mirror of
https://github.com/pocoproject/poco.git
synced 2025-11-24 06:04:15 +01:00
@@ -1,4 +1,5 @@
|
||||
set(LIBNAME "PocoNetSSL")
|
||||
set(LIBNAME "NetSSL")
|
||||
set(POCO_LIBNAME "Poco${LIBNAME}")
|
||||
|
||||
# Sources
|
||||
file(GLOB SRCS_G "src/*.cpp")
|
||||
@@ -8,26 +9,39 @@ POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||
|
||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||
set_target_properties( ${LIBNAME}
|
||||
add_library( "${LIBNAME}" ${LIB_MODE} ${SRCS} )
|
||||
add_library( "${POCO_LIBNAME}" ALIAS "${LIBNAME}")
|
||||
set_target_properties( "${LIBNAME}"
|
||||
PROPERTIES
|
||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||
DEFINE_SYMBOL NetSSL_EXPORTS)
|
||||
target_link_libraries( ${LIBNAME} PocoCrypto PocoNet PocoUtil PocoFoundation ${OPENSSL_SSL_LIBRARY} ${OPENSSL_CRYPTO_LIBRARY} )
|
||||
OUTPUT_NAME ${POCO_LIBNAME}
|
||||
DEFINE_SYMBOL NetSSL_EXPORTS
|
||||
)
|
||||
|
||||
target_link_libraries( "${LIBNAME}" Crypto Net Util Foundation ${OPENSSL_SSL_LIBRARY} ${OPENSSL_CRYPTO_LIBRARY} )
|
||||
target_include_directories( "${LIBNAME}"
|
||||
PUBLIC
|
||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
|
||||
$<INSTALL_INTERFACE:include>
|
||||
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src
|
||||
)
|
||||
install(
|
||||
DIRECTORY include/Poco
|
||||
DESTINATION include
|
||||
COMPONENT Devel
|
||||
PATTERN ".svn" EXCLUDE
|
||||
)
|
||||
|
||||
install(
|
||||
TARGETS ${LIBNAME}
|
||||
TARGETS "${LIBNAME}" EXPORT "${LIBNAME}Targets"
|
||||
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
||||
ARCHIVE DESTINATION lib${LIB_SUFFIX}
|
||||
RUNTIME DESTINATION bin
|
||||
INCLUDES DESTINATION include
|
||||
)
|
||||
|
||||
POCO_GENERATE_PACKAGE("${LIBNAME}" "${LIBNAME}Targets" "lib/cmake/${PROJECT_NAME}")
|
||||
|
||||
if (ENABLE_TESTS)
|
||||
add_subdirectory(samples)
|
||||
add_subdirectory(testsuite)
|
||||
|
||||
7
NetSSL_OpenSSL/cmake/PocoNetSSLConfig.cmake
Normal file
7
NetSSL_OpenSSL/cmake/PocoNetSSLConfig.cmake
Normal file
@@ -0,0 +1,7 @@
|
||||
include(CMakeFindDependencyMacro)
|
||||
set(CMAKE_PREFIX_PATH ${CMAKE_CURRENT_LIST_DIR})
|
||||
find_dependency(PocoFoundation)
|
||||
find_dependency(PocoUtil)
|
||||
find_dependency(PocoNet)
|
||||
find_dependency(PocoCrypto)
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/PocoNetSSLTargets.cmake")
|
||||
Reference in New Issue
Block a user