mirror of
https://github.com/pocoproject/poco.git
synced 2025-03-24 15:57:19 +01:00
cmake: Cleanup CMakeLists.txt for all components
- Add missing CMakeLists.txt - Use POCO_ macros to improve code structure in XCode/VisualStudio - Better ODBC detection - Remove unnecessary commented out code The CMake documentation recommends explicitly listing source files, but because CMake is not the primary build system GLOB patterns are used for the moment.
This commit is contained in:
parent
65fcaf65a0
commit
7950001803
@ -1,11 +1,20 @@
|
|||||||
set(LIBNAME "mod_poco")
|
set(LIBNAME "mod_poco")
|
||||||
|
|
||||||
include_directories( include ${APACHE_INCLUDE_DIR} ${APRUTIL_INCLUDE_DIR} )
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
|
|
||||||
aux_source_directory(src SRCS)
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
include_directories( "include" )
|
||||||
|
|
||||||
add_library( ${LIBNAME} SHARED ${SRCS} )
|
add_library( ${LIBNAME} SHARED ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME} PROPERTIES VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
set_target_properties( ${LIBNAME}
|
||||||
|
PROPERTIES
|
||||||
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL ApacheHandlers_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} )
|
target_link_libraries( ${LIBNAME} )
|
||||||
|
|
||||||
if (ENABLE_TESTS)
|
if (ENABLE_TESTS)
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_library( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_library( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_library( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_library( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoFoundation )
|
||||||
|
@ -1,20 +1,20 @@
|
|||||||
set(LIBNAME "CppUnit")
|
set(LIBNAME "CppUnit")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/CppUnitException.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/TestCase.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/TestDecorator.cpp
|
|
||||||
src/TestFailure.cpp
|
# Headers
|
||||||
src/TestResult.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/TestRunner.cpp
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
src/TestSuite.cpp
|
|
||||||
src/TextTestResult.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION "1"
|
VERSION "1" SOVERSION "1"
|
||||||
SOVERSION "1")
|
DEFINE_SYMBOL CppUnit_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} )
|
target_link_libraries( ${LIBNAME} )
|
||||||
|
|
||||||
|
if(WIN32)
|
||||||
|
add_subdirectory(WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
29
CppUnit/WinTestRunner/CMakeLists.txt
Normal file
29
CppUnit/WinTestRunner/CMakeLists.txt
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
set(LIBNAME "WinTestRunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( WIN_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( WIN_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( WIN_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
# TODO: Is this flag always required?
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
|
||||||
|
include_directories( "src" )
|
||||||
|
|
||||||
|
add_library( ${LIBNAME} ${LIB_MODE} ${WIN_SRCS} )
|
||||||
|
set_target_properties( ${LIBNAME}
|
||||||
|
PROPERTIES
|
||||||
|
VERSION "1" SOVERSION "1"
|
||||||
|
DEFINE_SYMBOL WinTestRunner_EXPORTS)
|
||||||
|
target_link_libraries( ${LIBNAME} CppUnit )
|
||||||
|
if(WIN32)
|
||||||
|
target_link_libraries( ${LIBNAME} winmm )
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
|
@ -1,27 +1,21 @@
|
|||||||
set(LIBNAME "PocoCrypto")
|
set(LIBNAME "PocoCrypto")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Cipher.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/CipherFactory.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/CipherImpl.cpp
|
|
||||||
src/CipherKey.cpp
|
# Headers
|
||||||
src/CipherKeyImpl.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/CryptoStream.cpp
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
src/CryptoTransform.cpp
|
|
||||||
src/DigestEngine.cpp
|
add_definitions(-D_USRDLL)
|
||||||
src/OpenSSLInitializer.cpp
|
include_directories( "include" )
|
||||||
src/RSACipherImpl.cpp
|
|
||||||
src/RSADigestEngine.cpp
|
|
||||||
src/RSAKey.cpp
|
|
||||||
src/RSAKeyImpl.cpp
|
|
||||||
src/X509Certificate.cpp
|
|
||||||
)
|
|
||||||
add_definitions(-D_USRDLL -DCrypto_EXPORTS)
|
|
||||||
include_directories( include ${OPENSSL_INCLUDE_DIR} )
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME} PROPERTIES VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
set_target_properties( ${LIBNAME}
|
||||||
|
PROPERTIES
|
||||||
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Crypto_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoFoundation ${OPENSSL_LIBRARIES} )
|
target_link_libraries( ${LIBNAME} PocoFoundation ${OPENSSL_LIBRARIES} )
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoCrypto PocoUtil PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoCrypto PocoUtil PocoXML PocoFoundation )
|
||||||
|
@ -1,21 +1,29 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/CryptoTest.cpp
|
|
||||||
src/DigestEngineTest.cpp
|
|
||||||
src/CryptoTestSuite.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/RSATest.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
target_link_libraries( ${TESTUNIT} PocoCrypto PocoNetSSL PocoXML PocoUtil PocoFoundation CppUnit )
|
||||||
target_link_libraries( ${TESTUNIT} PocoCrypto PocoNetSSL PocoXML PocoUtil PocoFoundation CppUnit pthread)
|
if( WIN32)
|
||||||
|
#TODO: Is this flag always required?
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
else()
|
||||||
|
target_link_libraries( ${TESTUNIT} pthread)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
@ -1,46 +1,15 @@
|
|||||||
set(LIBNAME "PocoData")
|
set(LIBNAME "PocoData")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/AbstractBinder.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/AbstractBinding.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/AbstractExtraction.cpp
|
|
||||||
src/AbstractExtractor.cpp
|
|
||||||
src/AbstractPreparation.cpp
|
|
||||||
src/AbstractPreparator.cpp
|
|
||||||
src/ArchiveStrategy.cpp
|
|
||||||
src/Bulk.cpp
|
|
||||||
src/Connector.cpp
|
|
||||||
src/DataException.cpp
|
|
||||||
src/Date.cpp
|
|
||||||
src/DynamicLOB.cpp
|
|
||||||
src/Limit.cpp
|
|
||||||
src/MetaColumn.cpp
|
|
||||||
src/PooledSessionHolder.cpp
|
|
||||||
src/PooledSessionImpl.cpp
|
|
||||||
src/Position.cpp
|
|
||||||
src/Range.cpp
|
|
||||||
src/RecordSet.cpp
|
|
||||||
src/Row.cpp
|
|
||||||
src/RowFilter.cpp
|
|
||||||
src/RowFormatter.cpp
|
|
||||||
src/RowIterator.cpp
|
|
||||||
src/Session.cpp
|
|
||||||
src/SessionFactory.cpp
|
|
||||||
src/SessionImpl.cpp
|
|
||||||
src/SessionPoolContainer.cpp
|
|
||||||
src/SessionPool.cpp
|
|
||||||
src/SimpleRowFormatter.cpp
|
|
||||||
src/SQLChannel.cpp
|
|
||||||
src/Statement.cpp
|
|
||||||
src/StatementCreator.cpp
|
|
||||||
src/StatementImpl.cpp
|
|
||||||
src/Time.cpp
|
|
||||||
src/Transaction.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
if (NOT POCO_STATIC)
|
||||||
add_definitions(-DData_EXPORTS -DTHREADSAFE -DODBC_EXPORTS -DMySQL_EXPORTS -DSQLite_EXPORTS)
|
add_definitions(-DTHREADSAFE)
|
||||||
endif (NOT POCO_STATIC)
|
endif (NOT POCO_STATIC)
|
||||||
|
|
||||||
if(MSVC AND NOT(MSVC_VERSION LESS 1400))
|
if(MSVC AND NOT(MSVC_VERSION LESS 1400))
|
||||||
@ -51,7 +20,8 @@ endif()
|
|||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Data_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -72,19 +42,25 @@ add_subdirectory( SQLite )
|
|||||||
|
|
||||||
find_package(MySQL)
|
find_package(MySQL)
|
||||||
if(MYSQL_FOUND)
|
if(MYSQL_FOUND)
|
||||||
|
include_directories("${MYSQL_INCLUDE_DIR}")
|
||||||
|
message(STATUS "MySQL Support Enabled")
|
||||||
add_subdirectory( MySQL )
|
add_subdirectory( MySQL )
|
||||||
|
else()
|
||||||
|
message(STATUS "MySQL Support Disabled - no MySQL library")
|
||||||
endif(MYSQL_FOUND)
|
endif(MYSQL_FOUND)
|
||||||
|
|
||||||
find_package(ODBC)
|
find_package(ODBC)
|
||||||
if(CMAKE_SYSTEM MATCHES "Windows")
|
if(CMAKE_SYSTEM MATCHES "Windows")
|
||||||
|
set(ODBC_LIBRARIES "")
|
||||||
message(STATUS "Windows native ODBC Support Enabled")
|
message(STATUS "Windows native ODBC Support Enabled")
|
||||||
add_subdirectory( ODBC )
|
add_subdirectory( ODBC )
|
||||||
else ()
|
else ()
|
||||||
if ( ${UNIX_ODBC_CONFIG} STREQUAL UNIX_ODBC_CONFIG-NOTFOUND AND ${IODBC_CONFIG} STREQUAL IODBC_CONFIG-NOTFOUND)
|
if (ODBC_FOUND)
|
||||||
message(STATUS "ODBC Support Disabled - no ODBC runtime")
|
include_directories("${ODBC_INCLUDE_DIRECTORIES}")
|
||||||
else ()
|
|
||||||
message(STATUS "ODBC Support Enabled")
|
message(STATUS "ODBC Support Enabled")
|
||||||
add_subdirectory( ODBC )
|
add_subdirectory( ODBC )
|
||||||
|
else ()
|
||||||
|
message(STATUS "ODBC Support Disabled - no ODBC runtime")
|
||||||
endif ()
|
endif ()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
@ -1,26 +1,22 @@
|
|||||||
set(LIBNAME "PocoDataMySQL")
|
set(LIBNAME "PocoDataMySQL")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Binder.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Connector.cpp
|
POCO_SOURCES_AUTO( MYSQL_SRCS ${SRCS_G})
|
||||||
src/Extractor.cpp
|
|
||||||
src/MySQLException.cpp
|
# Headers
|
||||||
src/MySQLStatementImpl.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/ResultMetadata.cpp
|
POCO_HEADERS_AUTO( MYSQL_SRCS ${HDRS_G})
|
||||||
src/SessionHandle.cpp
|
|
||||||
src/SessionImpl.cpp
|
|
||||||
src/StatementExecutor.cpp
|
|
||||||
src/Utility.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
add_definitions(-DTHREADSAFE -DNO_TCL)
|
add_definitions(-DTHREADSAFE -DNO_TCL)
|
||||||
|
|
||||||
include_directories( include ${MYSQL_INCLUDE_DIR})
|
include_directories( "include" )
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${MYSQL_SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL MySQL_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoData PocoFoundation ${MYSQL_LIB})
|
target_link_libraries( ${LIBNAME} PocoData PocoFoundation ${MYSQL_LIB})
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -28,7 +24,7 @@ install(
|
|||||||
DESTINATION include
|
DESTINATION include
|
||||||
PATTERN ".svn" EXCLUDE
|
PATTERN ".svn" EXCLUDE
|
||||||
)
|
)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
TARGETS ${LIBNAME}
|
TARGETS ${LIBNAME}
|
||||||
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
||||||
|
@ -1,19 +1,18 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/MySQLTest.cpp
|
|
||||||
src/MySQLTestSuite.cpp
|
|
||||||
src/SQLExecutor.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
target_link_libraries( ${TESTUNIT} PocoDataMySQL PocoData PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoDataMySQL PocoData PocoFoundation CppUnit )
|
||||||
|
|
||||||
|
@ -1,38 +1,30 @@
|
|||||||
set(LIBNAME "PocoDataODBC")
|
set(LIBNAME "PocoDataODBC")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Binder.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/ConnectionHandle.cpp
|
POCO_SOURCES_AUTO( ODBC_SRCS ${SRCS_G})
|
||||||
src/Connector.cpp
|
|
||||||
src/EnvironmentHandle.cpp
|
# Headers
|
||||||
src/Extractor.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/ODBCException.cpp
|
POCO_HEADERS_AUTO( ODBC_SRCS ${HDRS_G})
|
||||||
src/ODBCMetaColumn.cpp
|
|
||||||
src/ODBCStatementImpl.cpp
|
|
||||||
src/Parameter.cpp
|
|
||||||
src/Preparator.cpp
|
|
||||||
src/SessionImpl.cpp
|
|
||||||
src/TypeInfo.cpp
|
|
||||||
src/Unicode.cpp
|
|
||||||
src/Utility.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
add_definitions( ${ODBC_CFLAGS} )
|
add_definitions( ${ODBC_CFLAGS} )
|
||||||
|
|
||||||
include_directories( include )
|
include_directories( "include" )
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${ODBC_SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
target_link_libraries( ${LIBNAME} PocoData PocoFoundation ${ODBC_LINK_FLAGS})
|
DEFINE_SYMBOL ODBC_EXPORTS)
|
||||||
|
target_link_libraries( ${LIBNAME} PocoData PocoFoundation ${ODBC_LIBRARIES})
|
||||||
|
|
||||||
install(
|
install(
|
||||||
DIRECTORY include/Poco
|
DIRECTORY include/Poco
|
||||||
DESTINATION include
|
DESTINATION include
|
||||||
PATTERN ".svn" EXCLUDE
|
PATTERN ".svn" EXCLUDE
|
||||||
)
|
)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
TARGETS ${LIBNAME}
|
TARGETS ${LIBNAME}
|
||||||
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
||||||
|
@ -1,26 +1,22 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/ODBCAccessTest.cpp
|
|
||||||
src/ODBCDB2Test.cpp
|
|
||||||
src/ODBCMySQLTest.cpp
|
|
||||||
src/ODBCOracleTest.cpp
|
|
||||||
src/ODBCPostgreSQLTest.cpp
|
|
||||||
src/ODBCSQLServerTest.cpp
|
|
||||||
src/ODBCSQLiteTest.cpp
|
|
||||||
src/ODBCTest.cpp
|
|
||||||
src/ODBCTestSuite.cpp
|
|
||||||
src/SQLExecutor.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
# Sources
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
target_link_libraries( ${TESTUNIT} PocoDataODBC PocoData PocoFoundation CppUnit )
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
|
target_link_libraries( ${TESTUNIT} PocoDataODBC PocoData PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
@ -1,33 +1,39 @@
|
|||||||
set(LIBNAME "PocoDataSQLite")
|
set(LIBNAME "PocoDataSQLite")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Binder.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Connector.cpp
|
POCO_SOURCES_AUTO( SQLITE_SRCS ${SRCS_G})
|
||||||
src/Extractor.cpp
|
|
||||||
src/Notifier.cpp
|
|
||||||
src/SessionImpl.cpp
|
|
||||||
src/SQLiteException.cpp
|
|
||||||
src/SQLiteStatementImpl.cpp
|
|
||||||
src/Utility.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
include_directories( "include" src )
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SQLITE_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
include_directories( "include" "src" )
|
||||||
|
|
||||||
if (POCO_UNBUNDLED)
|
if (POCO_UNBUNDLED)
|
||||||
find_package(SQLite3)
|
find_package(SQLite3)
|
||||||
set(DATASQLITELIBS PocoData PocoFoundation ${SQLITE3_LIBRARIES})
|
set(DATASQLITELIBS PocoData PocoFoundation ${SQLITE3_LIBRARIES})
|
||||||
include_directories(${SQLITE3_INCLUDE_DIRS})
|
include_directories("${SQLITE3_INCLUDE_DIRS}")
|
||||||
else()
|
else()
|
||||||
set(SRCS ${SRCS} src/sqlite3.c)
|
# sqlite3
|
||||||
|
POCO_SOURCES( SQLITE_SRCS sqlite3
|
||||||
|
src/sqlite3.c
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_HEADERS( SQLITE_SRCS sqlite3
|
||||||
|
src/sqlite3.h
|
||||||
|
)
|
||||||
|
|
||||||
set(DATASQLITELIBS PocoData PocoFoundation)
|
set(DATASQLITELIBS PocoData PocoFoundation)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_definitions(-DSQLITE_THREADSAFE=1 -DSQLITE_DISABLE_LFS -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_COMPLETE -DSQLITE_OMIT_TCL_VARIABLE -DSQLITE_OMIT_DEPRECATED)
|
add_definitions(-DSQLITE_THREADSAFE=1 -DSQLITE_DISABLE_LFS -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_COMPLETE -DSQLITE_OMIT_TCL_VARIABLE -DSQLITE_OMIT_DEPRECATED)
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SQLITE_SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL SQLite_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} ${DATASQLITELIBS} )
|
target_link_libraries( ${LIBNAME} ${DATASQLITELIBS} )
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -1,18 +1,23 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/SQLiteTest.cpp
|
|
||||||
src/SQLiteTestSuite.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
# Sources
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
target_link_libraries( ${TESTUNIT} PocoDataSQLite PocoData PocoFoundation CppUnit )
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
|
target_link_libraries( ${TESTUNIT} PocoDataSQLite PocoData PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
#TODO: Is this flag always required?
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoNet PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoDataSQLite PocoData PocoNet PocoFoundation )
|
||||||
|
@ -1,26 +1,27 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Binder.cpp
|
|
||||||
src/Connector.cpp
|
|
||||||
src/DataTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/DataTestSuite.cpp
|
|
||||||
src/Extractor.cpp
|
|
||||||
src/Preparator.cpp
|
|
||||||
src/SessionImpl.cpp
|
|
||||||
src/SessionPoolTest.cpp
|
|
||||||
src/TestStatementImpl.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
#TODO: Why is this file there? It doesn't compile if it is include in the sources
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS OFF
|
||||||
|
src/StatementImpl.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoData PocoUtil PocoXML PocoFoundation CppUnit)
|
target_link_libraries( ${TESTUNIT} PocoData PocoUtil PocoXML PocoFoundation CppUnit)
|
||||||
|
if( WIN32)
|
||||||
|
#TODO: Is this flag always required?
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
@ -1,182 +1,32 @@
|
|||||||
set(LIBNAME "PocoFoundation")
|
set(LIBNAME "PocoFoundation")
|
||||||
|
|
||||||
if (WIN32)
|
# Sources
|
||||||
# cmake has CMAKE_RC_COMPILER, but no message compiler
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
if ("${CMAKE_GENERATOR}" MATCHES "Visual Studio")
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
# this path is only present for 2008+, but we currently require PATH to
|
|
||||||
# be set up anyway
|
|
||||||
get_filename_component(sdk_dir "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows;CurrentInstallFolder]" REALPATH)
|
|
||||||
get_filename_component(kit_dir "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows Kits\\Installed Roots;KitsRoot]" REALPATH)
|
|
||||||
if (X64)
|
|
||||||
set(sdk_bindir "${sdk_dir}/bin/x64")
|
|
||||||
set(kit_bindir "${kit_dir}/bin/x64")
|
|
||||||
else (X64)
|
|
||||||
set(sdk_bindir "${sdk_dir}/bin")
|
|
||||||
set(kit_bindir "${kit_dir}/bin/x86")
|
|
||||||
endif (X64)
|
|
||||||
endif ()
|
|
||||||
find_program(CMAKE_MC_COMPILER mc.exe HINTS "${sdk_bindir}" "${kit_bindir}"
|
|
||||||
DOC "path to message compiler")
|
|
||||||
if (NOT CMAKE_MC_COMPILER)
|
|
||||||
message(FATAL_ERROR "message compiler not found: required to build")
|
|
||||||
endif (NOT CMAKE_MC_COMPILER)
|
|
||||||
message(STATUS "Found message compiler: ${CMAKE_MC_COMPILER}")
|
|
||||||
mark_as_advanced(CMAKE_MC_COMPILER)
|
|
||||||
endif(WIN32)
|
|
||||||
|
|
||||||
set( BASE_SRCS
|
# Headers
|
||||||
src/ASCIIEncoding.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/Ascii.cpp
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
src/AtomicCounter.cpp
|
|
||||||
src/AbstractObserver.cpp
|
# Platform Specific
|
||||||
src/ActiveDispatcher.cpp
|
POCO_SOURCES_AUTO_PLAT( SRCS OPENVMS src/OpcomChannel.cpp )
|
||||||
src/ArchiveStrategy.cpp
|
POCO_HEADERS_AUTO( SRCS include/Poco/OpcomChannel.h )
|
||||||
src/AsyncChannel.cpp
|
|
||||||
src/Base64Decoder.cpp
|
POCO_SOURCES_AUTO_PLAT( SRCS UNIX src/SyslogChannel.cpp )
|
||||||
src/Base64Encoder.cpp
|
POCO_HEADERS_AUTO( SRCS include/Poco/SyslogChannel.h )
|
||||||
src/Base32Decoder.cpp
|
|
||||||
src/Base32Encoder.cpp
|
POCO_SOURCES_AUTO_PLAT( SRCS WIN32
|
||||||
src/BinaryReader.cpp
|
src/WindowsConsoleChannel.cpp
|
||||||
src/BinaryWriter.cpp
|
src/EventLogChannel.cpp
|
||||||
src/Bugcheck.cpp
|
)
|
||||||
src/ByteOrder.cpp
|
|
||||||
src/Channel.cpp
|
POCO_HEADERS_AUTO( SRCS
|
||||||
src/Checksum.cpp
|
include/Poco/WindowsConsoleChannel.h
|
||||||
src/Clock.cpp
|
include/Poco/EventLogChannel.h
|
||||||
src/Condition.cpp
|
)
|
||||||
src/Configurable.cpp
|
|
||||||
src/ConsoleChannel.cpp
|
# Messages
|
||||||
src/CountingStream.cpp
|
POCO_MESSAGES( SRCS Logging src/pocomsg.mc)
|
||||||
src/DateTime.cpp
|
|
||||||
src/DateTimeFormat.cpp
|
|
||||||
src/DateTimeFormatter.cpp
|
|
||||||
src/DateTimeParser.cpp
|
|
||||||
src/Debugger.cpp
|
|
||||||
src/DeflatingStream.cpp
|
|
||||||
src/DigestEngine.cpp
|
|
||||||
src/DigestStream.cpp
|
|
||||||
src/DirectoryIterator.cpp
|
|
||||||
src/DirectoryIteratorStrategy.cpp
|
|
||||||
src/DirectoryWatcher.cpp
|
|
||||||
src/Environment.cpp
|
|
||||||
src/Error.cpp
|
|
||||||
src/ErrorHandler.cpp
|
|
||||||
src/Event.cpp
|
|
||||||
src/EventArgs.cpp
|
|
||||||
src/Exception.cpp
|
|
||||||
src/FPEnvironment.cpp
|
|
||||||
src/File.cpp
|
|
||||||
src/FIFOBufferStream.cpp
|
|
||||||
src/FileChannel.cpp
|
|
||||||
src/FileStream.cpp
|
|
||||||
src/FileStreamFactory.cpp
|
|
||||||
src/Format.cpp
|
|
||||||
src/Formatter.cpp
|
|
||||||
src/FormattingChannel.cpp
|
|
||||||
src/Glob.cpp
|
|
||||||
src/Hash.cpp
|
|
||||||
src/HashStatistic.cpp
|
|
||||||
src/HexBinaryDecoder.cpp
|
|
||||||
src/HexBinaryEncoder.cpp
|
|
||||||
src/InflatingStream.cpp
|
|
||||||
src/Latin1Encoding.cpp
|
|
||||||
src/Latin2Encoding.cpp
|
|
||||||
src/Latin9Encoding.cpp
|
|
||||||
src/LineEndingConverter.cpp
|
|
||||||
src/LocalDateTime.cpp
|
|
||||||
src/LogFile.cpp
|
|
||||||
src/LogStream.cpp
|
|
||||||
src/Logger.cpp
|
|
||||||
src/LoggingFactory.cpp
|
|
||||||
src/LoggingRegistry.cpp
|
|
||||||
src/MD4Engine.cpp
|
|
||||||
src/MD5Engine.cpp
|
|
||||||
src/Manifest.cpp
|
|
||||||
src/MemoryPool.cpp
|
|
||||||
src/MemoryStream.cpp
|
|
||||||
src/Message.cpp
|
|
||||||
src/Mutex.cpp
|
|
||||||
src/NamedEvent.cpp
|
|
||||||
src/NamedMutex.cpp
|
|
||||||
src/NestedDiagnosticContext.cpp
|
|
||||||
src/Notification.cpp
|
|
||||||
src/NotificationCenter.cpp
|
|
||||||
src/NotificationQueue.cpp
|
|
||||||
src/TimedNotificationQueue.cpp
|
|
||||||
src/PriorityNotificationQueue.cpp
|
|
||||||
src/NullChannel.cpp
|
|
||||||
src/NullStream.cpp
|
|
||||||
src/NumberFormatter.cpp
|
|
||||||
src/NumberParser.cpp
|
|
||||||
src/NumericString.cpp
|
|
||||||
src/Path.cpp
|
|
||||||
src/PatternFormatter.cpp
|
|
||||||
src/Pipe.cpp
|
|
||||||
src/PipeImpl.cpp
|
|
||||||
src/PipeStream.cpp
|
|
||||||
src/Process.cpp
|
|
||||||
src/PurgeStrategy.cpp
|
|
||||||
src/RWLock.cpp
|
|
||||||
src/Random.cpp
|
|
||||||
src/RandomStream.cpp
|
|
||||||
src/RefCountedObject.cpp
|
|
||||||
src/RegularExpression.cpp
|
|
||||||
src/RotateStrategy.cpp
|
|
||||||
src/Runnable.cpp
|
|
||||||
src/SHA1Engine.cpp
|
|
||||||
src/Semaphore.cpp
|
|
||||||
src/SharedLibrary.cpp
|
|
||||||
src/SharedMemory.cpp
|
|
||||||
src/SignalHandler.cpp
|
|
||||||
src/SimpleFileChannel.cpp
|
|
||||||
src/SortedDirectoryIterator.cpp
|
|
||||||
src/SplitterChannel.cpp
|
|
||||||
src/Stopwatch.cpp
|
|
||||||
src/StreamChannel.cpp
|
|
||||||
src/StreamConverter.cpp
|
|
||||||
src/StreamCopier.cpp
|
|
||||||
src/StreamTokenizer.cpp
|
|
||||||
src/String.cpp
|
|
||||||
src/NumericString.cpp
|
|
||||||
src/StringTokenizer.cpp
|
|
||||||
src/SynchronizedObject.cpp
|
|
||||||
src/Task.cpp
|
|
||||||
src/TaskManager.cpp
|
|
||||||
src/TaskNotification.cpp
|
|
||||||
src/TeeStream.cpp
|
|
||||||
src/TemporaryFile.cpp
|
|
||||||
src/TextConverter.cpp
|
|
||||||
src/TextEncoding.cpp
|
|
||||||
src/TextIterator.cpp
|
|
||||||
src/TextBufferIterator.cpp
|
|
||||||
src/Thread.cpp
|
|
||||||
src/ThreadTarget.cpp
|
|
||||||
src/ThreadLocal.cpp
|
|
||||||
src/ThreadPool.cpp
|
|
||||||
src/Timer.cpp
|
|
||||||
src/Timespan.cpp
|
|
||||||
src/Timestamp.cpp
|
|
||||||
src/Timezone.cpp
|
|
||||||
src/Token.cpp
|
|
||||||
src/URI.cpp
|
|
||||||
src/URIStreamFactory.cpp
|
|
||||||
src/URIStreamOpener.cpp
|
|
||||||
src/UTF16Encoding.cpp
|
|
||||||
src/UTF32Encoding.cpp
|
|
||||||
src/UTF8Encoding.cpp
|
|
||||||
src/UTF8String.cpp
|
|
||||||
src/UUID.cpp
|
|
||||||
src/UUIDGenerator.cpp
|
|
||||||
src/Unicode.cpp
|
|
||||||
src/UnicodeConverter.cpp
|
|
||||||
src/Var.cpp
|
|
||||||
src/VarHolder.cpp
|
|
||||||
src/VarIterator.cpp
|
|
||||||
src/Void.cpp
|
|
||||||
src/Windows1250Encoding.cpp
|
|
||||||
src/Windows1251Encoding.cpp
|
|
||||||
src/Windows1252Encoding.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
||||||
# The configuration will fail if the packages are not found
|
# The configuration will fail if the packages are not found
|
||||||
@ -186,7 +36,7 @@ if (POCO_UNBUNDLED)
|
|||||||
include_directories(${PCRE_INCLUDE_DIRS})
|
include_directories(${PCRE_INCLUDE_DIRS})
|
||||||
|
|
||||||
#HACK: Unicode.cpp requires functions from these files. The can't be taken from the library
|
#HACK: Unicode.cpp requires functions from these files. The can't be taken from the library
|
||||||
list(APPEND BASE_SRCS
|
POCO_SOURCES( SRCS RegExp
|
||||||
src/pcre_ucd.c
|
src/pcre_ucd.c
|
||||||
src/pcre_tables.c
|
src/pcre_tables.c
|
||||||
)
|
)
|
||||||
@ -195,8 +45,8 @@ if (POCO_UNBUNDLED)
|
|||||||
set(SYSLIBS ${SYSLIBS} ${ZLIB_LIBRARIES})
|
set(SYSLIBS ${SYSLIBS} ${ZLIB_LIBRARIES})
|
||||||
include_directories(${ZLIB_INCLUDE_DIRS})
|
include_directories(${ZLIB_INCLUDE_DIRS})
|
||||||
else()
|
else()
|
||||||
# PCRE
|
# pcre
|
||||||
list(APPEND BASE_SRCS
|
POCO_SOURCES( SRCS pcre
|
||||||
src/pcre_chartables.c
|
src/pcre_chartables.c
|
||||||
src/pcre_compile.c
|
src/pcre_compile.c
|
||||||
src/pcre_exec.c
|
src/pcre_exec.c
|
||||||
@ -213,8 +63,13 @@ else()
|
|||||||
src/pcre_xclass.c
|
src/pcre_xclass.c
|
||||||
)
|
)
|
||||||
|
|
||||||
# ZLIB
|
# zlib
|
||||||
list(APPEND BASE_SRCS
|
POCO_HEADERS( SRCS zlib
|
||||||
|
include/Poco/zconf.h
|
||||||
|
include/Poco/zlib.h
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES( SRCS zlib
|
||||||
src/adler32.c
|
src/adler32.c
|
||||||
src/compress.c
|
src/compress.c
|
||||||
src/crc32.c
|
src/crc32.c
|
||||||
@ -228,47 +83,18 @@ else()
|
|||||||
)
|
)
|
||||||
endif (POCO_UNBUNDLED)
|
endif (POCO_UNBUNDLED)
|
||||||
|
|
||||||
set(WIN_SRCS
|
|
||||||
src/EventLogChannel.cpp
|
|
||||||
src/WindowsConsoleChannel.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
if (WIN32)
|
|
||||||
set(RES_SRCS ${CMAKE_SOURCE_DIR}/Foundation/src/pocomsg.h)
|
|
||||||
set_source_files_properties(${RES_SRCS} PROPERTIES GENERATED true)
|
|
||||||
add_custom_command(
|
|
||||||
OUTPUT ${RES_SRCS}
|
|
||||||
DEPENDS ${CMAKE_SOURCE_DIR}/Foundation/src/pocomsg.mc
|
|
||||||
COMMAND ${CMAKE_MC_COMPILER}
|
|
||||||
ARGS
|
|
||||||
-h ${CMAKE_SOURCE_DIR}/Foundation/src
|
|
||||||
-r ${CMAKE_SOURCE_DIR}/Foundation/src
|
|
||||||
${CMAKE_SOURCE_DIR}/Foundation/src/pocomsg.mc
|
|
||||||
VERBATIM # recommended: p260
|
|
||||||
)
|
|
||||||
list(APPEND WIN_SRCS ${RES_SRCS})
|
|
||||||
endif (WIN32)
|
|
||||||
|
|
||||||
set(LIN_SRCS
|
|
||||||
src/SyslogChannel.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
# TODO: Use this sources somewhere if built on OpenVMS
|
|
||||||
set(OPENVMS_SRCS
|
|
||||||
src/OpcomChannel.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
if(CMAKE_SYSTEM MATCHES "Windows")
|
if(CMAKE_SYSTEM MATCHES "Windows")
|
||||||
set(SRCS ${BASE_SRCS} ${WIN_SRCS})
|
add_definitions( -DPCRE_STATIC)
|
||||||
add_definitions( -DPCRE_STATIC -DFoundation_EXPORTS)
|
|
||||||
set(SYSLIBS ${SYSLIBS} iphlpapi)
|
set(SYSLIBS ${SYSLIBS} iphlpapi)
|
||||||
else (CMAKE_SYSTEM MATCHES "Windows")
|
else (CMAKE_SYSTEM MATCHES "Windows")
|
||||||
set(SRCS ${BASE_SRCS} ${LIN_SRCS})
|
|
||||||
add_definitions( -DPCRE_STATIC)
|
add_definitions( -DPCRE_STATIC)
|
||||||
endif(CMAKE_SYSTEM MATCHES "Windows")
|
endif(CMAKE_SYSTEM MATCHES "Windows")
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS})
|
||||||
set_target_properties( ${LIBNAME} PROPERTIES VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
set_target_properties( ${LIBNAME}
|
||||||
|
PROPERTIES
|
||||||
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Foundation_EXPORTS)
|
||||||
if (${CMAKE_CXX_COMPILER_ID} MATCHES "SunPro")
|
if (${CMAKE_CXX_COMPILER_ID} MATCHES "SunPro")
|
||||||
set_target_properties( ${LIBNAME} PROPERTIES LINK_FLAGS "-library=stlport4")
|
set_target_properties( ${LIBNAME} PROPERTIES LINK_FLAGS "-library=stlport4")
|
||||||
endif (${CMAKE_CXX_COMPILER_ID} MATCHES "SunPro")
|
endif (${CMAKE_CXX_COMPILER_ID} MATCHES "SunPro")
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${CMAKE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation)
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation)
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoFoundation )
|
||||||
|
@ -1,172 +1,55 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/ActiveDispatcherTest.cpp
|
|
||||||
src/ActiveMethodTest.cpp
|
|
||||||
src/ActivityTest.cpp
|
|
||||||
src/AnyTest.cpp
|
|
||||||
src/ArrayTest.cpp
|
|
||||||
src/AutoPtrTest.cpp
|
|
||||||
src/AutoReleasePoolTest.cpp
|
|
||||||
src/Base32Test.cpp
|
|
||||||
src/Base64Test.cpp
|
|
||||||
src/BasicEventTest.cpp
|
|
||||||
src/BinaryReaderWriterTest.cpp
|
|
||||||
src/ByteOrderTest.cpp
|
|
||||||
src/CacheTestSuite.cpp
|
|
||||||
src/ChannelTest.cpp
|
|
||||||
src/ClassLoaderTest.cpp
|
|
||||||
src/ClockTest.cpp
|
|
||||||
src/ConditionTest.cpp
|
|
||||||
src/CoreTest.cpp
|
|
||||||
src/CoreTestSuite.cpp
|
|
||||||
src/CountingStreamTest.cpp
|
|
||||||
src/CryptTestSuite.cpp
|
|
||||||
src/DateTimeFormatterTest.cpp
|
|
||||||
src/DateTimeParserTest.cpp
|
|
||||||
src/DateTimeTest.cpp
|
|
||||||
src/DateTimeTestSuite.cpp
|
|
||||||
src/DigestStreamTest.cpp
|
|
||||||
src/DirectoryIteratorsTest.cpp
|
|
||||||
src/DirectoryWatcherTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/DummyDelegate.cpp
|
|
||||||
src/DynamicFactoryTest.cpp
|
|
||||||
src/DynamicTestSuite.cpp
|
|
||||||
src/EventTestSuite.cpp
|
|
||||||
src/ExpireCacheTest.cpp
|
|
||||||
src/ExpireLRUCacheTest.cpp
|
|
||||||
src/FIFOEventTest.cpp
|
|
||||||
src/FIFOBufferStreamTest.cpp
|
|
||||||
src/FPETest.cpp
|
|
||||||
src/FileChannelTest.cpp
|
|
||||||
src/FileStreamTest.cpp
|
|
||||||
src/FileTest.cpp
|
|
||||||
src/FilesystemTestSuite.cpp
|
|
||||||
src/FormatTest.cpp
|
|
||||||
src/FoundationTestSuite.cpp
|
|
||||||
src/GlobTest.cpp
|
|
||||||
src/HMACEngineTest.cpp
|
|
||||||
src/HashMapTest.cpp
|
|
||||||
src/HashSetTest.cpp
|
|
||||||
src/HashTableTest.cpp
|
|
||||||
src/HashingTestSuite.cpp
|
|
||||||
src/HexBinaryTest.cpp
|
|
||||||
src/LRUCacheTest.cpp
|
|
||||||
src/LineEndingConverterTest.cpp
|
|
||||||
src/LinearHashTableTest.cpp
|
|
||||||
src/ListMapTest.cpp
|
|
||||||
src/LocalDateTimeTest.cpp
|
|
||||||
src/LogStreamTest.cpp
|
|
||||||
src/LoggerTest.cpp
|
|
||||||
src/LoggingFactoryTest.cpp
|
|
||||||
src/LoggingRegistryTest.cpp
|
|
||||||
src/LoggingTestSuite.cpp
|
|
||||||
src/MD4EngineTest.cpp
|
|
||||||
src/MD5EngineTest.cpp
|
|
||||||
src/ManifestTest.cpp
|
|
||||||
src/MemoryPoolTest.cpp
|
|
||||||
src/MemoryStreamTest.cpp
|
|
||||||
src/NDCTest.cpp
|
|
||||||
src/NamedEventTest.cpp
|
|
||||||
src/NamedMutexTest.cpp
|
|
||||||
src/NamedTuplesTest.cpp
|
|
||||||
src/NotificationCenterTest.cpp
|
|
||||||
src/NotificationQueueTest.cpp
|
|
||||||
src/ObjectPoolTest.cpp
|
|
||||||
src/PriorityNotificationQueueTest.cpp
|
|
||||||
src/TimedNotificationQueueTest.cpp
|
|
||||||
src/NotificationsTestSuite.cpp
|
|
||||||
src/NullStreamTest.cpp
|
|
||||||
src/NumberFormatterTest.cpp
|
|
||||||
src/NumberParserTest.cpp
|
|
||||||
src/PathTest.cpp
|
|
||||||
src/PatternFormatterTest.cpp
|
|
||||||
src/PBKDF2EngineTest.cpp
|
|
||||||
src/PriorityEventTest.cpp
|
|
||||||
src/ProcessTest.cpp
|
|
||||||
src/ProcessesTestSuite.cpp
|
|
||||||
src/RWLockTest.cpp
|
|
||||||
src/RandomStreamTest.cpp
|
|
||||||
src/RandomTest.cpp
|
|
||||||
src/RegularExpressionTest.cpp
|
|
||||||
src/SHA1EngineTest.cpp
|
|
||||||
src/SemaphoreTest.cpp
|
|
||||||
src/SharedLibraryTest.cpp
|
|
||||||
src/SharedLibraryTestSuite.cpp
|
|
||||||
src/SharedMemoryTest.cpp
|
|
||||||
src/SharedPtrTest.cpp
|
|
||||||
src/SimpleFileChannelTest.cpp
|
|
||||||
src/SimpleHashTableTest.cpp
|
|
||||||
src/StopwatchTest.cpp
|
|
||||||
src/StreamConverterTest.cpp
|
|
||||||
src/StreamCopierTest.cpp
|
|
||||||
src/StreamTokenizerTest.cpp
|
|
||||||
src/StreamsTestSuite.cpp
|
|
||||||
src/StringTest.cpp
|
|
||||||
src/StringTokenizerTest.cpp
|
|
||||||
src/TaskManagerTest.cpp
|
|
||||||
src/TaskTest.cpp
|
|
||||||
src/TaskTestSuite.cpp
|
|
||||||
src/TeeStreamTest.cpp
|
|
||||||
src/TestChannel.cpp
|
|
||||||
src/TestPlugin.cpp
|
|
||||||
src/TextConverterTest.cpp
|
|
||||||
src/TextEncodingTest.cpp
|
|
||||||
src/TextIteratorTest.cpp
|
|
||||||
src/TextBufferIteratorTest.cpp
|
|
||||||
src/TextTestSuite.cpp
|
|
||||||
src/ThreadLocalTest.cpp
|
|
||||||
src/ThreadPoolTest.cpp
|
|
||||||
src/ThreadTest.cpp
|
|
||||||
src/ThreadingTestSuite.cpp
|
|
||||||
src/TimerTest.cpp
|
|
||||||
src/TimespanTest.cpp
|
|
||||||
src/TimestampTest.cpp
|
|
||||||
src/TimezoneTest.cpp
|
|
||||||
src/TuplesTest.cpp
|
|
||||||
src/TypeListTest.cpp
|
|
||||||
src/URIStreamOpenerTest.cpp
|
|
||||||
src/URITest.cpp
|
|
||||||
src/URITestSuite.cpp
|
|
||||||
src/UTF8StringTest.cpp
|
|
||||||
src/UUIDGeneratorTest.cpp
|
|
||||||
src/UUIDTest.cpp
|
|
||||||
src/UUIDTestSuite.cpp
|
|
||||||
src/UniqueExpireCacheTest.cpp
|
|
||||||
src/UnicodeConverterTest.cpp
|
|
||||||
src/UniqueExpireLRUCacheTest.cpp
|
|
||||||
src/VarTest.cpp
|
|
||||||
src/ZLibTest.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
file(GLOB SRCS_G_REMOVE
|
||||||
|
src/TestApp.cpp
|
||||||
|
src/TestApp_WINCE.cpp
|
||||||
|
src/TestLibrary.cpp
|
||||||
|
src/TestPlugin.cpp
|
||||||
|
)
|
||||||
|
list(REMOVE_ITEM SRCS_G ${SRCS_G_REMOVE})
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_PLAT( TEST_SRCS FoundationTest WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} COMMAND ${TESTUNIT} -all)
|
||||||
set_tests_properties(${LIBNAME} PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=.") # The SharedLibaryTest has to look for shared libraries in the working directory
|
set_tests_properties(${LIBNAME} PROPERTIES ENVIRONMENT "LD_LIBRARY_PATH=.") # The SharedLibaryTest has to look for shared libraries in the working directory
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
||||||
target_link_libraries( ${TESTUNIT} PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoFoundation CppUnit )
|
||||||
if (NOT ANDROID)
|
if( WIN32)
|
||||||
target_link_libraries( ${TESTUNIT} pthread)
|
add_definitions("-D_AFXDLL")
|
||||||
endif ()
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
else()
|
||||||
|
target_link_libraries( ${TESTUNIT} pthread)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
# The test is run in the build directory. So the test data is copied there too
|
# The test is run in the runtime directory. So the test data is copied there too
|
||||||
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/data ${CMAKE_CURRENT_BINARY_DIR}/data )
|
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/data ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/data )
|
||||||
|
|
||||||
|
# TestApp
|
||||||
add_executable( TestApp src/TestApp.cpp )
|
add_executable( TestApp src/TestApp.cpp )
|
||||||
# The test is run in the build directory. So the TestApp is built there too because it is used by the tests
|
# The test is run in the runtime directory. So the TestApp is built there too because it is used by the tests
|
||||||
set_target_properties( TestApp PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} )
|
set_target_properties( TestApp PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} )
|
||||||
#set_target_properties( TestApp PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( TestApp PocoFoundation )
|
target_link_libraries( TestApp PocoFoundation )
|
||||||
|
# TODO: Add TestApp_WINCE
|
||||||
|
|
||||||
add_library( TestLibrary SHARED src/TestLibrary.cpp )
|
# TestLibrary
|
||||||
set_target_properties( TestLibrary PROPERTIES PREFIX "") # The test requires the library named TestLibrary. By default it is prefixed with lib.
|
add_library( TestLibrary SHARED src/TestLibrary.cpp src/TestPlugin.cpp src/TestPlugin.h )
|
||||||
# The test is run in the build directory. So the TestLibrary is built there too because it is used by the tests
|
set_target_properties( TestLibrary PROPERTIES PREFIX "" DEBUG_POSTFIX "") # The test requires the library named TestLibrary. By default it is prefixed with lib.
|
||||||
set_target_properties( TestLibrary PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} )
|
# The test is run in the runtime directory. So the TestLibrary is built there too because it is used by the tests
|
||||||
#set_target_properties( TestLibrary PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
set_target_properties( TestLibrary PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} )
|
||||||
target_link_libraries( TestLibrary PocoFoundation )
|
target_link_libraries( TestLibrary PocoFoundation )
|
||||||
|
|
||||||
|
@ -1,27 +1,18 @@
|
|||||||
set(LIBNAME "PocoJSON")
|
set(LIBNAME "PocoJSON")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Array.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Handler.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/JSONException.cpp
|
|
||||||
src/Object.cpp
|
|
||||||
src/ParseHandler.cpp
|
|
||||||
src/Parser.cpp
|
|
||||||
src/PrintHandler.cpp
|
|
||||||
src/Query.cpp
|
|
||||||
src/Stringifier.cpp
|
|
||||||
src/TemplateCache.cpp
|
|
||||||
src/Template.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
# Headers
|
||||||
add_definitions(-DJSON_EXPORTS)
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
endif (NOT POCO_STATIC)
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL JSON_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -29,7 +20,7 @@ install(
|
|||||||
DESTINATION include
|
DESTINATION include
|
||||||
PATTERN ".svn" EXCLUDE
|
PATTERN ".svn" EXCLUDE
|
||||||
)
|
)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
TARGETS ${LIBNAME}
|
TARGETS ${LIBNAME}
|
||||||
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoJSON PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoJSON PocoFoundation )
|
||||||
|
@ -1,23 +1,24 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/JSONTest.cpp
|
|
||||||
src/JSONTest.h
|
|
||||||
src/JSONTestSuite.cpp
|
|
||||||
src/JSONTestSuite.h
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoJSON PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoJSON PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
# The test is run in the build directory. So the test data is copied there too
|
# The test is run in the build directory. So the test data is copied there too
|
||||||
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
||||||
|
@ -1,37 +1,18 @@
|
|||||||
set(LIBNAME "PocoMongoDB")
|
set(LIBNAME "PocoMongoDB")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Array.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Binary.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/Connection.cpp
|
|
||||||
src/Cursor.cpp
|
|
||||||
src/Database.cpp
|
|
||||||
src/DeleteRequest.cpp
|
|
||||||
src/Document.cpp
|
|
||||||
src/Element.cpp
|
|
||||||
src/GetMoreRequest.cpp
|
|
||||||
src/InsertRequest.cpp
|
|
||||||
src/JavaScriptCode.cpp
|
|
||||||
src/KillCursorsRequest.cpp
|
|
||||||
src/Message.cpp
|
|
||||||
src/MessageHeader.cpp
|
|
||||||
src/ObjectId.cpp
|
|
||||||
src/QueryRequest.cpp
|
|
||||||
src/RegularExpression.cpp
|
|
||||||
src/ReplicaSet.cpp
|
|
||||||
src/RequestMessage.cpp
|
|
||||||
src/ResponseMessage.cpp
|
|
||||||
src/UpdateRequest.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
# Headers
|
||||||
add_definitions(-DMongoDB_EXPORTS)
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
endif (NOT POCO_STATIC)
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL MongoDB_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoNet PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoNet PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -48,6 +29,7 @@ install(
|
|||||||
)
|
)
|
||||||
|
|
||||||
if (ENABLE_TESTS)
|
if (ENABLE_TESTS)
|
||||||
|
add_subdirectory(samples)
|
||||||
add_subdirectory(testsuite)
|
add_subdirectory(testsuite)
|
||||||
endif ()
|
endif ()
|
||||||
|
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoMongoDB PocoNet PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoMongoDB PocoNet PocoFoundation )
|
||||||
|
@ -1,21 +1,24 @@
|
|||||||
set( TEST_SRCS
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
src/Driver.cpp
|
|
||||||
src/MongoDBTest.cpp
|
|
||||||
src/MongoDBTest.h
|
|
||||||
src/MongoDBTestSuite.cpp
|
|
||||||
src/MongoDBTestSuite.h
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
# Headers
|
||||||
src/WinDriver.cpp
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoMongoDB PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoMongoDB PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
#TODO: Is this flag always required?
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
@ -1,126 +1,23 @@
|
|||||||
set(LIBNAME "PocoNet")
|
set(LIBNAME "PocoNet")
|
||||||
|
|
||||||
set( BASE_SRCS
|
# Sources
|
||||||
src/AbstractHTTPRequestHandler.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/DatagramSocket.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/DatagramSocketImpl.cpp
|
|
||||||
src/DialogSocket.cpp
|
|
||||||
src/DNS.cpp
|
|
||||||
src/FilePartSource.cpp
|
|
||||||
src/FTPClientSession.cpp
|
|
||||||
src/FTPStreamFactory.cpp
|
|
||||||
src/HostEntry.cpp
|
|
||||||
src/HTMLForm.cpp
|
|
||||||
src/HTTPAuthenticationParams.cpp
|
|
||||||
src/HTTPBasicCredentials.cpp
|
|
||||||
src/HTTPBufferAllocator.cpp
|
|
||||||
src/HTTPChunkedStream.cpp
|
|
||||||
src/HTTPClientSession.cpp
|
|
||||||
src/HTTPCookie.cpp
|
|
||||||
src/HTTPCredentials.cpp
|
|
||||||
src/HTTPDigestCredentials.cpp
|
|
||||||
src/HTTPFixedLengthStream.cpp
|
|
||||||
src/HTTPHeaderStream.cpp
|
|
||||||
src/HTTPIOStream.cpp
|
|
||||||
src/HTTPMessage.cpp
|
|
||||||
src/HTTPRequest.cpp
|
|
||||||
src/HTTPRequestHandler.cpp
|
|
||||||
src/HTTPRequestHandlerFactory.cpp
|
|
||||||
src/HTTPResponse.cpp
|
|
||||||
src/HTTPServer.cpp
|
|
||||||
src/HTTPServerConnection.cpp
|
|
||||||
src/HTTPServerConnectionFactory.cpp
|
|
||||||
src/HTTPServerParams.cpp
|
|
||||||
src/HTTPServerRequest.cpp
|
|
||||||
src/HTTPServerRequestImpl.cpp
|
|
||||||
src/HTTPServerResponse.cpp
|
|
||||||
src/HTTPServerResponseImpl.cpp
|
|
||||||
src/HTTPServerSession.cpp
|
|
||||||
src/HTTPSession.cpp
|
|
||||||
src/HTTPSessionFactory.cpp
|
|
||||||
src/HTTPSessionInstantiator.cpp
|
|
||||||
src/HTTPStream.cpp
|
|
||||||
src/HTTPStreamFactory.cpp
|
|
||||||
src/ICMPClient.cpp
|
|
||||||
src/ICMPEventArgs.cpp
|
|
||||||
src/ICMPPacket.cpp
|
|
||||||
src/ICMPPacketImpl.cpp
|
|
||||||
src/ICMPSocket.cpp
|
|
||||||
src/ICMPSocketImpl.cpp
|
|
||||||
src/ICMPv4PacketImpl.cpp
|
|
||||||
src/IPAddress.cpp
|
|
||||||
src/IPAddressImpl.cpp
|
|
||||||
src/MailMessage.cpp
|
|
||||||
src/MailRecipient.cpp
|
|
||||||
src/MailStream.cpp
|
|
||||||
src/MediaType.cpp
|
|
||||||
src/MessageHeader.cpp
|
|
||||||
src/MulticastSocket.cpp
|
|
||||||
src/MultipartReader.cpp
|
|
||||||
src/MultipartWriter.cpp
|
|
||||||
src/NameValueCollection.cpp
|
|
||||||
src/Net.cpp
|
|
||||||
src/NetException.cpp
|
|
||||||
src/NetworkInterface.cpp
|
|
||||||
src/NTPClient.cpp
|
|
||||||
src/NTPEventArgs.cpp
|
|
||||||
src/NTPPacket.cpp
|
|
||||||
src/NullPartHandler.cpp
|
|
||||||
src/PartHandler.cpp
|
|
||||||
src/PartSource.cpp
|
|
||||||
src/PartStore.cpp
|
|
||||||
src/POP3ClientSession.cpp
|
|
||||||
src/QuotedPrintableDecoder.cpp
|
|
||||||
src/QuotedPrintableEncoder.cpp
|
|
||||||
src/RawSocket.cpp
|
|
||||||
src/RawSocketImpl.cpp
|
|
||||||
src/RemoteSyslogChannel.cpp
|
|
||||||
src/RemoteSyslogListener.cpp
|
|
||||||
src/ServerSocket.cpp
|
|
||||||
src/ServerSocketImpl.cpp
|
|
||||||
src/SMTPChannel.cpp
|
|
||||||
src/SMTPClientSession.cpp
|
|
||||||
src/Socket.cpp
|
|
||||||
src/SocketAddress.cpp
|
|
||||||
src/SocketAddressImpl.cpp
|
|
||||||
src/SocketImpl.cpp
|
|
||||||
src/SocketNotification.cpp
|
|
||||||
src/SocketNotifier.cpp
|
|
||||||
src/SocketReactor.cpp
|
|
||||||
src/SocketStream.cpp
|
|
||||||
src/StreamSocket.cpp
|
|
||||||
src/StreamSocketImpl.cpp
|
|
||||||
src/StringPartSource.cpp
|
|
||||||
src/TCPServer.cpp
|
|
||||||
src/TCPServerConnection.cpp
|
|
||||||
src/TCPServerConnectionFactory.cpp
|
|
||||||
src/TCPServerDispatcher.cpp
|
|
||||||
src/TCPServerParams.cpp
|
|
||||||
src/WebSocket.cpp
|
|
||||||
src/WebSocketImpl.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set( WIN_SRCS
|
# Headers
|
||||||
)
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
set( LIN_SRCS
|
|
||||||
)
|
|
||||||
|
|
||||||
|
#TODO: Can WIN32 be used here?
|
||||||
if(CMAKE_SYSTEM MATCHES "Windows")
|
if(CMAKE_SYSTEM MATCHES "Windows")
|
||||||
set(SRCS ${BASE_SRCS} ${WIN_SRCS})
|
set(SYSLIBS ${SYSLIBS} "ws2_32.lib" "iphlpapi.lib")
|
||||||
set(SYSLIBS ${SYSLIBS} "ws2_32.lib" "iphlpapi.lib")
|
|
||||||
else (CMAKE_SYSTEM MATCHES "Windows")
|
|
||||||
set(SRCS ${BASE_SRCS} ${LIN_SRCS})
|
|
||||||
endif(CMAKE_SYSTEM MATCHES "Windows")
|
endif(CMAKE_SYSTEM MATCHES "Windows")
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
|
||||||
add_definitions(-DNet_EXPORTS)
|
|
||||||
endif (NOT POCO_STATIC)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Net_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoFoundation ${SYSLIBS})
|
target_link_libraries( ${LIBNAME} PocoFoundation ${SYSLIBS})
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -128,7 +25,7 @@ install(
|
|||||||
DESTINATION include
|
DESTINATION include
|
||||||
PATTERN ".svn" EXCLUDE
|
PATTERN ".svn" EXCLUDE
|
||||||
)
|
)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
TARGETS ${LIBNAME}
|
TARGETS ${LIBNAME}
|
||||||
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
LIBRARY DESTINATION lib${LIB_SUFFIX}
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNet PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -1,74 +1,21 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/DNSTest.cpp
|
|
||||||
src/DatagramSocketTest.cpp
|
|
||||||
src/DialogServer.cpp
|
|
||||||
src/DialogSocketTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/EchoServer.cpp
|
|
||||||
src/FTPClientSessionTest.cpp
|
|
||||||
src/FTPClientTestSuite.cpp
|
|
||||||
src/FTPStreamFactoryTest.cpp
|
|
||||||
src/HTMLFormTest.cpp
|
|
||||||
src/HTMLTestSuite.cpp
|
|
||||||
src/HTTPClientSessionTest.cpp
|
|
||||||
src/HTTPClientTestSuite.cpp
|
|
||||||
src/HTTPCookieTest.cpp
|
|
||||||
src/HTTPCredentialsTest.cpp
|
|
||||||
src/HTTPRequestTest.cpp
|
|
||||||
src/HTTPResponseTest.cpp
|
|
||||||
src/HTTPServerTest.cpp
|
|
||||||
src/HTTPServerTestSuite.cpp
|
|
||||||
src/HTTPStreamFactoryTest.cpp
|
|
||||||
src/HTTPTestServer.cpp
|
|
||||||
src/HTTPTestSuite.cpp
|
|
||||||
src/ICMPClientTest.cpp
|
|
||||||
src/ICMPClientTestSuite.cpp
|
|
||||||
src/ICMPSocketTest.cpp
|
|
||||||
src/IPAddressTest.cpp
|
|
||||||
src/MailMessageTest.cpp
|
|
||||||
src/MailStreamTest.cpp
|
|
||||||
src/MailTestSuite.cpp
|
|
||||||
src/MediaTypeTest.cpp
|
|
||||||
src/MessageHeaderTest.cpp
|
|
||||||
src/MessagesTestSuite.cpp
|
|
||||||
src/MulticastEchoServer.cpp
|
|
||||||
src/MulticastSocketTest.cpp
|
|
||||||
src/MultipartReaderTest.cpp
|
|
||||||
src/MultipartWriterTest.cpp
|
|
||||||
src/NameValueCollectionTest.cpp
|
|
||||||
src/NetCoreTestSuite.cpp
|
|
||||||
src/NetTestSuite.cpp
|
|
||||||
src/NetworkInterfaceTest.cpp
|
|
||||||
src/NTPClientTest.cpp
|
|
||||||
src/NTPClientTestSuite.cpp
|
|
||||||
src/POP3ClientSessionTest.cpp
|
|
||||||
src/QuotedPrintableTest.cpp
|
|
||||||
src/RawSocketTest.cpp
|
|
||||||
src/ReactorTestSuite.cpp
|
|
||||||
src/SMTPClientSessionTest.cpp
|
|
||||||
src/SocketAddressTest.cpp
|
|
||||||
src/SocketReactorTest.cpp
|
|
||||||
src/SocketStreamTest.cpp
|
|
||||||
src/SocketTest.cpp
|
|
||||||
src/SocketsTestSuite.cpp
|
|
||||||
src/SyslogTest.cpp
|
|
||||||
src/TCPServerTest.cpp
|
|
||||||
src/TCPServerTestSuite.cpp
|
|
||||||
src/UDPEchoServer.cpp
|
|
||||||
src/WebSocketTest.cpp
|
|
||||||
src/WebSocketTestSuite.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoNet PocoUtil PocoXML PocoFoundation CppUnit)
|
target_link_libraries( ${TESTUNIT} PocoNet PocoUtil PocoXML PocoFoundation CppUnit)
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
@ -1,45 +1,18 @@
|
|||||||
set(LIBNAME "PocoNetSSL")
|
set(LIBNAME "PocoNetSSL")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/AcceptCertificateHandler.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/CertificateHandlerFactory.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/CertificateHandlerFactoryMgr.cpp
|
|
||||||
src/ConsoleCertificateHandler.cpp
|
|
||||||
src/Context.cpp
|
|
||||||
src/HTTPSClientSession.cpp
|
|
||||||
src/HTTPSSessionInstantiator.cpp
|
|
||||||
src/HTTPSStreamFactory.cpp
|
|
||||||
src/InvalidCertificateHandler.cpp
|
|
||||||
src/KeyConsoleHandler.cpp
|
|
||||||
src/KeyFileHandler.cpp
|
|
||||||
src/PrivateKeyFactory.cpp
|
|
||||||
src/PrivateKeyFactoryMgr.cpp
|
|
||||||
src/PrivateKeyPassphraseHandler.cpp
|
|
||||||
src/RejectCertificateHandler.cpp
|
|
||||||
src/SecureServerSocket.cpp
|
|
||||||
src/SecureServerSocketImpl.cpp
|
|
||||||
src/SecureSMTPClientSession.cpp
|
|
||||||
src/SecureSocketImpl.cpp
|
|
||||||
src/SecureStreamSocket.cpp
|
|
||||||
src/SecureStreamSocketImpl.cpp
|
|
||||||
src/Session.cpp
|
|
||||||
src/SSLException.cpp
|
|
||||||
src/SSLManager.cpp
|
|
||||||
src/Utility.cpp
|
|
||||||
src/VerificationErrorArgs.cpp
|
|
||||||
src/X509Certificate.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
include_directories( ${OPENSSL_INCLUDE_DIR} )
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
if (NOT POCO_STATIC)
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
add_definitions(-DNetSSL_EXPORTS)
|
|
||||||
endif (NOT POCO_STATIC)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
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} )
|
target_link_libraries( ${LIBNAME} PocoCrypto PocoNet PocoUtil PocoFoundation ${OPENSSL_SSL_LIBRARY} ${OPENSSL_CRYPTO_LIBRARY} )
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
add_subdirectory( HTTPSTimeServer )
|
add_subdirectory( HTTPSTimeServer )
|
||||||
add_subdirectory( download )
|
add_subdirectory( download )
|
||||||
|
add_subdirectory( Mail )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoNetSSL PocoCrypto PocoUtil PocoNet PocoXML PocoFoundation )
|
||||||
|
@ -1,33 +1,33 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/HTTPSClientSessionTest.cpp
|
|
||||||
src/HTTPSClientTestSuite.cpp
|
|
||||||
src/HTTPSServerTest.cpp
|
|
||||||
src/HTTPSServerTestSuite.cpp
|
|
||||||
src/HTTPSStreamFactoryTest.cpp
|
|
||||||
src/HTTPSTestServer.cpp
|
|
||||||
src/NetSSLTestSuite.cpp
|
|
||||||
src/TCPServerTest.cpp
|
|
||||||
src/TCPServerTestSuite.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoNetSSL PocoCrypto PocoNet PocoUtil PocoXML PocoFoundation CppUnit)
|
target_link_libraries( ${TESTUNIT} PocoNetSSL PocoCrypto PocoNet PocoUtil PocoXML PocoFoundation CppUnit)
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
# The test is run in the build directory. So the test data is copied there too
|
# The test is run in the build directory. So the test data is copied there too
|
||||||
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/any.pem ${CMAKE_CURRENT_BINARY_DIR}
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/any.pem ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/rootcert.pem ${CMAKE_CURRENT_BINARY_DIR}
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/rootcert.pem ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
|
||||||
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/testrunner.xml ${CMAKE_CURRENT_BINARY_DIR}/${TESTUNIT}.xml
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/testrunner.xml ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${TESTUNIT}.xml
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -1,17 +1,12 @@
|
|||||||
set(LIBNAME "PocoPDF")
|
set(LIBNAME "PocoPDF")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Destination.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Document.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/Encoder.cpp
|
|
||||||
src/Font.cpp
|
# Headers
|
||||||
src/Image.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/LinkAnnotation.cpp
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
src/Outline.cpp
|
|
||||||
src/Page.cpp
|
|
||||||
src/PDFException.cpp
|
|
||||||
src/TextAnnotation.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
||||||
# The configuration will fail if the packages are not found
|
# The configuration will fail if the packages are not found
|
||||||
@ -20,8 +15,8 @@ if (POCO_UNBUNDLED)
|
|||||||
set(SYSLIBS ${SYSLIBS} ${ZLIB_LIBRARIES})
|
set(SYSLIBS ${SYSLIBS} ${ZLIB_LIBRARIES})
|
||||||
include_directories(${ZLIB_INCLUDE_DIRS})
|
include_directories(${ZLIB_INCLUDE_DIRS})
|
||||||
else()
|
else()
|
||||||
# ZLIB
|
# zlib
|
||||||
list(APPEND SRCS
|
POCO_SOURCES( SRCS zlib
|
||||||
src/adler32.c
|
src/adler32.c
|
||||||
src/compress.c
|
src/compress.c
|
||||||
src/crc32.c
|
src/crc32.c
|
||||||
@ -38,8 +33,8 @@ endif (POCO_UNBUNDLED)
|
|||||||
|
|
||||||
# TODO: Currently only bundled is supported, in future this should also be possible
|
# TODO: Currently only bundled is supported, in future this should also be possible
|
||||||
# with an unbundled version of hpdf
|
# with an unbundled version of hpdf
|
||||||
# HPDF
|
# hpdf
|
||||||
list(APPEND SRCS
|
POCO_SOURCES( SRCS hpdf
|
||||||
src/hpdf_annotation.c
|
src/hpdf_annotation.c
|
||||||
src/hpdf_array.c
|
src/hpdf_array.c
|
||||||
src/hpdf_binary.c
|
src/hpdf_binary.c
|
||||||
@ -94,7 +89,7 @@ list(APPEND SRCS
|
|||||||
|
|
||||||
# TODO: Currently only bundled is supported, in future this should also be possible
|
# TODO: Currently only bundled is supported, in future this should also be possible
|
||||||
# with an unbundled version of libpng
|
# with an unbundled version of libpng
|
||||||
list(APPEND SRCS
|
POCO_SOURCES( SRCS libpng
|
||||||
src/png.c
|
src/png.c
|
||||||
src/pngerror.c
|
src/pngerror.c
|
||||||
src/pnggccrd.c
|
src/pnggccrd.c
|
||||||
@ -115,16 +110,13 @@ list(APPEND SRCS
|
|||||||
src/pngwutil.c
|
src/pngwutil.c
|
||||||
)
|
)
|
||||||
|
|
||||||
include_directories(include/Poco/PDF) # zip src
|
include_directories( "include/Poco/PDF" ) # zip src
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
|
||||||
add_definitions(-DPDF_EXPORTS)
|
|
||||||
endif (NOT POCO_STATIC)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL PDF_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} ${SYSLIBS} PocoFoundation )
|
target_link_libraries( ${LIBNAME} ${SYSLIBS} PocoFoundation )
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoPDF PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoPDF PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoPDF PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoPDF PocoFoundation )
|
||||||
|
@ -1,21 +1,22 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/Driver.cpp
|
|
||||||
src/PDFTest.cpp
|
|
||||||
src/PDFTest.h
|
|
||||||
src/PDFTestSuite.cpp
|
|
||||||
src/PDFTestSuite.h
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoPDF PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoPDF PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
@ -1,13 +1,16 @@
|
|||||||
set(LIBNAME "PocoSevenZip")
|
set(LIBNAME "PocoSevenZip")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Archive.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/ArchiveEntry.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
)
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
# TODO: Currently only bundled is supported, in future this should also be possible
|
# TODO: Currently only bundled is supported, in future this should also be possible
|
||||||
# with an unbundled version of 7z
|
# with an unbundled version of 7z
|
||||||
list(APPEND SRCS
|
POCO_SOURCES( SRCS 7z
|
||||||
src/7zAlloc.c
|
src/7zAlloc.c
|
||||||
src/7zBuf2.c
|
src/7zBuf2.c
|
||||||
src/7zBuf.c
|
src/7zBuf.c
|
||||||
@ -17,7 +20,7 @@ list(APPEND SRCS
|
|||||||
src/7zFile.c
|
src/7zFile.c
|
||||||
src/7zIn.c
|
src/7zIn.c
|
||||||
src/7zStream.c
|
src/7zStream.c
|
||||||
# src/Alloc.c
|
src/Alloc.c
|
||||||
src/Bcj2.c
|
src/Bcj2.c
|
||||||
src/Bra86.c
|
src/Bra86.c
|
||||||
src/Bra.c
|
src/Bra.c
|
||||||
@ -46,16 +49,13 @@ list(APPEND SRCS
|
|||||||
# src/XzIn.c
|
# src/XzIn.c
|
||||||
)
|
)
|
||||||
|
|
||||||
include_directories( "include" )
|
include_directories( include )
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
|
||||||
add_definitions(-DSevenZip_EXPORTS)
|
|
||||||
endif (NOT POCO_STATIC)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL SevenZip_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoUtil PocoXML PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoUtil PocoXML PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
@ -72,8 +72,7 @@ install(
|
|||||||
)
|
)
|
||||||
|
|
||||||
if (ENABLE_TESTS)
|
if (ENABLE_TESTS)
|
||||||
# TODO: Enable CMake for samples
|
add_subdirectory(samples)
|
||||||
#add_subdirectory(samples)
|
|
||||||
# TODO: Add tests
|
# TODO: Add tests
|
||||||
#add_subdirectory(testsuite)
|
#add_subdirectory(testsuite)
|
||||||
endif ()
|
endif ()
|
||||||
|
1
SevenZip/samples/CMakeLists.txt
Normal file
1
SevenZip/samples/CMakeLists.txt
Normal file
@ -0,0 +1 @@
|
|||||||
|
add_subdirectory( un7zip )
|
7
SevenZip/samples/un7zip/CMakeLists.txt
Normal file
7
SevenZip/samples/un7zip/CMakeLists.txt
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
set(SAMPLE_NAME "un7zip")
|
||||||
|
|
||||||
|
set(LOCAL_SRCS "")
|
||||||
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
|
target_link_libraries( ${SAMPLE_NAME} PocoSevenZip PocoUtil PocoXML PocoFoundation )
|
@ -1,36 +1,14 @@
|
|||||||
set(LIBNAME "PocoUtil")
|
set(LIBNAME "PocoUtil")
|
||||||
|
|
||||||
set(BASE_SRCS
|
# Sources
|
||||||
src/AbstractConfiguration.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/Application.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/ConfigurationMapper.cpp
|
|
||||||
src/ConfigurationView.cpp
|
|
||||||
src/FilesystemConfiguration.cpp
|
|
||||||
src/HelpFormatter.cpp
|
|
||||||
src/IniFileConfiguration.cpp
|
|
||||||
src/IntValidator.cpp
|
|
||||||
src/JSONConfiguration.cpp
|
|
||||||
src/LayeredConfiguration.cpp
|
|
||||||
src/LoggingConfigurator.cpp
|
|
||||||
src/LoggingSubsystem.cpp
|
|
||||||
src/MapConfiguration.cpp
|
|
||||||
src/OptionCallback.cpp
|
|
||||||
src/Option.cpp
|
|
||||||
src/OptionException.cpp
|
|
||||||
src/OptionProcessor.cpp
|
|
||||||
src/OptionSet.cpp
|
|
||||||
src/PropertyFileConfiguration.cpp
|
|
||||||
src/RegExpValidator.cpp
|
|
||||||
src/ServerApplication.cpp
|
|
||||||
src/Subsystem.cpp
|
|
||||||
src/SystemConfiguration.cpp
|
|
||||||
src/Timer.cpp
|
|
||||||
src/TimerTask.cpp
|
|
||||||
src/Validator.cpp
|
|
||||||
src/XMLConfiguration.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set( WIN_SRCS
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( SRCS WIN32
|
||||||
src/WinRegistryConfiguration.cpp
|
src/WinRegistryConfiguration.cpp
|
||||||
src/WinRegistryKey.cpp
|
src/WinRegistryKey.cpp
|
||||||
src/WinService.cpp
|
src/WinService.cpp
|
||||||
@ -38,17 +16,11 @@ set( WIN_SRCS
|
|||||||
|
|
||||||
include_directories( "include" )
|
include_directories( "include" )
|
||||||
|
|
||||||
if(CMAKE_SYSTEM MATCHES "Windows")
|
|
||||||
set(SRCS ${BASE_SRCS} ${WIN_SRCS})
|
|
||||||
add_definitions(-DUtil_EXPORTS)
|
|
||||||
else (CMAKE_SYSTEM MATCHES "Windows")
|
|
||||||
set(SRCS ${BASE_SRCS})
|
|
||||||
endif(CMAKE_SYSTEM MATCHES "Windows")
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Util_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoJSON PocoXML PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoJSON PocoXML PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoUtil PocoJSON PocoXML PocoFoundation )
|
||||||
|
@ -1,39 +1,28 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/AbstractConfigurationTest.cpp
|
|
||||||
src/JSONConfigurationTest.cpp
|
|
||||||
src/ConfigurationMapperTest.cpp
|
|
||||||
src/ConfigurationTestSuite.cpp
|
|
||||||
src/ConfigurationViewTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/FilesystemConfigurationTest.cpp
|
|
||||||
src/HelpFormatterTest.cpp
|
|
||||||
src/IniFileConfigurationTest.cpp
|
|
||||||
src/LayeredConfigurationTest.cpp
|
|
||||||
src/LoggingConfiguratorTest.cpp
|
|
||||||
src/MapConfigurationTest.cpp
|
|
||||||
src/OptionProcessorTest.cpp
|
|
||||||
src/OptionSetTest.cpp
|
|
||||||
src/OptionTest.cpp
|
|
||||||
src/OptionsTestSuite.cpp
|
|
||||||
src/PropertyFileConfigurationTest.cpp
|
|
||||||
src/SystemConfigurationTest.cpp
|
|
||||||
src/UtilTestSuite.cpp
|
|
||||||
src/ValidatorTest.cpp
|
|
||||||
src/XMLConfigurationTest.cpp
|
|
||||||
src/TimerTestSuite.cpp
|
|
||||||
src/TimerTest.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinConfigurationTest.cpp
|
|
||||||
src/WinDriver.cpp
|
|
||||||
src/WinRegistryTest.cpp
|
|
||||||
src/WindowsTestSuite.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
src/WinConfigurationTest.cpp
|
||||||
|
src/WinRegistryTest.cpp
|
||||||
|
src/WindowsTestSuite.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoUtil PocoJSON PocoXML PocoFoundation CppUnit)
|
target_link_libraries( ${TESTUNIT} PocoUtil PocoJSON PocoXML PocoFoundation CppUnit)
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
@ -1,74 +1,12 @@
|
|||||||
set(LIBNAME "PocoXML")
|
set(LIBNAME "PocoXML")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/AbstractContainerNode.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/AbstractNode.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/Attr.cpp
|
|
||||||
src/Attributes.cpp
|
# Headers
|
||||||
src/AttributesImpl.cpp
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
src/AttrMap.cpp
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
src/CDATASection.cpp
|
|
||||||
src/CharacterData.cpp
|
|
||||||
src/ChildNodesList.cpp
|
|
||||||
src/Comment.cpp
|
|
||||||
src/ContentHandler.cpp
|
|
||||||
src/DeclHandler.cpp
|
|
||||||
src/DefaultHandler.cpp
|
|
||||||
src/Document.cpp
|
|
||||||
src/DocumentEvent.cpp
|
|
||||||
src/DocumentFragment.cpp
|
|
||||||
src/DocumentType.cpp
|
|
||||||
src/DOMBuilder.cpp
|
|
||||||
src/DOMException.cpp
|
|
||||||
src/DOMImplementation.cpp
|
|
||||||
src/DOMObject.cpp
|
|
||||||
src/DOMParser.cpp
|
|
||||||
src/DOMSerializer.cpp
|
|
||||||
src/DOMWriter.cpp
|
|
||||||
src/DTDHandler.cpp
|
|
||||||
src/DTDMap.cpp
|
|
||||||
src/Element.cpp
|
|
||||||
src/ElementsByTagNameList.cpp
|
|
||||||
src/Entity.cpp
|
|
||||||
src/EntityReference.cpp
|
|
||||||
src/EntityResolver.cpp
|
|
||||||
src/EntityResolverImpl.cpp
|
|
||||||
src/ErrorHandler.cpp
|
|
||||||
src/Event.cpp
|
|
||||||
src/EventDispatcher.cpp
|
|
||||||
src/EventException.cpp
|
|
||||||
src/EventListener.cpp
|
|
||||||
src/EventTarget.cpp
|
|
||||||
src/InputSource.cpp
|
|
||||||
src/LexicalHandler.cpp
|
|
||||||
src/Locator.cpp
|
|
||||||
src/LocatorImpl.cpp
|
|
||||||
src/MutationEvent.cpp
|
|
||||||
src/Name.cpp
|
|
||||||
src/NamedNodeMap.cpp
|
|
||||||
src/NamePool.cpp
|
|
||||||
src/NamespaceStrategy.cpp
|
|
||||||
src/NamespaceSupport.cpp
|
|
||||||
src/NodeAppender.cpp
|
|
||||||
src/Node.cpp
|
|
||||||
src/NodeFilter.cpp
|
|
||||||
src/NodeIterator.cpp
|
|
||||||
src/NodeList.cpp
|
|
||||||
src/Notation.cpp
|
|
||||||
src/ParserEngine.cpp
|
|
||||||
src/ProcessingInstruction.cpp
|
|
||||||
src/SAXException.cpp
|
|
||||||
src/SAXParser.cpp
|
|
||||||
src/Text.cpp
|
|
||||||
src/TreeWalker.cpp
|
|
||||||
src/WhitespaceFilter.cpp
|
|
||||||
src/XMLException.cpp
|
|
||||||
src/XMLFilter.cpp
|
|
||||||
src/XMLFilterImpl.cpp
|
|
||||||
src/XMLReader.cpp
|
|
||||||
src/XMLString.cpp
|
|
||||||
src/XMLWriter.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
||||||
# The configuration will fail if the packages are not found
|
# The configuration will fail if the packages are not found
|
||||||
@ -77,7 +15,7 @@ if (POCO_UNBUNDLED)
|
|||||||
set(SYSLIBS ${SYSLIBS} ${EXPAT_LIBRARIES})
|
set(SYSLIBS ${SYSLIBS} ${EXPAT_LIBRARIES})
|
||||||
include_directories(${EXPAT_INCLUDE_DIRS})
|
include_directories(${EXPAT_INCLUDE_DIRS})
|
||||||
else()
|
else()
|
||||||
list(APPEND SRCS
|
POCO_SOURCES( SRCS expat
|
||||||
src/xmlparse.cpp
|
src/xmlparse.cpp
|
||||||
src/xmlrole.c
|
src/xmlrole.c
|
||||||
src/xmltok.c
|
src/xmltok.c
|
||||||
@ -86,18 +24,13 @@ else()
|
|||||||
)
|
)
|
||||||
endif (POCO_UNBUNDLED)
|
endif (POCO_UNBUNDLED)
|
||||||
|
|
||||||
|
add_definitions(-D_USRDLL -DXML_NS -DXML_DTD -DHAVE_EXPAT_CONFIG_H)
|
||||||
|
|
||||||
add_definitions(-D_USRDLL -DXML_NS -DXML_DTD -DHAVE_EXPAT_CONFIG_H -DXML_EXPORTS)
|
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
|
||||||
add_definitions(-DXML_EXPORTS)
|
|
||||||
endif (NOT POCO_STATIC)
|
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL XML_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} ${SYSLIBS} PocoFoundation)
|
target_link_libraries( ${LIBNAME} ${SYSLIBS} PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoXML PocoFoundation )
|
||||||
|
@ -1,37 +1,26 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/AttributesImplTest.cpp
|
|
||||||
src/ChildNodesTest.cpp
|
|
||||||
src/DOMTestSuite.cpp
|
|
||||||
src/DocumentTest.cpp
|
|
||||||
src/DocumentTypeTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/ElementTest.cpp
|
|
||||||
src/EventTest.cpp
|
|
||||||
src/NamePoolTest.cpp
|
|
||||||
src/NameTest.cpp
|
|
||||||
src/NamespaceSupportTest.cpp
|
|
||||||
src/NodeAppenderTest.cpp
|
|
||||||
src/NodeIteratorTest.cpp
|
|
||||||
src/NodeTest.cpp
|
|
||||||
src/ParserWriterTest.cpp
|
|
||||||
src/SAXParserTest.cpp
|
|
||||||
src/SAXTestSuite.cpp
|
|
||||||
src/TextTest.cpp
|
|
||||||
src/TreeWalkerTest.cpp
|
|
||||||
src/XMLTestSuite.cpp
|
|
||||||
src/XMLWriterTest.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${TESTUNIT} PocoXML PocoFoundation CppUnit)
|
target_link_libraries( ${TESTUNIT} PocoXML PocoFoundation CppUnit)
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
|
@ -1,38 +1,18 @@
|
|||||||
set(LIBNAME "PocoZip")
|
set(LIBNAME "PocoZip")
|
||||||
|
|
||||||
set(SRCS
|
# Sources
|
||||||
src/Add.cpp
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
src/AutoDetectStream.cpp
|
POCO_SOURCES_AUTO( SRCS ${SRCS_G})
|
||||||
src/Compress.cpp
|
|
||||||
src/Decompress.cpp
|
|
||||||
src/Delete.cpp
|
|
||||||
src/Keep.cpp
|
|
||||||
src/ParseCallback.cpp
|
|
||||||
src/PartialStream.cpp
|
|
||||||
src/Rename.cpp
|
|
||||||
src/Replace.cpp
|
|
||||||
src/SkipCallback.cpp
|
|
||||||
src/ZipArchive.cpp
|
|
||||||
src/ZipArchiveInfo.cpp
|
|
||||||
src/ZipCommon.cpp
|
|
||||||
src/ZipDataInfo.cpp
|
|
||||||
src/ZipException.cpp
|
|
||||||
src/ZipFileInfo.cpp
|
|
||||||
src/ZipLocalFileHeader.cpp
|
|
||||||
src/ZipManipulator.cpp
|
|
||||||
src/ZipOperation.cpp
|
|
||||||
src/ZipStream.cpp
|
|
||||||
src/ZipUtil.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
if (NOT POCO_STATIC)
|
# Headers
|
||||||
add_definitions(-DZip_EXPORTS)
|
file(GLOB_RECURSE HDRS_G "include/*.h" )
|
||||||
endif (NOT POCO_STATIC)
|
POCO_HEADERS_AUTO( SRCS ${HDRS_G})
|
||||||
|
|
||||||
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
||||||
set_target_properties( ${LIBNAME}
|
set_target_properties( ${LIBNAME}
|
||||||
PROPERTIES
|
PROPERTIES
|
||||||
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION}
|
||||||
|
DEFINE_SYMBOL Zip_EXPORTS)
|
||||||
target_link_libraries( ${LIBNAME} PocoUtil PocoXML PocoFoundation)
|
target_link_libraries( ${LIBNAME} PocoUtil PocoXML PocoFoundation)
|
||||||
|
|
||||||
install(
|
install(
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoZip PocoUtil PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoZip PocoUtil PocoXML PocoFoundation )
|
||||||
|
@ -4,5 +4,4 @@ set(LOCAL_SRCS "")
|
|||||||
aux_source_directory(src LOCAL_SRCS)
|
aux_source_directory(src LOCAL_SRCS)
|
||||||
|
|
||||||
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
add_executable( ${SAMPLE_NAME} ${LOCAL_SRCS} )
|
||||||
#set_target_properties( ${SAMPLE_NAME} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
|
||||||
target_link_libraries( ${SAMPLE_NAME} PocoZip PocoUtil PocoXML PocoFoundation )
|
target_link_libraries( ${SAMPLE_NAME} PocoZip PocoUtil PocoXML PocoFoundation )
|
||||||
|
@ -1,23 +1,29 @@
|
|||||||
set( TEST_SRCS
|
|
||||||
src/CompressTest.cpp
|
|
||||||
src/Driver.cpp
|
|
||||||
src/PartialStreamTest.cpp
|
|
||||||
src/ZipTest.cpp
|
|
||||||
src/ZipTestSuite.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
#include_directories()
|
|
||||||
|
|
||||||
set( WIN_TEST_SRCS
|
|
||||||
src/WinDriver.cpp
|
|
||||||
)
|
|
||||||
|
|
||||||
set(TESTUNIT "${LIBNAME}-testrunner")
|
set(TESTUNIT "${LIBNAME}-testrunner")
|
||||||
|
|
||||||
|
# Sources
|
||||||
|
file(GLOB SRCS_G "src/*.cpp")
|
||||||
|
POCO_SOURCES_AUTO( TEST_SRCS ${SRCS_G})
|
||||||
|
|
||||||
|
# Headers
|
||||||
|
file(GLOB_RECURSE HDRS_G "src/*.h" )
|
||||||
|
POCO_HEADERS_AUTO( TEST_SRCS ${HDRS_G})
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WIN32
|
||||||
|
src/WinDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
POCO_SOURCES_AUTO_PLAT( TEST_SRCS WINCE
|
||||||
|
src/WinCEDriver.cpp
|
||||||
|
)
|
||||||
|
|
||||||
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
add_executable( ${TESTUNIT} ${TEST_SRCS} )
|
||||||
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
add_test(NAME ${LIBNAME} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMAND ${TESTUNIT} -all)
|
||||||
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
#set_target_properties( ${TESTUNIT} PROPERTIES COMPILE_FLAGS ${RELEASE_CXX_FLAGS} )
|
||||||
target_link_libraries( ${TESTUNIT} PocoZip PocoNet PocoFoundation CppUnit )
|
target_link_libraries( ${TESTUNIT} PocoZip PocoNet PocoFoundation CppUnit )
|
||||||
|
if( WIN32)
|
||||||
|
add_definitions("-D_AFXDLL")
|
||||||
|
target_link_libraries( ${TESTUNIT} WinTestRunner)
|
||||||
|
endif(WIN32)
|
||||||
|
|
||||||
# The test is run in the build directory. So the test data is copied there too
|
# The test is run in the build directory. So the test data is copied there too
|
||||||
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
add_custom_command(TARGET ${TESTUNIT} POST_BUILD
|
||||||
|
@ -1,48 +1,58 @@
|
|||||||
# check for location of odbc_config
|
#
|
||||||
find_program(UNIX_ODBC_CONFIG odbc_config
|
# Find the ODBC driver manager includes and library.
|
||||||
$ENV{ODBC_PATH}/bin
|
#
|
||||||
/usr/bin
|
# ODBC is an open standard for connecting to different databases in a
|
||||||
/usr/local/bin
|
# semi-vendor-independent fashion. First you install the ODBC driver
|
||||||
PATHS)
|
# manager. Then you need a driver for each separate database you want
|
||||||
|
# to connect to (unless a generic one works). VTK includes neither
|
||||||
|
# the driver manager nor the vendor-specific drivers: you have to find
|
||||||
|
# those yourself.
|
||||||
|
#
|
||||||
|
# This module defines
|
||||||
|
# ODBC_INCLUDE_DIRECTORIES, where to find sql.h
|
||||||
|
# ODBC_LIBRARIES, the libraries to link against to use ODBC
|
||||||
|
# ODBC_FOUND. If false, you cannot build anything that requires MySQL.
|
||||||
|
|
||||||
# Check that we can find the ODBC headers in `odbc_config --include-prefix`
|
find_path(ODBC_INCLUDE_DIRECTORIES
|
||||||
# location If the headers cannot be found, set UNIX_ODBC_CONFIG to
|
NAMES sql.h
|
||||||
# UNIX_ODBC_CONFIG-NOTFOUND since the odbc_config tool is essentially useless
|
HINTS
|
||||||
# if `odbc_config --include-prefix` doesn't actually point to ODBC headers
|
/usr/include
|
||||||
if(NOT ${UNIX_ODBC_CONFIG} MATCHES "UNIX_ODBC_CONFIG-NOTFOUND")
|
/usr/include/odbc
|
||||||
execute_process(COMMAND ${UNIX_ODBC_CONFIG} --include-prefix
|
/usr/local/include
|
||||||
OUTPUT_VARIABLE UNIX_ODBC_INCLUDE_PREFIX
|
/usr/local/include/odbc
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE)
|
/usr/local/odbc/include
|
||||||
if(NOT EXISTS ${UNIX_ODBC_INCLUDE_PREFIX}/sqlext.h)
|
"C:/Program Files/ODBC/include"
|
||||||
set(UNIX_ODBC_CONFIG "UNIX_ODBC_CONFIG-NOTFOUND")
|
"C:/Program Files/Microsoft SDKs/Windows/v7.0/include"
|
||||||
endif(NOT EXISTS ${UNIX_ODBC_INCLUDE_PREFIX}/sqlext.h)
|
"C:/Program Files/Microsoft SDKs/Windows/v6.0a/include"
|
||||||
endif(NOT ${UNIX_ODBC_CONFIG} MATCHES "UNIX_ODBC_CONFIG-NOTFOUND")
|
"C:/ODBC/include"
|
||||||
|
DOC "Specify the directory containing sql.h."
|
||||||
|
)
|
||||||
|
|
||||||
if(${UNIX_ODBC_CONFIG} MATCHES "UNIX_ODBC_CONFIG-NOTFOUND")
|
find_library(ODBC_LIBRARIES
|
||||||
message(STATUS "Couldn't find unixODBC")
|
NAMES iodbc odbc odbcinst odbc32
|
||||||
else(${UNIX_ODBC_CONFIG} MATCHES "UNIX_ODBC_CONFIG-NOTFOUND")
|
HINTS
|
||||||
message(STATUS "Found unixODBC: odbc_config in ${UNIX_ODBC_CONFIG}")
|
/usr/lib
|
||||||
exec_program(${UNIX_ODBC_CONFIG} ARGS "--include-prefix" OUTPUT_VARIABLE ODBC_INCLUDE_DIR)
|
/usr/lib/odbc
|
||||||
include_directories(${ODBC_INCLUDE_DIR})
|
/usr/local/lib
|
||||||
exec_program(${UNIX_ODBC_CONFIG} ARGS "--libs" OUTPUT_VARIABLE ODBC_LINK_FLAGS)
|
/usr/local/lib/odbc
|
||||||
add_definitions(-DPOCO_UNIXODBC)
|
/usr/local/odbc/lib
|
||||||
endif(${UNIX_ODBC_CONFIG} MATCHES "UNIX_ODBC_CONFIG-NOTFOUND")
|
"C:/Program Files/ODBC/lib"
|
||||||
|
"C:/ODBC/lib/debug"
|
||||||
|
"C:/Program Files (x86)/Microsoft SDKs/Windows/v7.0A/Lib"
|
||||||
|
DOC "Specify the ODBC driver manager library here."
|
||||||
|
)
|
||||||
|
|
||||||
find_program(IODBC_CONFIG iodbc-config
|
# MinGW find usually fails
|
||||||
$ENV{ODBC_PATH}/bin
|
if(MINGW)
|
||||||
/usr/bin
|
set(ODBC_INCLUDE_DIRECTORIES ".")
|
||||||
/usr/local/bin
|
set(ODBC_LIBRARIES odbc32)
|
||||||
PATHS)
|
endif()
|
||||||
|
|
||||||
|
include(FindPackageHandleStandardArgs)
|
||||||
|
find_package_handle_standard_args(ODBC
|
||||||
|
DEFAULT_MSG
|
||||||
|
ODBC_INCLUDE_DIRECTORIES
|
||||||
|
ODBC_LIBRARIES
|
||||||
|
)
|
||||||
|
|
||||||
if(${IODBC_CONFIG} MATCHES "IODBC_CONFIG-NOTFOUND")
|
mark_as_advanced(ODBC_FOUND ODBC_LIBRARIES ODBC_INCLUDE_DIRECTORIES)
|
||||||
message(STATUS "Couldn't find iODBC")
|
|
||||||
else(${IODBC_CONFIG} MATCHES "IODBC_CONFIG-NOTFOUND")
|
|
||||||
message(STATUS "Found iODBC: iodbc-config in ${IODBC_CONFIG}")
|
|
||||||
exec_program(${IODBC_CONFIG} ARGS "--cflags" OUTPUT_VARIABLE ODBC_CFLAGS)
|
|
||||||
add_definitions( ${ODBC_CFLAGS} )
|
|
||||||
exec_program(${IODBC_CONFIG} ARGS "--libs" OUTPUT_VARIABLE ODBC_LINK_FLAGS)
|
|
||||||
add_definitions(-DPOCO_IODBC)
|
|
||||||
endif(${IODBC_CONFIG} MATCHES "IODBC_CONFIG-NOTFOUND")
|
|
||||||
|
|
||||||
message(STATUS "UNIX ODBC: ${UNIX_ODBC_CONFIG}")
|
|
||||||
message(STATUS "IODBC: ${IODBC_CONFIG}")
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user