]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
CMakeLists.txt/FreeBSD: Boost_python needs explicit linking with libpython*.so 12763/head
authorWillem Jan Withagen <wjw@digiware.nl>
Tue, 3 Jan 2017 14:08:25 +0000 (15:08 +0100)
committerWillem Jan Withagen <wjw@digiware.nl>
Wed, 4 Jan 2017 20:50:22 +0000 (21:50 +0100)
 - Otherwise losts of unresolved errors will result.

Signed-off-by: Willem Jan Withagen <wjw@digiware.nl>
CMakeLists.txt

index 565547c2c5919bc7f4b366afc682dc7209c674f2..90debd85164db01715e909ac27f76a2dec537a2c 100644 (file)
@@ -477,7 +477,12 @@ find_package(Boost 1.61 COMPONENTS ${BOOST_COMPONENTS} REQUIRED)
 include_directories(SYSTEM ${Boost_INCLUDE_DIRS})
 include_directories(SYSTEM ${PROJECT_BINARY_DIR}/include)
 
-if (NOT WITH_SYSTEM_BOOST)
+if (WITH_SYSTEM_BOOST)
+  if(FREEBSD)
+    # if boost_python is used then also link with libpython*
+    LIST(APPEND Boost_LIBRARIES ${PYTHON_LIBRARIES})
+  endif()
+else()
   LIST(APPEND Boost_LIBRARIES "-lz")
 endif()