mirror of
https://github.com/zeromq/cppzmq.git
synced 2024-12-13 10:52:57 +01:00
Problem: Draft build not enabled for git cloned cppzmq.
When cppzmq is build out of source e.g. ${CMAKE_SOURCE_DIR}/build: mkdir build cd build cmake .. then .git is not found properly, DRAFT build not enabled and poller test not added to pool of tests.
This commit is contained in:
parent
5ebc7fe32f
commit
34e5b98917
@ -19,17 +19,17 @@ if (ZeroMQ_FOUND AND (NOT TARGET libzmq OR NOT TARGET libzmq-static))
|
||||
message(FATAL_ERROR "ZeroMQ version not supported!")
|
||||
endif()
|
||||
|
||||
if (EXISTS "${SOURCE_DIR}/.git")
|
||||
if (EXISTS "${CMAKE_SOURCE_DIR}/.git")
|
||||
OPTION (ENABLE_DRAFTS "Build and install draft classes and methods" ON)
|
||||
else ()
|
||||
OPTION (ENABLE_DRAFTS "Build and install draft classes and methods" OFF)
|
||||
endif ()
|
||||
IF (ENABLE_DRAFTS)
|
||||
if (ENABLE_DRAFTS)
|
||||
ADD_DEFINITIONS (-DZMQ_BUILD_DRAFT_API)
|
||||
set (pkg_config_defines "-DZMQ_BUILD_DRAFT_API=1")
|
||||
ELSE (ENABLE_DRAFTS)
|
||||
else (ENABLE_DRAFTS)
|
||||
set (pkg_config_defines "")
|
||||
ENDIF (ENABLE_DRAFTS)
|
||||
endif (ENABLE_DRAFTS)
|
||||
|
||||
message(STATUS "cppzmq v${CPPZMQ_VERSION}")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user