Support for constant T-matrix generator in cython.
[qpms.git] / CMakeLists.txt
blob7f80c81b24105b6c983e00261e4aca1c14007254
1 cmake_minimum_required(VERSION 3.0.2)
2 include(CMakeAddFortranSubdirectory)
3 include(version.cmake)
4 include(GNUInstallDirs)
6 project (QPMS)
8 set(CMAKE_BUILD_TYPE Debug)
10 macro(use_c99)
11   if (CMAKE_VERSION VERSION_LESS "3.1")
12     if (CMAKE_C_COMPILER_ID STREQUAL "GNU")
13       set (CMAKE_C_FLAGS "-std=gnu99 ${CMAKE_C_FLAGS}")
14     endif ()
15   else ()
16     set (CMAKE_C_STANDARD 99)
17   endif ()
18 endmacro(use_c99)
20 # We need the amos libraries to be compiled with -fPIC
21 # but at the same time, we do not want to make a .so file,
22 # so distutils package it with the rest of qpms c/cython lib.
23 set(CMAKE_POSITION_INDEPENDENT_CODE ON)
25 set (QPMS_VERSION_MAJOR 0)
26 #set (QPMS_VERSION_MINOR 3)
27 cmake_add_fortran_subdirectory (amos
28         PROJECT amos
29         LIBRARIES amos
30         NO_EXTERNAL_INSTALL)
31 add_subdirectory (qpms)
34 enable_testing()
35 add_subdirectory (tests EXCLUDE_FROM_ALL)
37 #add_subdirectory (apps/transop-ewald)