Deleted the old code block
[dyninst.git] / cmake / DyninstConfig.cmake.in
1 # - Config file for Dyninst and its component libraries
2 # It defines the following variables:
3 #
4 # DYNINST_INCLUDE_DIRS
5 # DYNINST_LIBRARIES
6 # DYNINST_INTERNAL_DEFINES - used by the test suite
7
8 # compute paths
9
10 get_filename_component(DYNINST_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
11 set (DYNINST_INCLUDE_DIR @CONF_INCLUDE_DIRS@)
12
13 # Library dependencies
14 #include ("${DYNINST_CMAKE_DIR}/DyninstTargets.cmake")
15 foreach(TARG @ALL_DYNINST_TARGETS@)
16   include ("${DYNINST_CMAKE_DIR}/${TARG}Targets.cmake" OPTIONAL)
17 endforeach()
18
19 set (DYNINST_LIBRARIES "dyninstAPI")
20
21 # Other variables Dyninst mutators may depend on
22 set (DYNINST_PLATFORM "@PLATFORM@")
23 set (DYNINST_INTERNAL_DEFINES @UNIFIED_DEFINES@)
24
25 if(DYNINST_FIND_COMPONENTS)
26   foreach(COMP DYNINST_FIND_COMPONENTS)
27     if(NOT TARGET ${COMP})
28       set(DYNINST_${COMP}_FOUND 0)
29       if(DYNINST_FIND_REQUIRED_${COMP})
30         MESSAGE(ERROR "${COMP} was not part of the Dyninst build")
31       endif()
32     else()
33       set(DYNINST_${COMP}_FOUND 1)
34       MESSAGE(STATUS "Found ${COMP}")
35     endif()
36   endforeach()
37 endif()
38
39 if(TARGET dyninstAPI)
40   set(Dyninst_FOUND 1)
41 else()
42   set(Dyninst_FOUND 0)
43 endif()
44