[cmake-developers] [CMake 0012205]: FindBoost cannot handle parallel boost installations - Fixed version attached

Mantis Bug Tracker mantis at public.kitware.com
Wed May 18 11:21:58 EDT 2011


The following issue has been SUBMITTED. 
====================================================================== 
http://public.kitware.com/Bug/view.php?id=12205 
====================================================================== 
Reported By:                Thomas Roehr
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   12205
Category:                   CMake
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
====================================================================== 
Date Submitted:             2011-05-18 11:21 EDT
Last Modified:              2011-05-18 11:21 EDT
====================================================================== 
Summary:                    FindBoost cannot handle parallel boost installations
- Fixed version attached
Description: 
FindBoost.cmake cannot handle multiple boost versions. It does not pick the
include directory correctly, i.e. the version of the include directory does not
correspond to the version of the library directory. Example (/usr and custom
dir, here: /opt)
boost 1.40 installed in /usr/ and 1.44 in /opt/boost/  
Setting BOOST_ROOT to /opt/boost or alternatively BOOST_INCLUDEDIR and
BOOST_LIBRARYDIR to /opt/boost/include and /opt/boost/lib/ will result in: 
Boost_INCLUDE_DIR -> /opt/boost/include and Boost_LIBRARY_DIR -> /usr/lib and
Boost_SYSTEM_LIBRARIES .. /usr/lib/libboost..


Steps to Reproduce: 

Install boost into /usr/ and into /opt/boost, export BOOST_ROOT=/opt/boost or
BOOST_INCLUDEDIR=/opt/boost/include, BOOST_LIBRARYDIR)/opt/boost/lib and run a
CMake project with

find_package(Boost 1.38 COMPONENTS filesystem system unit_test_framework thread
serialization)

message(${Boost_INCLUDE_DIRS})
message(${Boost_LIBRARY_DIRS})



Additional Information: 
Attached the update FindBoost.cmake version that first searches the provided
path with NO_DEFAULT option and has a fallback to the DEFAULT path search. It
also provides full path information on the found libraries. 

====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2011-05-18 11:21 Thomas Roehr   New Issue                                    
2011-05-18 11:21 Thomas Roehr   File Added: FindBoost.cmake                    
======================================================================




More information about the cmake-developers mailing list