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

fix: fatal error cxxopts.hpp no such file or directory #1

Closed
prashis opened this issue Dec 16, 2021 · 2 comments
Closed

fix: fatal error cxxopts.hpp no such file or directory #1

prashis opened this issue Dec 16, 2021 · 2 comments

Comments

@prashis
Copy link

prashis commented Dec 16, 2021

#20 856.2 Scanning dependencies of target valhalla
#20 856.2 [ 66%] Building CXX object src/CMakeFiles/valhalla.dir/worker.cc.o
#20 867.4 [ 66%] Building CXX object src/CMakeFiles/valhalla.dir/filesystem.cc.o
#20 867.9 [ 70%] Building CXX object src/CMakeFiles/valhalla.dir/proto_conversions.cc.o
#20 872.1 [ 70%] Building CXX object src/CMakeFiles/valhalla.dir/tile_server.cc.o
#20 875.4 [ 70%] Building C object src/CMakeFiles/valhalla.dir/__/third_party/microtar/src/microtar.c.o
#20 875.5 [ 70%] Linking CXX static library libvalhalla.a
#20 875.8 [ 70%] Built target valhalla
#20 875.9 Scanning dependencies of target valhalla_build_statistics
#20 875.9 [ 73%] Building CXX object CMakeFiles/valhalla_build_statistics.dir/src/mjolnir/valhalla_build_statistics.cc.o
#20 876.5 /valhalla/src/mjolnir/valhalla_build_statistics.cc:8:10: fatal error: cxxopts.hpp: No such file or directory
#20 876.5     8 | #include <cxxopts.hpp>
#20 876.5       |          ^~~~~~~~~~~~~
#20 876.5 compilation terminated.
#20 876.5 make[2]: *** [CMakeFiles/valhalla_build_statistics.dir/build.make:63: CMakeFiles/valhalla_build_statistics.dir/src/mjolnir/valhalla_build_statistics.cc.o] Error 1
#20 876.5 make[1]: *** [CMakeFiles/Makefile2:1188: CMakeFiles/valhalla_build_statistics.dir/all] Error 2
#20 876.5 make: *** [Makefile:152: all] Error 2
------
executor failed running [/bin/sh -c cd valhalla/build; make]: exit code: 2
@prashis
Copy link
Author

prashis commented Dec 16, 2021

I'd fixed it by adding cxxopts.hpp in dir and moving inside of docker at /usr/include, maybe there is better solution for it instead of it 😅

@alinmindroc
Copy link
Owner

Thanks for reporting!
This happens because I had to update two CMakeLists files in the Valhalla repository, in order to compile the valhalla_traffic_demo_utils tool. I'm sure there is a cleaner solution for that, but I'm not cmake-savvy enough. So whenever the original CMakeLists change in the upstream, things break.

I've updated the docker image to clone a specific commit of the Valhalla repo now, so it shouldn't break again in the future.

I have also moved the tool to use cxxopts instead of boost, so now it's compiling correctly.

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

No branches or pull requests

2 participants