mirror of
https://github.com/pocoproject/poco.git
synced 2025-11-25 06:36:37 +01:00
cmake: Foundation cleanup
- add NumericString.cpp to source files - support unbundled pcre and zlib - add OpcomChannel to OPENVMS_SRC for later OpenVMS support - Reviewed-by: Roger Meier <r.meier@siemens.com>
This commit is contained in:
@@ -108,7 +108,7 @@ set( BASE_SRCS
|
|||||||
src/NullStream.cpp
|
src/NullStream.cpp
|
||||||
src/NumberFormatter.cpp
|
src/NumberFormatter.cpp
|
||||||
src/NumberParser.cpp
|
src/NumberParser.cpp
|
||||||
# src/OpcomChannel.cpp
|
src/NumericString.cpp
|
||||||
src/Path.cpp
|
src/Path.cpp
|
||||||
src/PatternFormatter.cpp
|
src/PatternFormatter.cpp
|
||||||
src/Pipe.cpp
|
src/Pipe.cpp
|
||||||
@@ -176,14 +176,21 @@ set( BASE_SRCS
|
|||||||
src/Windows1250Encoding.cpp
|
src/Windows1250Encoding.cpp
|
||||||
src/Windows1251Encoding.cpp
|
src/Windows1251Encoding.cpp
|
||||||
src/Windows1252Encoding.cpp
|
src/Windows1252Encoding.cpp
|
||||||
src/adler32.c
|
)
|
||||||
src/compress.c
|
|
||||||
src/crc32.c
|
# If POCO_UNBUNDLED is enabled we try to find the required packages
|
||||||
src/deflate.c
|
# The configuration will fail if the packages are not found
|
||||||
src/infback.c
|
if (POCO_UNBUNDLED)
|
||||||
src/inffast.c
|
find_package(PCRE REQUIRED)
|
||||||
src/inflate.c
|
set(SYSLIBS ${SYSLIBS} ${PCRE_LIBRARIES})
|
||||||
src/inftrees.c
|
include_directories(${PCRE_INCLUDE_DIRS})
|
||||||
|
|
||||||
|
find_package(ZLIB REQUIRED)
|
||||||
|
set(SYSLIBS ${SYSLIBS} ${ZLIB_LIBRARIES})
|
||||||
|
include_directories(${ZLIB_INCLUDE_DIRS})
|
||||||
|
else()
|
||||||
|
# PCRE
|
||||||
|
list(APPEND BASE_SRCS
|
||||||
src/pcre_chartables.c
|
src/pcre_chartables.c
|
||||||
src/pcre_compile.c
|
src/pcre_compile.c
|
||||||
src/pcre_exec.c
|
src/pcre_exec.c
|
||||||
@@ -198,10 +205,22 @@ set( BASE_SRCS
|
|||||||
src/pcre_ucd.c
|
src/pcre_ucd.c
|
||||||
src/pcre_valid_utf8.c
|
src/pcre_valid_utf8.c
|
||||||
src/pcre_xclass.c
|
src/pcre_xclass.c
|
||||||
src/pocomsg.mc
|
)
|
||||||
|
|
||||||
|
# ZLIB
|
||||||
|
list(APPEND BASE_SRCS
|
||||||
|
src/adler32.c
|
||||||
|
src/compress.c
|
||||||
|
src/crc32.c
|
||||||
|
src/deflate.c
|
||||||
|
src/infback.c
|
||||||
|
src/inffast.c
|
||||||
|
src/inflate.c
|
||||||
|
src/inftrees.c
|
||||||
src/trees.c
|
src/trees.c
|
||||||
src/zutil.c
|
src/zutil.c
|
||||||
)
|
)
|
||||||
|
endif (POCO_UNBUNDLED)
|
||||||
|
|
||||||
set(WIN_SRCS
|
set(WIN_SRCS
|
||||||
src/EventLogChannel.cpp
|
src/EventLogChannel.cpp
|
||||||
@@ -228,6 +247,11 @@ set(LIN_SRCS
|
|||||||
src/SyslogChannel.cpp
|
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})
|
set(SRCS ${BASE_SRCS} ${WIN_SRCS})
|
||||||
add_definitions( -DPCRE_STATIC -DFoundation_EXPORTS)
|
add_definitions( -DPCRE_STATIC -DFoundation_EXPORTS)
|
||||||
|
|||||||
Reference in New Issue
Block a user