mirror of
https://github.com/QuantumLeaps/qpc.git
synced 2025-01-28 07:03:10 +08:00
21 lines
729 B
CMake
21 lines
729 B
CMake
# CMake the qpc libraries for different targets
|
|
set(PORT_DIR ${PORT})
|
|
if((PORT STREQUAL win32) OR (PORT STREQUAL posix))
|
|
if(QPC_CFG_UNIT_TEST)
|
|
set(PORT_DIR ${PORT_DIR}-qutest)
|
|
elseif(KERNEL STREQUAL qv)
|
|
set(PORT_DIR ${PORT_DIR}-qv)
|
|
endif()
|
|
endif()
|
|
if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${PORT_DIR})
|
|
message(STATUS "Found port dir - './${PORT_DIR}' for port ${PORT}, KERNEL ${KERNEL}")
|
|
else()
|
|
message(FATAL_ERROR "Target port dir '${CMAKE_CURRENT_SOURCE_DIR}/${PORT_DIR}' not found!")
|
|
endif()
|
|
|
|
add_subdirectory(${PORT_DIR})
|
|
if(NOT QPC_CFG_QPCONFIG_H_INCLUDE_PATH)
|
|
set(QPC_CFG_QPCONFIG_H_INCLUDE_PATH config)
|
|
endif()
|
|
target_include_directories(qpc PUBLIC ${QPC_CFG_QPCONFIG_H_INCLUDE_PATH})
|