Abstract away the protocol handshake code
[quassel.git] / src / core / CMakeLists.txt
1 # Builds the core module
2
3 setup_qt_variables(Network Sql Script)
4
5 set(SOURCES
6     abstractsqlstorage.cpp
7     core.cpp
8     corealiasmanager.cpp
9     coreapplication.cpp
10     coreauthhandler.cpp
11     corebacklogmanager.cpp
12     corebasichandler.cpp
13     corebuffersyncer.cpp
14     corebufferviewconfig.cpp
15     corebufferviewmanager.cpp
16     corecoreinfo.cpp
17     coreidentity.cpp
18     coreignorelistmanager.cpp
19     coreircchannel.cpp
20     coreirclisthelper.cpp
21     coreircuser.cpp
22     corenetwork.cpp
23     corenetworkconfig.cpp
24     coresession.cpp
25     coresessioneventprocessor.cpp
26     coresettings.cpp
27     coreuserinputhandler.cpp
28     coreusersettings.cpp
29     ctcpparser.cpp
30     eventstringifier.cpp
31     ircparser.cpp
32     netsplit.cpp
33     oidentdconfiggenerator.cpp
34     postgresqlstorage.cpp
35     sessionthread.cpp
36     sqlitestorage.cpp
37     storage.cpp)
38
39 set(MOC_HDRS
40     abstractsqlstorage.h
41     core.h
42     corealiasmanager.h
43     coreapplication.h
44     coreauthhandler.h
45     corebacklogmanager.h
46     corebasichandler.h
47     corebuffersyncer.h
48     corebufferviewconfig.h
49     corebufferviewmanager.h
50     corecoreinfo.h
51     coreeventmanager.h
52     coreidentity.h
53     coreignorelistmanager.h
54     coreircchannel.h
55     coreirclisthelper.h
56     coreircuser.h
57     corenetwork.h
58     corenetworkconfig.h
59     coresession.h
60     coresessioneventprocessor.h
61     coreuserinputhandler.h
62     ctcpparser.h
63     eventstringifier.h
64     ircparser.h
65     netsplit.h
66     oidentdconfiggenerator.h
67     postgresqlstorage.h
68     sqlitestorage.h
69     storage.h
70     sessionthread.h)
71
72 set(HEADERS
73     coresettings.h
74     coreusersettings.h)
75
76 if(HAVE_SSL)
77   set(SOURCES ${SOURCES} sslserver.cpp)
78   set(MOC_HDRS ${MOC_HDRS} sslserver.h)
79   include_directories(${OPENSSL_INCLUDE_DIR})
80 endif(HAVE_SSL)
81
82 if(HAVE_QCA2)
83   set(SOURCES ${SOURCES} cipher.cpp)
84   set(HEADERS ${HEADERS} cipher.h)
85   include_directories(${QCA2_INCLUDE_DIR})
86 endif(HAVE_QCA2)
87
88 include_directories(${CMAKE_SOURCE_DIR}/src/common ${QUASSEL_QT_INCLUDES})
89
90 if(NOT WITH_QT5)
91   qt4_wrap_cpp(MOC ${MOC_HDRS})
92 endif(NOT WITH_QT5)
93
94 set(CORE_RCS ${CORE_RCS} core/sql.qrc PARENT_SCOPE)
95
96 add_library(mod_core STATIC ${SOURCES} ${MOC} ${HEADERS})
97 add_dependencies(mod_core mod_common)
98 set_target_properties(mod_core PROPERTIES COMPILE_FLAGS "${QUASSEL_QT_COMPILEFLAGS}")
99
100 if(HAVE_QCA2)
101   target_link_libraries(mod_core ${QCA2_LIBRARIES})
102 endif(HAVE_QCA2)