Commit | Line | Data |
---|---|---|
263b5807 TJ |
1 | include_directories( |
2 | ${CMAKE_SOURCE_DIR}/src | |
3 | ${CMAKE_SOURCE_DIR}/utils | |
4 | ${ICONV_INCLUDE_DIRS} | |
5 | ) | |
6 | ||
7 | SET(cpp_sources | |
8 | cron.cpp | |
69d568dd | 9 | crypto.cpp |
263b5807 TJ |
10 | daemonfunc.cpp |
11 | filefunc.cpp | |
12 | i18n.cpp | |
13 | i2n_configfile.cpp | |
14 | ipfunc.cpp | |
15 | logfunc.cpp | |
16 | logread.cpp | |
17 | oftmpstream.cpp | |
18 | pidfile.cpp | |
7e606af5 | 19 | pipestream.cpp |
263b5807 | 20 | pointer_func.cpp |
09ca2cbf | 21 | restricted_html.cpp |
263b5807 TJ |
22 | source_track_basics.cpp |
23 | stringfunc.cpp | |
24 | timefunc.cpp | |
25 | tmpfstream.cpp | |
26 | tracefunc.cpp | |
27 | tribool.cpp | |
28 | userfunc.cpp | |
29 | week.cpp | |
30 | ) | |
31 | ||
57cee5f6 | 32 | SET(cpp_headers |
263b5807 | 33 | cron.hpp |
69d568dd | 34 | crypto.hxx |
263b5807 TJ |
35 | daemonfunc.hpp |
36 | exception.hxx | |
37 | filefunc.hxx | |
38 | i18n.h | |
39 | i2n_configdata.hpp | |
40 | i2n_configfile.hpp | |
41 | insocketstream.hxx | |
42 | ip_type.hxx | |
43 | ipfunc.hxx | |
44 | log_macros.hpp | |
45 | logfunc.hpp | |
46 | logread.hxx | |
47 | oftmpstream.hxx | |
48 | pidfile.hpp | |
49 | pipestream.hxx | |
50 | pointer_func.hpp | |
09ca2cbf | 51 | restricted_html.hpp |
263b5807 TJ |
52 | source_track_basics.hpp |
53 | stringfunc.hxx | |
54 | timefunc.hxx | |
55 | tmpfstream.hpp | |
56 | tmpfstream_impl.hpp | |
57 | tracefunc.hpp | |
58 | tribool.hpp | |
59 | userfunc.hpp | |
60 | week.hpp | |
61 | ) | |
62 | ||
57cee5f6 | 63 | add_library(i2ncommon SHARED ${cpp_sources} ${cpp_headers}) |
263b5807 | 64 | |
2bb72337 TJ |
65 | target_link_libraries(i2ncommon |
66 | ${Boost_IOSTREAMS_LIBRARIES} | |
67 | ${Boost_THREAD_LIBRARIES} | |
68 | ${ICONV_LIBRARIES} | |
69 | ${OPENSSL_LIBRARIES}) | |
263b5807 | 70 | |
78cd0cd1 | 71 | set_target_properties(i2ncommon PROPERTIES VERSION ${VERSION} SOVERSION 7) |
adf4a846 GE |
72 | set_target_properties(i2ncommon PROPERTIES OUTPUT_NAME i2ncommon CLEAN_DIRECT_OUTPUT 1) |
73 | ||
74 | add_library(i2ncommon_static STATIC ${cpp_sources} ${cpp_headers}) | |
75 | set_target_properties(i2ncommon_static PROPERTIES OUTPUT_NAME i2ncommon CLEAN_DIRECT_OUTPUT 1) | |
263b5807 TJ |
76 | |
77 | install(TARGETS i2ncommon | |
4a1afbc0 | 78 | LIBRARY DESTINATION lib${LIB_SUFFIX} |
263b5807 TJ |
79 | COMPONENT sharedlibs) |
80 | ||
adf4a846 GE |
81 | install(TARGETS i2ncommon_static |
82 | ARCHIVE DESTINATION lib${LIB_SUFFIX} | |
83 | COMPONENT staticlibs) | |
84 | ||
263b5807 | 85 | install(FILES ${cpp_headers} |
c6e19f3d | 86 | DESTINATION include/${PROJECT_NAME} |
263b5807 | 87 | COMPONENT headers) |