fix build system : make eo/edo tests work
This commit is contained in:
parent
0829afceb9
commit
06ff0b682b
17 changed files with 328 additions and 326 deletions
|
|
@ -2,50 +2,50 @@
|
|||
### 1) Include the sources
|
||||
######################################################################################
|
||||
|
||||
INCLUDE_DIRECTORIES(${EO_SOURCE_DIR}/src)
|
||||
include_directories(${EO_SRC_DIR}/src)
|
||||
|
||||
######################################################################################
|
||||
### 2) Specify where CMake can find the libraries
|
||||
######################################################################################
|
||||
|
||||
IF(NOT WIN32 OR CYGWIN)
|
||||
LINK_DIRECTORIES(${EO_BIN_DIR}/lib)
|
||||
ENDIF(NOT WIN32 OR CYGWIN)
|
||||
if(NOT WIN32 OR CYGWIN)
|
||||
link_directories(${EO_BIN_DIR}/lib)
|
||||
endif(NOT WIN32 OR CYGWIN)
|
||||
|
||||
# especially for Visual Studio
|
||||
IF(WIN32 AND NOT CYGWIN)
|
||||
LINK_DIRECTORIES(${EO_BIN_DIR}\\lib\\${CMAKE_BUILD_TYPE})
|
||||
ENDIF(WIN32 AND NOT CYGWIN)
|
||||
if(WIN32 AND NOT CYGWIN)
|
||||
link_directories(${EO_BIN_DIR}\\lib\\${CMAKE_BUILD_TYPE})
|
||||
endif(WIN32 AND NOT CYGWIN)
|
||||
|
||||
######################################################################################
|
||||
### 3) Define your targets
|
||||
######################################################################################
|
||||
|
||||
ADD_EXECUTABLE(BinaryPSO BinaryPSO.cpp)
|
||||
ADD_EXECUTABLE(RealPSO RealPSO.cpp)
|
||||
add_executable(BinaryPSO BinaryPSO.cpp)
|
||||
add_executable(RealPSO RealPSO.cpp)
|
||||
|
||||
######################################################################################
|
||||
### 4) Optionnal
|
||||
######################################################################################
|
||||
|
||||
SET(BINARYPSO_VERSION ${GLOBAL_VERSION})
|
||||
SET_TARGET_PROPERTIES(BinaryPSO PROPERTIES VERSION "${BINARYPSO_VERSION}")
|
||||
set(BINARYPSO_VERSION ${GLOBAL_VERSION})
|
||||
set_target_properties(BinaryPSO PROPERTIES VERSION "${BINARYPSO_VERSION}")
|
||||
|
||||
SET(REALPSO_VERSION ${GLOBAL_VERSION})
|
||||
SET_TARGET_PROPERTIES(RealPSO PROPERTIES VERSION "${REALPSO_VERSION}")
|
||||
set(REALPSO_VERSION ${GLOBAL_VERSION})
|
||||
set_target_properties(RealPSO PROPERTIES VERSION "${REALPSO_VERSION}")
|
||||
|
||||
######################################################################################
|
||||
### 5) Link the librairies for the targets
|
||||
######################################################################################
|
||||
|
||||
TARGET_LINK_LIBRARIES(BinaryPSO eo eoutils)
|
||||
TARGET_LINK_LIBRARIES(RealPSO eo eoutils)
|
||||
target_link_libraries(BinaryPSO eo eoutils)
|
||||
target_link_libraries(RealPSO eo eoutils)
|
||||
|
||||
######################################################################################
|
||||
### 6) Configure project installation paths
|
||||
######################################################################################
|
||||
|
||||
INSTALL(TARGETS BinaryPSO RUNTIME DESTINATION local/share${INSTALL_SUB_DIR}/eo/examples/Lesson6 COMPONENT examples)
|
||||
INSTALL(TARGETS RealPSO RUNTIME DESTINATION local/share${INSTALL_SUB_DIR}/eo/examples/Lesson6 COMPONENT examples)
|
||||
install(TARGETS BinaryPSO RUNTIME DESTINATION local/share${INSTALL_SUB_DIR}/eo/examples/Lesson6 COMPONENT examples)
|
||||
install(TARGETS RealPSO RUNTIME DESTINATION local/share${INSTALL_SUB_DIR}/eo/examples/Lesson6 COMPONENT examples)
|
||||
|
||||
######################################################################################
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue