Refactor Cipher related things.
[quassel.git] / src / core / CMakeLists.txt
index a6d3f20..6df50bf 100644 (file)
@@ -1,10 +1,6 @@
 # Builds the core module
 
-set(QT_DONT_USE_QTGUI 1)
-set(QT_USE_QTNETWORK 1)
-set(QT_USE_QTSQL 1)
-set(QT_USE_QTSCRIPT 1)
-include(${QT_USE_FILE})
+setup_qt_variables(Network Sql Script)
 
 set(SOURCES
     abstractsqlstorage.cpp
@@ -24,7 +20,6 @@ set(SOURCES
     coreircuser.cpp
     corenetwork.cpp
     corenetworkconfig.cpp
-    oidentdconfiggenerator.cpp
     coresession.cpp
     coresessioneventprocessor.cpp
     coresettings.cpp
@@ -34,6 +29,7 @@ set(SOURCES
     eventstringifier.cpp
     ircparser.cpp
     netsplit.cpp
+    oidentdconfiggenerator.cpp
     postgresqlstorage.cpp
     sessionthread.cpp
     sqlitestorage.cpp
@@ -50,6 +46,7 @@ set(MOC_HDRS
     corebufferviewconfig.h
     corebufferviewmanager.h
     corecoreinfo.h
+    coreeventmanager.h
     coreidentity.h
     coreignorelistmanager.h
     coreircchannel.h
@@ -57,7 +54,6 @@ set(MOC_HDRS
     coreircuser.h
     corenetwork.h
     corenetworkconfig.h
-    oidentdconfiggenerator.h
     coresession.h
     coresessioneventprocessor.h
     coreuserinputhandler.h
@@ -65,6 +61,7 @@ set(MOC_HDRS
     eventstringifier.h
     ircparser.h
     netsplit.h
+    oidentdconfiggenerator.h
     postgresqlstorage.h
     sqlitestorage.h
     storage.h
@@ -86,13 +83,17 @@ if(HAVE_QCA2)
   include_directories(${QCA2_INCLUDE_DIR})
 endif(HAVE_QCA2)
 
-qt4_wrap_cpp(MOC ${MOC_HDRS})
-set(CORE_RCS ${CORE_RCS} core/sql.qrc PARENT_SCOPE)
+include_directories(${CMAKE_SOURCE_DIR}/src/common ${QUASSEL_QT_INCLUDES})
+
+if(NOT WITH_QT5)
+  qt4_wrap_cpp(MOC ${MOC_HDRS})
+endif(NOT WITH_QT5)
 
-include_directories(${CMAKE_SOURCE_DIR}/src/common)
+set(CORE_RCS ${CORE_RCS} core/sql.qrc PARENT_SCOPE)
 
 add_library(mod_core STATIC ${SOURCES} ${MOC} ${HEADERS})
 add_dependencies(mod_core mod_common)
+set_target_properties(mod_core PROPERTIES COMPILE_FLAGS "${QUASSEL_QT_COMPILEFLAGS}")
 
 if(HAVE_QCA2)
   target_link_libraries(mod_core ${QCA2_LIBRARIES})