Reputation: 276
I'm following the next installation guide:
https://www.cgal.org/download/windows.html#Boost
and got the following cmake error:
BOOST_LIBRARYDIR = C:/dev/libboost_1_67_0/lib32-msvc-12.0
BOOST_ROOT = C:/dev/libboost_1_67_0/
[ C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1483 ] Searching for THREAD_LIBRARY_RELEASE: libboost_thread-vc120-mt-1_67;libboost_thread-vc120-mt;libboost_thread-mt-1_67;libboost_thread-mt;libboost_thread;libboost_thread-vc120-mt-s-1_67;libboost_thread-vc120-mt-s;libboost_thread-mt-s-1_67;libboost_thread-mt-s
[ C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1525 ] Searching for THREAD_LIBRARY_DEBUG: libboost_thread-vc120-mt-gd-1_67;libboost_thread-vc120-mt-gd;libboost_thread-mt-gd-1_67;libboost_thread-mt-gd;libboost_thread-mt;libboost_thread;libboost_thread-vc120-mt-s-gd-1_67;libboost_thread-vc120-mt-s-gd;libboost_thread-mt-s-gd-1_67;libboost_thread-mt-s-gd
[ C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1483 ] Searching for SYSTEM_LIBRARY_RELEASE: libboost_system-vc120-mt-1_67;libboost_system-vc120-mt;libboost_system-mt-1_67;libboost_system-mt;libboost_system;libboost_system-vc120-mt-s-1_67;libboost_system-vc120-mt-s;libboost_system-mt-s-1_67;libboost_system-mt-s
[ C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1525 ] Searching for SYSTEM_LIBRARY_DEBUG: libboost_system-vc120-mt-gd-1_67;libboost_system-vc120-mt-gd;libboost_system-mt-gd-1_67;libboost_system-mt-gd;libboost_system-mt;libboost_system;libboost_system-vc120-mt-s-gd-1_67;libboost_system-vc120-mt-s-gd;libboost_system-mt-s-gd-1_67;libboost_system-mt-s-gd
[ C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1595 ] Boost_FOUND = 1
CMake Error at C:/Program Files/CMake/share/cmake-3.6/Modules/FindBoost.cmake:1753 (message):
Unable to find the requested Boost libraries.
Boost version: 1.67.0
Boost include path: C:/dev/libboost_1_67_0
Could not find the following static Boost libraries:
boost_thread
boost_system
No Boost libraries were found. You may need to set BOOST_LIBRARYDIR to the
directory containing Boost libraries or BOOST_ROOT to the location of
Boost.
Call Stack (most recent call first):
cmake/modules/CGAL_SetupBoost.cmake:48 (find_package)
cmake/modules/CGAL_SetupDependencies.cmake:85 (include)
CMakeLists.txt:674 (include)
Boost include dirs: C:/dev/libboost_1_67_0
Boost libraries:
== Detect external libraries (DONE) ==
I have tryed many ways to solve the problem:
https://sourceforge.net/projects/boost/files/boost-binaries/
C:\boost_1_67_0>b2 toolset=msvc-12.0 variant=debug,release link=static runtime-link=static threading=single,multi --prefix=C:\boost_1_67_0\build
C:\boost_1_67_0>b2 toolset=msvc-12.0 variant=debug,release link=static runtime-link=static threading=single,multi --prefix=C:\boost_1_67_0\build install
In all way the result is the same:
libboost_thread-vc120-mt-gd-x32-1_67.lib, libboost_thread-vc120-mt-s-x32-1_67.lib, libboost_thread-vc120-mt-sgd-x32-1_67.lib, libboost_thread-vc120-mt-x32-1_67.lib
libboost_system-vc120-mt-gd-x32-1_67.lib, libboost_system-vc120-mt-s-x32-1_67.lib, libboost_system-vc120-mt-sgd-x32-1_67.lib, libboost_system-vc120-mt-x32-1_67.lib
The problem is that cmake is searching for a lib with the name:
xxxxxxxxxxxxxxx-vc120-mt-1_67
but the boost binaries only have:
xxxxxxxxxxxxxxx-vc120-mt-x32-1_67.lib
How can i solve this problem?
Upvotes: 0
Views: 111
Reputation: 726
You can override the FindBoost mechanism by specifying the path to your boost libraries with the -D option :
cmake -DBoost_THREAD_LIBRARY_RELEASE=C:/dev/libboost_1_67_0/lib32-msvc-12.0/libboost_thread-vc120-mt-gd-x32-1_67.lib -DBoost_SYSTEM_LIBRARY_RELEASE=... <path_to_CGAL_root>
or by specifying them in the GUI of cmake-gui, if you are using it.
EDIT: Apparently you can also upgrade your version of cmake to the latest version(3.11.2), which should have a FindBoost that works with Boost 1.67.0.
Upvotes: 0