paradiseo-->peo
git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@598 331e1502-861f-0410-8da2-ba01fb791d7f
This commit is contained in:
parent
ef7821fa60
commit
dd69a368dc
21 changed files with 377 additions and 562 deletions
|
|
@ -21,6 +21,13 @@ ADD_CUSTOM_COMMAND(
|
|||
ARGS -E copy_if_different
|
||||
${ParadisEO-PEO_SOURCE_DIR}/tutorial/Lesson1/schema.xml
|
||||
${ParadisEO-PEO_BINARY_DIR}/tutorial/Lesson1)
|
||||
ADD_CUSTOM_COMMAND(
|
||||
TARGET install
|
||||
POST_BUILD
|
||||
COMMAND ${CMAKE_COMMAND}
|
||||
ARGS -E copy_if_different
|
||||
${ParadisEO-PEO_SOURCE_DIR}/tutorial/Lesson1/ParadisEO-PEO_Lesson1.pdf
|
||||
${ParadisEO-PEO_BINARY_DIR}/tutorial/Lesson1)
|
||||
######################################################################################
|
||||
|
||||
|
||||
|
|
@ -28,23 +35,23 @@ ADD_CUSTOM_COMMAND(
|
|||
### 1) Include the sources
|
||||
######################################################################################
|
||||
|
||||
INCLUDE_DIRECTORIES(${EO_SRC_DIR})
|
||||
INCLUDE_DIRECTORIES(${MO_SRC_DIR})
|
||||
INCLUDE_DIRECTORIES(${PEO_SRC_DIR})
|
||||
INCLUDE_DIRECTORIES(${TSP_SRC_DIR})
|
||||
INCLUDE_DIRECTORIES(${EO_SRC_DIR}/src ${MO_SRC_DIR}/src ${ParadisEO-PEO_SOURCE_DIR}/src ${TSP_SRC_DIR})
|
||||
|
||||
######################################################################################
|
||||
|
||||
|
||||
######################################################################################
|
||||
### 2) Specify where CMake can find the libraries (mandatory: before 3) )
|
||||
### 2) Specify where CMake can find the libraries
|
||||
######################################################################################
|
||||
|
||||
LINK_DIRECTORIES( ${EO_SRC_DIR}
|
||||
${EO_SRC_DIR}/utils
|
||||
${ParadisEO-PEO_BINARY_DIR}/lib
|
||||
${TSP_BINARY_DIR}/lib)
|
||||
IF(NOT WIN32 OR CYGWIN)
|
||||
LINK_DIRECTORIES(${EO_BIN_DIR}/lib ${ParadisEO-PEO_BINARY_DIR}/lib ${TSP_BINARY_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} ${ParadisEO-PEO_BINARY_DIR}\\lib\\${CMAKE_BUILD_TYPE} ${TSP_BINARY_DIR}\\lib\\${CMAKE_BUILD_TYPE})
|
||||
ENDIF(WIN32 AND NOT CYGWIN)
|
||||
######################################################################################
|
||||
|
||||
|
||||
|
|
@ -52,20 +59,16 @@ LINK_DIRECTORIES( ${EO_SRC_DIR}
|
|||
### 3) Define your target(s): just an executable here
|
||||
######################################################################################
|
||||
|
||||
# no matter what is the OS, hopefully
|
||||
ADD_EXECUTABLE(tspExample main.cpp)
|
||||
|
||||
ADD_DEPENDENCIES(tspExample tsp)
|
||||
ADD_DEPENDENCIES(tspExample peo)
|
||||
ADD_DEPENDENCIES(tspExample rmc_mpi)
|
||||
ADD_DEPENDENCIES(tspExample tsp peo rmc_mpi)
|
||||
######################################################################################
|
||||
|
||||
|
||||
######################################################################################
|
||||
### 4) Optionnal: define your target(s)'s version: no effect for windows
|
||||
### 4) Optionnal: define properties
|
||||
######################################################################################
|
||||
|
||||
SET(LESSON1_VERSION "1.0.beta")
|
||||
SET(LESSON1_VERSION ${GLOBAL_VERSION})
|
||||
SET_TARGET_PROPERTIES(tspExample PROPERTIES VERSION "${LESSON1_VERSION}")
|
||||
######################################################################################
|
||||
|
||||
|
|
@ -74,16 +77,29 @@ SET_TARGET_PROPERTIES(tspExample PROPERTIES VERSION "${LESSON1_VERSION}")
|
|||
### 5) Link the librairies
|
||||
######################################################################################
|
||||
|
||||
TARGET_LINK_LIBRARIES(tspExample ${XML2_LIBS}) # define in CMakeLists.txt at PEO root dir
|
||||
TARGET_LINK_LIBRARIES(tspExample tsp)
|
||||
TARGET_LINK_LIBRARIES(tspExample peo)
|
||||
TARGET_LINK_LIBRARIES(tspExample rmc_mpi)
|
||||
TARGET_LINK_LIBRARIES(tspExample eo)
|
||||
TARGET_LINK_LIBRARIES(tspExample eoutils)
|
||||
TARGET_LINK_LIBRARIES(tspExample ${XML2_LIBS} tsp peo rmc_mpi eo eoutils)
|
||||
|
||||
######################################################################################
|
||||
|
||||
|
||||
######################################################################################
|
||||
### 6) Windows advanced config - especially for Microsoft Visual Studio 8
|
||||
######################################################################################
|
||||
|
||||
IF(CMAKE_CXX_COMPILER MATCHES cl)
|
||||
IF(NOT WITH_SHARED_LIBS)
|
||||
IF(CMAKE_GENERATOR STREQUAL "Visual Studio 8 2005")
|
||||
SET(CMAKE_CXX_FLAGS "/nologo /W3 /Gy")
|
||||
SET(CMAKE_CXX_FLAGS_DEBUG "/MTd /Z7 /Od")
|
||||
SET(CMAKE_CXX_FLAGS_RELEASE "/MT /O2")
|
||||
SET(CMAKE_CXX_FLAGS_MINSIZEREL "/MT /O2")
|
||||
SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "/MTd /Z7 /Od")
|
||||
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /SUBSYSTEM:CONSOLE")
|
||||
|
||||
ENDIF(CMAKE_GENERATOR STREQUAL "Visual Studio 8 2005")
|
||||
ENDIF(NOT WITH_SHARED_LIBS)
|
||||
ENDIF(CMAKE_CXX_COMPILER MATCHES cl)
|
||||
######################################################################################
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
#include "param.h"
|
||||
|
||||
#include <paradiseo>
|
||||
#include <peo>
|
||||
|
||||
|
||||
#define POP_SIZE 10
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue