Hi everyone,
Question is about the difference of using Boost_INCLUDE_DIR and Boost_INCLUDE_DIRS to indicate where boost header files are in the system.
As I understood so far from the documentation and from different posts on SO and other forums:
- Boost_INCLUDE_DIR is cached after a first run of cmake in the project
- Boost_INCLUDE_DIRS is set each time that cmake is run in the project
From the examples in the documentation, Boost_INCLUDE_DIRS is the variable used to indicate where boost header files are in the system.
But my question is, if we decided to use Boost_INCLUDE_DIR, should results be different that with Boost_INCLUDE_DIRS ?
Because in our library, we decided to go with Boost_INCLUDE_DIR, it worked so far. But one developer encountered an error because Boost_INCLUDE_DIR was empty (it was not Boost_INCLUDE_DIR-NOT_FOUND) and Boost_INCLUDE_DIRS was correctly set.
Our CMake scripts only does the following:
find_package(Boost 1.56 REQUIRED)
include_directories(${Boost_INCLUDE_DIR})
Thank you for any insights on the issue and have a nice day.
Julián