From a844b001f93a522a0d7069fb6378d2e820427167 Mon Sep 17 00:00:00 2001 From: sjunges Date: Wed, 23 Nov 2016 20:47:37 +0100 Subject: [PATCH] python has to be found before carl is included in order to pass the python version forward --- resources/3rdparty/CMakeLists.txt | 8 ++++++++ stormpy/CMakeLists.txt | 7 ------- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/resources/3rdparty/CMakeLists.txt b/resources/3rdparty/CMakeLists.txt index 87b0b790f..71449ca13 100644 --- a/resources/3rdparty/CMakeLists.txt +++ b/resources/3rdparty/CMakeLists.txt @@ -4,6 +4,14 @@ add_custom_target(test-resources) set(STORM_3RDPARTY_SOURCE_DIR ${PROJECT_SOURCE_DIR}/resources/3rdparty) set(STORM_3RDPARTY_BINARY_DIR ${PROJECT_BINARY_DIR}/resources/3rdparty) +if (STORM_PYTHON) + find_package(PythonInterp REQUIRED QUIET) + find_package(PythonLibs REQUIRED QUIET) + + message(STATUS "Python executable: ${PYTHON_EXECUTABLE}") + message(STATUS "Python include: ${PYTHON_INCLUDE_DIRS}") + message(STATUS "Python include: ${PYTHON_LIBRARIES}") +endif() ############################################################# ## diff --git a/stormpy/CMakeLists.txt b/stormpy/CMakeLists.txt index 6a1acd8b7..afd91d57e 100644 --- a/stormpy/CMakeLists.txt +++ b/stormpy/CMakeLists.txt @@ -1,10 +1,3 @@ -find_package(PythonInterp REQUIRED QUIET) -find_package(PythonLibs REQUIRED QUIET) - -message(STATUS "Python executable: ${PYTHON_EXECUTABLE}") -message(STATUS "Python include: ${PYTHON_INCLUDE_DIRS}") -message(STATUS "Python include: ${PYTHON_LIBRARIES}") - set(STORMPY_OUTPUT_DIR "${PROJECT_BINARY_DIR}/stormpy") set(STORMPY_SOURCE_DIR "${PROJECT_SOURCE_DIR}/stormpy")