Skip to content
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

Be explicit about Boost dependency in io subsystem #187

Open
daniel-j-h opened this issue Dec 23, 2016 · 1 comment
Open

Be explicit about Boost dependency in io subsystem #187

daniel-j-h opened this issue Dec 23, 2016 · 1 comment

Comments

@daniel-j-h
Copy link
Contributor

Using find_package(Osmium REQUIRED io) and any_input/output.hpp fails at compile time if Boost is not installed:

/home/travis/build/mapbox/rewrite-exit-destination-signage/third_party/libosmium/include/osmium/io/detail/debug_output_format.hpp:44:25: fatal error: boost/crc.hpp: No such file or directory

 #include <boost/crc.hpp>

Shold FindOsmium.cmake check early for all required dependencies? As in:

find_package(Boost REQUIRED)

(Maybe even with components and a minimum version)

@joto
Copy link
Member

joto commented Dec 23, 2016

This is difficult to do right, because basically all dependencies are optional, some are only needed for some tiny functionality in some corner of libosmium. In this case the dependency is only needed for the debug output, which most people probably don't need. Still, the way it is now, the code might not compile, so it is good you found this problem. We probably have to be more systematic in the way we test for dependencies and then either fail the compile or disable some functionality. Not sure how to best do this, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants