2014-12-11 10:17:08 +01:00
|
|
|
# Sources
|
|
|
|
file(GLOB SRCS_G "src/*.cpp")
|
|
|
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
|
|
|
|
|
|
|
# Headers
|
|
|
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
|
|
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
|
|
|
|
2019-06-24 15:39:06 +02:00
|
|
|
# Version Resource
|
|
|
|
if(MSVC AND NOT POCO_STATIC)
|
2019-10-18 15:35:02 +02:00
|
|
|
source_group("Resources" FILES ${PROJECT_SOURCE_DIR}/DLLVersion.rc)
|
|
|
|
list(APPEND SRCS ${PROJECT_SOURCE_DIR}/DLLVersion.rc)
|
2019-06-24 15:39:06 +02:00
|
|
|
endif()
|
|
|
|
|
2018-06-03 18:17:50 +02:00
|
|
|
add_library(CppParser ${SRCS})
|
|
|
|
add_library(Poco::CppParser ALIAS CppParser)
|
|
|
|
set_target_properties(CppParser
|
2014-12-11 10:17:08 +01:00
|
|
|
PROPERTIES
|
|
|
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
2018-06-03 18:17:50 +02:00
|
|
|
OUTPUT_NAME PocoCppParser
|
2014-12-11 10:17:08 +01:00
|
|
|
DEFINE_SYMBOL CppParser_EXPORTS
|
|
|
|
)
|
|
|
|
|
2018-06-03 18:17:50 +02:00
|
|
|
target_link_libraries(CppParser PUBLIC Poco::Foundation)
|
|
|
|
target_include_directories(CppParser
|
2014-12-11 10:17:08 +01:00
|
|
|
PUBLIC
|
|
|
|
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
|
|
|
|
$<INSTALL_INTERFACE:include>
|
|
|
|
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src
|
|
|
|
)
|
|
|
|
|
2018-06-03 18:17:50 +02:00
|
|
|
POCO_INSTALL(CppParser)
|
|
|
|
POCO_GENERATE_PACKAGE(CppParser)
|
2014-12-11 10:17:08 +01:00
|
|
|
|
|
|
|
if (ENABLE_TESTS)
|
2015-01-27 15:52:18 +01:00
|
|
|
add_subdirectory(testsuite)
|
2014-12-11 10:17:08 +01:00
|
|
|
endif ()
|
|
|
|
|