1 ## =========================================================================
2 ## @author Leonardo Florez-Valencia (florez-l@javeriana.edu.co)
3 ## =========================================================================
5 ## == If working on a MacOSX, activate the use of RPATH's
6 ## == Furthermore: prepare the type of executables
7 set(APP_TYPE "" CACHE STRING "Executable linking." FORCE)
9 set(APP_TYPE "MACOSX_BUNDLE" CACHE STRING "Executable linking." FORCE)
10 set(CMAKE_MACOSX_RPATH true CACHE BOOL "Use RPATH's on MacOSX." FORCE)
11 mark_as_advanced(CMAKE_MACOSX_RPATH)
13 set(APP_TYPE "WIN32" CACHE STRING "Executable linking." FORCE)
15 mark_as_advanced(APP_TYPE)
18 set(CMAKE_CXX_STANDARD 17)
20 ## == Prepare header generator to build shared libs
21 include(GenerateExportHeader)
23 ## == Do not allow to build inside the source tree
24 if(PROJECT_BINARY_DIR STREQUAL ${PROJECT_SOURCE_DIR})
25 message(FATAL_ERROR "Building in the source tree is not allowed.")
26 endif(PROJECT_BINARY_DIR STREQUAL ${PROJECT_SOURCE_DIR})
28 ## == Where to put targets (executables and libs)
29 set(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR})
30 set(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR})
32 CMAKE_BACKWARDS_COMPATIBILITY
33 EXECUTABLE_OUTPUT_PATH