Add support for compiling with QCA on Qt5
[quassel.git] / src / core / CMakeLists.txt
index cd29875..d6f467f 100644 (file)
@@ -12,7 +12,6 @@ set(SOURCES
     corebufferviewconfig.cpp
     corebufferviewmanager.cpp
     corecoreinfo.cpp
-    coreeventmanager.cpp
     coreidentity.cpp
     coreignorelistmanager.cpp
     coreircchannel.cpp
@@ -55,9 +54,17 @@ if (QCA2_FOUND)
     list(APPEND LIBS ${QCA2_LIBRARIES})
 endif()
 
+if (QCA2-QT5_FOUND)
+    add_definitions(-DHAVE_QCA2)
+    include_directories(${QCA2-QT5_INCLUDE_DIR})
+    list(APPEND SOURCES cipher.cpp)
+    list(APPEND LIBS ${QCA2-QT5_LIBRARIES})
+endif()
+
 include_directories(${CMAKE_SOURCE_DIR}/src/common)
 
-set(CORE_RCS ${CORE_RCS} core/sql.qrc PARENT_SCOPE)
+set(CORE_RCS ${CORE_RCS} ${CMAKE_CURRENT_SOURCE_DIR}/sql.qrc)
+qt_add_resources(SOURCES ${CORE_RCS})
 
 add_library(mod_core STATIC ${SOURCES})
 qt_use_modules(mod_core Core Network Script Sql)