1 set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${KDE4_ENABLE_EXCEPTIONS}" )
3 check_include_files(sys/inotify.h SYS_INOTIFY_H_FOUND)
4 macro_bool_to_01(SYS_INOTIFY_H_FOUND HAVE_SYS_INOTIFY_H)
5 configure_file(config-messageviewer.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-messageviewer.h)
7 add_subdirectory(tests)
10 option(MESSAGEVIEWER_NO_WEBKIT "Use QTextBrowser instead of WebKit for the message viewer" FALSE)
11 if(MESSAGEVIEWER_NO_WEBKIT)
12 add_definitions( -DMESSAGEVIEWER_NO_WEBKIT=1 )
13 set(_mailwebview_cpp mailwebview_textbrowser.cpp )
14 set(_mailwebview_lib )
15 else(MESSAGEVIEWER_NO_WEBKIT)
16 set(_mailwebview_cpp mailwebview_webkit.cpp )
18 set(_mailwebview_lib ${KDE4_KDEWEBKIT_LIBRARY} ${QT_QTWEBKIT_LIBRARY})
20 set(_mailwebview_lib ${QT_QTWEBKIT_LIBRARY} )
22 endif(MESSAGEVIEWER_NO_WEBKIT)
24 set(libmessageviewer_SRCS
27 webkitparthtmlwriter.cpp
31 attachmentstrategy.cpp
34 objecttreeparser_p.cpp
38 bodypartformatterfactory.cpp
46 spamheaderanalyzer.cpp
53 objecttreeviewersource.cpp
54 objecttreeemptysource.cpp
57 chiasmuskeyselector.cpp
63 contactphotomemento.cpp
64 invitationsettings.cpp
68 kde4_add_kcfg_files(libmessageviewer_SRCS
69 globalsettings_base.kcfgc
72 kde4_add_ui_files(libmessageviewer_SRCS
77 kde4_add_library(messageviewer ${LIBRARY_TYPE} ${libmessageviewer_SRCS})
79 target_link_libraries(messageviewer messagecore kdepim kpgp kleo
80 ${KDEPIMLIBS_KMIME_LIBS}
81 ${KDEPIMLIBS_AKONADI_LIBS}
82 ${KDEPIMLIBS_AKONADI_KMIME_LIBS}
83 ${KDEPIMLIBS_KPIMUTILS_LIBS}
84 ${KDEPIMLIBS_KABC_LIBS}
85 ${KDEPIMLIBS_MAILTRANSPORT_LIBS}
87 ${KDEPIMLIBS_KTNEF_LIBS}
93 ${CMAKE_SOURCE_DIR}/libkleo
98 set_target_properties( messageviewer PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
99 install(TARGETS messageviewer ${INSTALL_TARGETS_DEFAULT_ARGS} )
101 #install( FILES viewer.h attachmentstrategy.h headerstrategy.h messageviewer_export.h DESTINATION ${INCLUDE_INSTALL_DIR}/messageviewer COMPONENT devel)