X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=src%2Fcommon%2FCMakeLists.txt;h=0e3e2a1cb4e1dee8679537913134603e0260ed6b;hp=4218661e86e67698b62f7a2331252c046fa4a9bb;hb=d20a7db77425fab0c44e5bf307ba0061ddaf9faf;hpb=5cfabc7f10123e0e4f03f76ef8ecbdd6c36df511 diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index 4218661e..0e3e2a1c 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -1,5 +1,4 @@ # Builds the common module - set(QT_DONT_USE_QTGUI 1) set(QT_USE_QTNETWORK 1) include(${QT_USE_FILE}) @@ -7,17 +6,27 @@ include(${QT_USE_FILE}) set(SOURCES aliasmanager.cpp backlogmanager.cpp + basichandler.cpp bufferinfo.cpp buffersyncer.cpp bufferviewconfig.cpp bufferviewmanager.cpp cliparser.cpp + ctcpevent.cpp + event.cpp + eventmanager.cpp identity.cpp + ignorelistmanager.cpp ircchannel.cpp + ircevent.cpp + irclisthelper.cpp ircuser.cpp logger.cpp message.cpp + messageevent.cpp network.cpp + networkconfig.cpp + networkevent.cpp quassel.cpp settings.cpp signalproxy.cpp @@ -27,35 +36,58 @@ set(SOURCES set(MOC_HDRS aliasmanager.h backlogmanager.h + basichandler.h buffersyncer.h bufferviewconfig.h bufferviewmanager.h coreinfo.h + eventmanager.h identity.h + ignorelistmanager.h ircchannel.h irclisthelper.h ircuser.h network.h + networkconfig.h settings.h signalproxy.h syncableobject.h) set(HEADERS ${MOC_HDRS} + abstractcliparser.h bufferinfo.h cliparser.h + ctcpevent.h + event.h + ircevent.h + networkevent.h + messageevent.h logger.h message.h types.h util.h) -qt4_wrap_cpp(MOC ${MOC_HDRS}) +if(APPLE) + set(SOURCES ${SOURCES} mac_utils.cpp) + set(HEADERS ${HEADERS} mac_utils.h) +endif(APPLE) +if(CMAKE_HOST_WIN32) + set(SOURCES ${SOURCES} logbacktrace_win.cpp) +endif(CMAKE_HOST_WIN32) +if(CMAKE_HOST_UNIX) + set(SOURCES ${SOURCES} logbacktrace_unix.cpp) +endif(CMAKE_HOST_UNIX) + +qt4_wrap_cpp(MOC ${MOC_HDRS}) include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_SOURCE_DIR}) # for version.inc and version.gen -add_definitions(-DHAVE_VERSION_GEN) # we ensure that by deps in the main CMakeLists.txt set_directory_properties(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES version.gen) -add_library(mod_common STATIC ${SOURCES} ${MOC} ${CMAKE_BINARY_DIR}/i18n/qrc_i18n.cxx) -set_source_files_properties(${CMAKE_BINARY_DIR}/i18n/qrc_i18n.cxx PROPERTIES GENERATED true) -add_dependencies(mod_common i18n) +add_library(mod_common STATIC ${SOURCES} ${MOC}) + +if(APPLE) + target_link_libraries(mod_common "-framework CoreServices" "-framework CoreFoundation") +endif(APPLE) +target_link_libraries(mod_common ${CMAKE_DL_LIBS})