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

Problem: ZMQ_BUILD_DRAFT_API define is not propagated to dependent CMake projects #4323

Merged
merged 1 commit into from
Dec 29, 2021
Merged

Problem: ZMQ_BUILD_DRAFT_API define is not propagated to dependent CMake projects #4323

merged 1 commit into from
Dec 29, 2021

Conversation

boscosiu
Copy link
Contributor

Solution: Add the definition to the relevant CMake targets in public scope. Fixes #4194

@bluca
Copy link
Member

bluca commented Dec 28, 2021

Build fails:

C:\projects\build_libzmq\platform.hpp(74,1): error C2220: the following warning is treated as an error [C:\projects\build_libzmq\libzmq.vcxproj]
C:\projects\build_libzmq\platform.hpp(74,1): warning C4005: 'ZMQ_BUILD_DRAFT_API': macro redefinition [C:\projects\build_libzmq\libzmq.vcxproj]
C:\projects\libzmq\src\precompiled.cpp : message : see previous definition of 'ZMQ_BUILD_DRAFT_API' 

@boscosiu
Copy link
Contributor Author

Thanks, sorry about that. I refactored this to have the build targets receive the definition directly from CMake instead of through the CMake-generated platform.hpp.

…ake projects

Solution: Add the definition to the relevant CMake targets in public scope.  Fixes #4194
@bluca bluca merged commit ee09926 into zeromq:master Dec 29, 2021
stephanlachnit added a commit to stephanlachnit/cppzmq that referenced this pull request Jul 29, 2022
This option added ZMQ_BUILD_DRAFT_API to the compile definitions. However, this should be propagated by libzmq (see zeromq/libzmq#4323 and zeromq#477).

Signed-off-by: Stephan Lachnit <stephanlachnit@debian.org>
stephanlachnit added a commit to stephanlachnit/cppzmq that referenced this pull request Nov 20, 2023
This option added ZMQ_BUILD_DRAFT_API to the compile definitions. However, this should be propagated by libzmq (see zeromq/libzmq#4323 and zeromq#477).

Signed-off-by: Stephan Lachnit <stephanlachnit@debian.org>
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

Successfully merging this pull request may close these issues.

CMake build on Linux does not export ZMQ_BUILD_DRAFT_API as a compile_definition with the target
2 participants