-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Made 'include_directories' use correct boost include var. #50
Conversation
The documentation of FindBoost (cmake --help-module FindBoost) indicates that 'Boost_INCLUDE_DIRS' points to the boost includes and not 'Boost_INCLUDE_DIR'. This bug could inadvertently cause pion to use system boost headers with another boost installation's libraries.
@camio could you please provide more information about this issue? In fact with my cmake v2.8.12.2 FindBoost.cmake contains following code ... # ------------------------------------------------------------------------ # End finding boost libraries # ------------------------------------------------------------------------ set(Boost_INCLUDE_DIRS ${Boost_INCLUDE_DIR}) set(Boost_LIBRARY_DIRS ${Boost_LIBRARY_DIR}) Which makes Boost_INCLUDE_DIRS equivalent to Boost_INCLUDE_DIR |
@snikulov The documentation for FindBoost as given by 'cmake --help-module FindBoost', reproduced below, explicitly discourages the use of 'Boost_INCLUDE_DIR' in favor of 'Boost_INCLUDE_DIRS'. "Projects should not read these entries directly but instead use the above result variables." We're using a custom FindBoost that maintains interface compatibility with cmake's one and that is where we came across this problem.
|
@camio thank you, I'm able to read documentation myself. |
@snikulov The use we ran into is exactly what I mentioned in the previous comment. A custom FindBoost.cmake command that is interface compatible with the one that comes with the system cmake. Rather than modify our custom 'FindBoost.cmake' command to support this invalid use of find_package(Boost...), it seems better to fix the pion cmake code. What you mentioned may also demonstrate the problem. I haven't tested it. |
@camio Ok. Thank you. |
Silence MSVC warnings about integer truncation
The documentation of FindBoost (cmake --help-module FindBoost)
indicates that 'Boost_INCLUDE_DIRS' points to the boost includes and not
'Boost_INCLUDE_DIR'.
This bug could inadvertently cause pion to use system boost headers with
another boost installation's libraries.