Fix problem type in island model.
[PaGMO.git] / CMakeLists.txt
blobba3855242e6f937719d60d2df25e10210e6f8960
1 PROJECT(PaGMO)
3 CMAKE_MINIMUM_REQUIRED(VERSION 2.4.0)
5 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -fmessage-length=0 -Wdisabled-optimization")
6 SET(CMAKE_BUILD_TYPE "Release")
8 INCLUDE(CheckTypeSize)
10 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}")
11 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/AstroToolbox")
12 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/Functions/rng")
13 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/Functions/objfuns")
14 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/GOclasses/algorithms")
15 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/GOclasses/basic")
16 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/GOclasses/problems")
17 INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/SolversThreads")
19 CHECK_TYPE_SIZE("void *" POINTER_SIZE)
20 MESSAGE(STATUS "Pointer size = ${POINTER_SIZE}")
22 FIND_LIBRARY(PTHREAD_LIBRARY pthread)
23 IF(NOT PTHREAD_LIBRARY)
24         MESSAGE(FATAL_ERROR "pthread library not found, please specify manually where it is located.")
25 ENDIF(NOT PTHREAD_LIBRARY)
27 SET(PAGMO_LIB_SRC_LIST
28         ${CMAKE_SOURCE_DIR}/AstroToolbox/Astro_Functions.cpp
29         ${CMAKE_SOURCE_DIR}/AstroToolbox/Lambert.cpp
30         ${CMAKE_SOURCE_DIR}/AstroToolbox/mga.cpp
31         ${CMAKE_SOURCE_DIR}/AstroToolbox/mga_dsm.cpp
32         ${CMAKE_SOURCE_DIR}/AstroToolbox/misc4Tandem.cpp
33         ${CMAKE_SOURCE_DIR}/AstroToolbox/Pl_Eph_An.cpp
34         ${CMAKE_SOURCE_DIR}/AstroToolbox/PowSwingByInv.cpp
35         ${CMAKE_SOURCE_DIR}/AstroToolbox/propagateKEP.cpp
36         ${CMAKE_SOURCE_DIR}/AstroToolbox/time2distance.cpp
37         ${CMAKE_SOURCE_DIR}/Functions/rng/PkRandom.cpp
38         ${CMAKE_SOURCE_DIR}/Functions/objfuns/trajobjfuns.cpp
39         ${CMAKE_SOURCE_DIR}/GOclasses/algorithms/ASA.cpp
40         ${CMAKE_SOURCE_DIR}/GOclasses/algorithms/DE.cpp
41         ${CMAKE_SOURCE_DIR}/GOclasses/algorithms/MPSO.cpp
42         ${CMAKE_SOURCE_DIR}/GOclasses/algorithms/PSO.cpp
43         ${CMAKE_SOURCE_DIR}/GOclasses/algorithms/SGA.cpp
44         ${CMAKE_SOURCE_DIR}/GOclasses/basic/individual.cpp
45         ${CMAKE_SOURCE_DIR}/GOclasses/basic/population.cpp
46         ${CMAKE_SOURCE_DIR}/GOclasses/problems/GOproblem.cpp
47         ${CMAKE_SOURCE_DIR}/GOclasses/problems/TrajectoryProblems.cpp
48         ${CMAKE_SOURCE_DIR}/SolversThreads/SolversThreads.cpp
51 ADD_LIBRARY(pagmo STATIC ${PAGMO_LIB_SRC_LIST})
53 ADD_EXECUTABLE(main main.cpp)
55 TARGET_LINK_LIBRARIES(main pagmo ${PTHREAD_LIBRARY})