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

CMake fails to compile #54

Closed
shawcx opened this issue Jan 30, 2014 · 5 comments
Closed

CMake fails to compile #54

shawcx opened this issue Jan 30, 2014 · 5 comments

Comments

@shawcx
Copy link

shawcx commented Jan 30, 2014

When adding an external project to CMake:

ExternalProject_Add(
    EP_zeromq
    PREFIX     ${CMAKE_CURRENT_BINARY_DIR}
    GIT_REPOSITORY https://github.com/zeromq/zeromq4-x.git
    GIT_TAG v4.0.3
    SOURCE_DIR ${CMAKE_CURRENT_BINARY_DIR}/src/zeromq

    CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR> -DZMQ_BUILD_FRAMEWORK=0
    )

The build fails with:

[ 66%] Building CXX object CMakeFiles/test_connect_resolve.dir/tests/test_connect_resolve.cpp.o
In file included from /code/build/thirdparty/src/zeromq/tests/test_connect_resolve.cpp:20:0:
/code/build/thirdparty/src/zeromq/tests/testutil.hpp:25:31: fatal error: ../src/platform.hpp: No such file or directory
compilation terminated.
make[5]: *** [CMakeFiles/test_connect_resolve.dir/tests/test_connect_resolve.cpp.o] Error 1
make[4]: *** [CMakeFiles/test_connect_resolve.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [thirdparty/src/EP_zeromq-stamp/EP_zeromq-build] Error 2
make[1]: *** [thirdparty/CMakeFiles/EP_zeromq.dir/all] Error 2
make: *** [all] Error 2
@yanxiongjian
Copy link

Have you worked out any approach to solve the problem?

@shawcx
Copy link
Author

shawcx commented Feb 14, 2014

I was going to post my workaround, but it looks like a patch got merged in. The system works.

@ronkorving
Copy link

So this can be closed? :)

@jcfr
Copy link
Contributor

jcfr commented Jan 30, 2016

@moertle Using master (1206dc4 /2016-01-30), I confirm the problem is fixed.

$ cmake -version
cmake version 3.4.2

CMake suite maintained and supported by Kitware (kitware.com/cmake).

$ cmake -DCMAKE_BUILD_TYPE=Release -DZMQ_BUILD_FRAMEWORK=0 ../ZeroMQ
[...]
-- Configuring done
-- Generating done
-- Build files have been written to: /path/to/ZeroMQ-Release

$ make -j5
[...]
[ 99%] Built target test_sub_forward
[ 99%] Built target test_system
[ 99%] Built target test_term_endpoint
[100%] Linking CXX executable bin/test_timeo
[100%] Built target test_timeo

@ronkorving @somdoron Please consider closing this issue.

@bluca
Copy link
Member

bluca commented Jun 9, 2016

Thanks for verifying, closing

@bluca bluca closed this as completed Jun 9, 2016
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

5 participants