@@ -43,6 +43,28 @@ add_definitions(-DBOOST_TEST_DYN_LINK)
4343# Avoid valgrind error due to overflow error, cf. https://github.com/ompl/ompl/issues/664
4444add_definitions (-DBOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS)
4545
46+ set_package_properties(Threads PROPERTIES
47+ URL "https://en.wikipedia.org/wiki/POSIX_Threads"
48+ PURPOSE "Pthreads is sometimes needed, depending on OS / compiler." )
49+ find_package (Threads QUIET )
50+
51+ enable_testing ()
52+
53+ set_package_properties(Python PROPERTIES
54+ URL "https://www.python.org"
55+ PURPOSE "Used for python bindings." )
56+ find_package (Python QUIET )
57+ find_boost_python()
58+
59+ if (PYTHON_FOUND)
60+ set_package_properties(pypy PROPERTIES
61+ URL "https://pypy.org"
62+ PURPOSE "Used to speed up the generation of python bindings." )
63+ find_package (pypy QUIET )
64+ endif ()
65+
66+ # look for boost AFTER find_boost_python which also uses
67+ # find_package(Boost) internally and can overwrite a selected Boost library
4668set_package_properties(Boost PROPERTIES
4769 URL "https://www.boost.org"
4870 PURPOSE "Used throughout OMPL for data serialization, graphs, etc." )
@@ -65,27 +87,6 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "^(Apple)?Clang$")
6587 add_definitions (-stdlib=${CXXSTDLIB} )
6688 endif ()
6789endif ()
68-
69- set_package_properties(Threads PROPERTIES
70- URL "https://en.wikipedia.org/wiki/POSIX_Threads"
71- PURPOSE "Pthreads is sometimes needed, depending on OS / compiler." )
72- find_package (Threads QUIET )
73-
74- enable_testing ()
75-
76- set_package_properties(Python PROPERTIES
77- URL "https://www.python.org"
78- PURPOSE "Used for python bindings." )
79- find_package (Python QUIET )
80- find_boost_python()
81-
82- if (PYTHON_FOUND)
83- set_package_properties(pypy PROPERTIES
84- URL "https://pypy.org"
85- PURPOSE "Used to speed up the generation of python bindings." )
86- find_package (pypy QUIET )
87- endif ()
88-
8990set_package_properties(Eigen3 PROPERTIES
9091 URL "http://eigen.tuxfamily.org"
9192 PURPOSE "A linear algebra library used throughout OMPL." )
0 commit comments