CMakeLists.txt 18.9 KB
Newer Older
1
2
add_definitions(-DTRANSLATION_DOMAIN=\"libmessageviewer\")

3
4
add_subdirectory(messagepartthemes/grantlee)

5
6
7
8
# KCFG files:
# The main messageviewer.kcfg is configured by CMake and put in the build directory.

if(KDEPIM_ENTERPRISE_BUILD)
Laurent Montel's avatar
Laurent Montel committed
9
10
11
    set(LEGACY_MANGLE_FROM_TO_HEADERS true)
    set(LEGACY_BODY_INVITES true)
    set(EXCHANGE_COMPATIBLE_INVITATIONS true)
12
else()
Laurent Montel's avatar
Laurent Montel committed
13
14
15
    set(LEGACY_MANGLE_FROM_TO_HEADERS false)
    set(LEGACY_BODY_INVITES false)
    set(EXCHANGE_COMPATIBLE_INVITATIONS false)
16
17
18
19
endif()

configure_file(settings/messageviewer.kcfg.cmake ${CMAKE_CURRENT_BINARY_DIR}/messageviewer.kcfg)
include(CheckIncludeFiles)
Tobias C. Berner's avatar
Tobias C. Berner committed
20
21
22
find_package(Inotify)
set_package_properties(Inotify PROPERTIES
                       PURPOSE "Filesystem alteration notifications using inotify")
23
24
25
26
27
if(Inotify_FOUND)
    set(HAVE_SYS_INOTIFY_H 1)
else()
    set(HAVE_SYS_INOTIFY_H 0)
endif()
Laurent Montel's avatar
Laurent Montel committed
28

29
find_package(Qca-qt5 2.2.0 CONFIG REQUIRED)
Laurent Montel's avatar
Laurent Montel committed
30
set_package_properties(Qca-qt5 PROPERTIES DESCRIPTION "Qt Cryptographic Architecture"
Laurent Montel's avatar
Laurent Montel committed
31
                   URL "https://invent.kde.org/libraries/qca" TYPE REQUIRED
Laurent Montel's avatar
Laurent Montel committed
32
                   PURPOSE "Needed for dkim support.")
Laurent Montel's avatar
Laurent Montel committed
33
34


35
36
37
38
39
40
configure_file(config-messageviewer.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config-messageviewer.h)

# target_include_directories does not handle empty include paths
include_directories(${GPGME_INCLUDES})

if(BUILD_TESTING)
41
    add_subdirectory(header/autotests)
Laurent Montel's avatar
Laurent Montel committed
42
43
44
    add_subdirectory(scamdetection/autotests)
    add_subdirectory(scamdetection/tests)
    add_subdirectory(viewerplugins/tests/)
45
    add_subdirectory(htmlwriter/autotests)
Laurent Montel's avatar
Laurent Montel committed
46
    add_subdirectory(viewer/webengine/tests)
47
    add_subdirectory(messagepartthemes/default/autotests)
Laurent Montel's avatar
Laurent Montel committed
48
    add_subdirectory(widgets/autotests/)
49
    add_subdirectory(utils/autotests)
50
    add_subdirectory(viewer/renderer/autotests)
Laurent Montel's avatar
Laurent Montel committed
51
    add_subdirectory(remote-content/autotests)
52
53
54
55
endif()
add_subdirectory(pics)
add_subdirectory(kconf_update)
add_subdirectory(about)
56
add_subdirectory(messageviewerheaderplugins)
57

58
if (${Qca-qt5_FOUND})
59
60
    if (BUILD_TESTING)
        add_subdirectory(dkim-verify/autotests)
61
	add_subdirectory(dkim-verify/tests)
62
    endif()
Laurent Montel's avatar
Laurent Montel committed
63
64
65
66
67
    set(dkim_verify_SRCS
        dkim-verify/dkiminfo.cpp
        dkim-verify/dkimmanagerkey.cpp
        dkim-verify/dkimmanagerkeywidget.cpp
        dkim-verify/dkimmanagerkeydialog.cpp
Laurent Montel's avatar
Laurent Montel committed
68
        dkim-verify/dkimdownloadkeyjob.cpp
69
        dkim-verify/dkimchecksignaturejob.cpp
Laurent Montel's avatar
Laurent Montel committed
70
71
        dkim-verify/dkimcheckauthenticationstatusjob.cpp
        dkim-verify/dkimauthenticationstatusinfo.cpp
Laurent Montel's avatar
Laurent Montel committed
72
        dkim-verify/dkimutil.cpp
73
        dkim-verify/dkimkeyrecord.cpp
Laurent Montel's avatar
Laurent Montel committed
74
        dkim-verify/dkimmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
75
        dkim-verify/dkimresultattribute.cpp
Laurent Montel's avatar
Laurent Montel committed
76
        dkim-verify/dkimwidgetinfo.cpp
Laurent Montel's avatar
Laurent Montel committed
77
        dkim-verify/dkimstoreresultjob.cpp
78
        dkim-verify/dkimheaderparser.cpp
79
        dkim-verify/dkimcheckpolicy.cpp
80
        dkim-verify/dmarcrecordjob.cpp
Laurent Montel's avatar
Laurent Montel committed
81
        dkim-verify/dmarcinfo.cpp
82
        dkim-verify/dmarcpolicyjob.cpp
Laurent Montel's avatar
Laurent Montel committed
83
        dkim-verify/dkimcheckpolicyjob.cpp
Laurent Montel's avatar
Laurent Montel committed
84
        dkim-verify/dkimrule.cpp
85
        dkim-verify/dkimmanagerrules.cpp
86
        dkim-verify/dkimgeneraterulejob.cpp
Laurent Montel's avatar
Laurent Montel committed
87
        dkim-verify/dkimauthenticationstatusinfoutil.cpp
Laurent Montel's avatar
Laurent Montel committed
88
        dkim-verify/dkimcheckfulljob.cpp
Laurent Montel's avatar
Laurent Montel committed
89
        dkim-verify/dkimauthenticationstatusinfoconverter.cpp
90
        dkim-verify/dkimmanagerauthenticationserver.cpp
Laurent Montel's avatar
Laurent Montel committed
91
        dkim-verify/dkimviewermenu.cpp
Laurent Montel's avatar
Laurent Montel committed
92
93
94
95
96
        dkim-verify/dkimmanagerulescombobox.cpp
        dkim-verify/dkimmanagerulesdialog.cpp
        dkim-verify/dkimmanageruleswidget.cpp
        dkim-verify/dkimruledialog.cpp
        dkim-verify/dkimrulewidget.cpp
97
        dkim-verify/dmarcmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
98
        )
99
100
endif()

101
102
103
104
set(messageviewer_renderer_SRCS
    viewer/renderer/messageviewerrenderer.cpp
    )

105
if(DEBUG_SIGNATURE)
Laurent Montel's avatar
Laurent Montel committed
106
    add_definitions(-DDEBUG_SIGNATURE)
107
endif()
Laurent Montel's avatar
Laurent Montel committed
108
109
110
111
112
113
114
115
116
if (MESSAGEVIEWER_EXPERIMENTAL_CONVERSATIONVIEW)
    set(libmessageviewer_conversationviewer_SRCS
        conversationview/conversationviewwidget.cpp
        )
    if (BUILD_TESTING)
        add_subdirectory(conversationview/autotests)
        add_subdirectory(conversationview/tests)
    endif()
endif()
117

Laurent Montel's avatar
Laurent Montel committed
118
119
120
121
122
set(libmessageviewer_mailviewer_SRCS
    viewer/webengine/mailwebengineview.cpp
    viewer/webengine/mailwebenginepage.cpp
    viewer/webengine/loadexternalreferencesurlinterceptor/loadexternalreferencesurlinterceptor.cpp
    viewer/webengine/cidreferencesurlinterceptor/cidreferencesurlinterceptor.cpp
Laurent Montel's avatar
Laurent Montel committed
123
    viewer/webengine/cidschemehandler/cidschemehandler.cpp
Laurent Montel's avatar
Laurent Montel committed
124
    )
Laurent Montel's avatar
Laurent Montel committed
125

126
set(libmessageviewer_viewer_SRCS
127
    viewer/attachmentstrategy.cpp
Laurent Montel's avatar
Laurent Montel committed
128
    viewer/csshelper.cpp
129
    viewer/csshelperbase.cpp
Laurent Montel's avatar
Laurent Montel committed
130
131
132
133
134
135
136
137
    viewer/editorwatcher.cpp
    viewer/objecttreeemptysource.cpp
    viewer/objecttreeviewersource.cpp
    viewer/viewer.cpp
    viewer/viewer_p.cpp
    viewer/messagedisplayformatattribute.cpp
    viewer/urlhandlermanager.cpp
    viewer/mimeparttree/mimeparttreeview.cpp
138
    viewer/mimeparttree/mimetreemodel.cpp
139
    viewer/viewerpurposemenuwidget.cpp
140
    viewer/messagewidgetarea.cpp
Laurent Montel's avatar
Laurent Montel committed
141
    )
142
143

set(libmessageviewer_widgets_SRCS
Laurent Montel's avatar
Laurent Montel committed
144
145
146
147
148
149
    widgets/attachmentdialog.cpp
    widgets/configurewidget.cpp
    widgets/printingsettings.cpp
    widgets/htmlstatusbar.cpp
    widgets/vcardviewer.cpp
    widgets/invitationsettings.cpp
150
    widgets/opensavedfilefolderwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
151
    widgets/mailsourceviewtextbrowserwidget.cpp
152
    widgets/submittedformwarningwidget.cpp
153
    widgets/shownextmessagewidget.cpp
Laurent Montel's avatar
Laurent Montel committed
154
    )
155

Laurent Montel's avatar
Laurent Montel committed
156

Laurent Montel's avatar
Laurent Montel committed
157
158
159
set(libmessageviewer_widgets_webengine_SRCS
    widgets/mailsourcewebengineviewer.cpp
    )
160

161
set(libmessageviewer_header_SRCS
Laurent Montel's avatar
Laurent Montel committed
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
    header/contactdisplaymessagememento.cpp
    header/headerstrategy.cpp
    header/richheaderstrategy.cpp
    header/headerstyle.cpp
    header/grantleeheaderstyle.cpp
    header/plainheaderstyle.cpp
    header/headerstyle_util.cpp
    header/grantleeheaderformatter.cpp
    header/grantleeheaderteststyle.cpp
    header/kxface.cpp
    header/headerstyleplugin.cpp
    header/headerstylepluginmanager.cpp
    header/headerstyleinterface.cpp
    header/headerstylemenumanager.cpp
    )
177
178

set(libmessageviewer_scamdetection_SRCS
Laurent Montel's avatar
Laurent Montel committed
179
180
181
182
    scamdetection/scamdetectionwarningwidget.cpp
    scamdetection/scamdetectiondetailsdialog.cpp
    scamdetection/scamattribute.cpp
    scamdetection/scamcheckshorturl.cpp
183
    scamdetection/scamexpandurljob.cpp
Laurent Montel's avatar
Laurent Montel committed
184
    scamdetection/scamcheckshorturlmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
185
    )
186

Laurent Montel's avatar
Laurent Montel committed
187
188
189
set(libmessageviewer_scamdetection_webengine_SRCS
    scamdetection/scamdetectionwebengine.cpp
    )
190

191
set(libmessageviewer_findbar_SRCS
Laurent Montel's avatar
Laurent Montel committed
192
193
    findbar/findbarsourceview.cpp
    )
194
195

set(libmessageviewer_utils_SRCS
196
    utils/iconnamecache.cpp
Laurent Montel's avatar
Laurent Montel committed
197
198
    utils/markmessagereadhandler.cpp
    utils/messageviewerutil.cpp
Sandro Knauß's avatar
Sandro Knauß committed
199
    utils/mimetype.cpp
Laurent Montel's avatar
Laurent Montel committed
200
    )
201

202
set(libmessageviewer_htmlwriter_SRCS
Laurent Montel's avatar
Laurent Montel committed
203
204
    htmlwriter/webengineparthtmlwriter.cpp
    htmlwriter/webengineembedpart.cpp
205
206
207
208
    htmlwriter/bufferedhtmlwriter.cpp
    htmlwriter/filehtmlwriter.cpp
    )

209
set(libmessageviewer_antispam_SRCS
Laurent Montel's avatar
Laurent Montel committed
210
211
212
    antispam/spamheaderanalyzer.cpp
    antispam/antispamconfig.cpp
    )
213
214

set(libmessageviewer_job_SRCS
Laurent Montel's avatar
Laurent Montel committed
215
216
    job/modifymessagedisplayformatjob.cpp
    )
217
218

set(libmessageviewer_viewerplugins_SRCS
Laurent Montel's avatar
Laurent Montel committed
219
220
221
222
223
    viewerplugins/viewerpluginmanager.cpp
    viewerplugins/viewerplugin.cpp
    viewerplugins/viewerplugininterface.cpp
    viewerplugins/viewerplugintoolmanager.cpp
    )
224

Laurent Montel's avatar
Laurent Montel committed
225
226
set(libmessageviewer_configureplugins_SRCS
    messageviewerconfigureplugins/messageviewerconfiguresettingsplugin.cpp
Laurent Montel's avatar
Laurent Montel committed
227
    messageviewerconfigureplugins/messageviewerconfiguresettingspluginmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
228
    messageviewerconfigureplugins/messageviewerconfiguresettingspluginwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
229
230
    )

231
232
233
234
set(libmessageviewer_messagepartthemes_default_SRCS
    messagepartthemes/default/converthtmltoplaintext.cpp
    messagepartthemes/default/defaultrenderer.cpp
    messagepartthemes/default/htmlblock.cpp
235
    messagepartthemes/default/messagepartrenderermanager.cpp
236
    messagepartthemes/default/plugins/attachmentmessagepartrenderer.cpp
237
    messagepartthemes/default/plugins/messagepartrenderer.cpp
Sandro Knauß's avatar
Sandro Knauß committed
238
    messagepartthemes/default/plugins/textmessagepartrenderer.cpp
Sandro Knauß's avatar
Sandro Knauß committed
239
    messagepartthemes/default/plugins/quotehtml.cpp
240
    messagepartthemes/default/messagepartrenderbase.cpp
Volker Krause's avatar
Volker Krause committed
241
    messagepartthemes/default/messagepartrenderplugin.cpp
242
    messagepartthemes/default/messagepartrendererfactory.cpp
243
244
    )

245
246
247
248
set(libmessageviewer_interfaces_SRCS
    interfaces/htmlwriter.cpp
    )

249
250
set(libmessageviewer_remotecontent
    remote-content/remotecontentmanager.cpp
251
    remote-content/remotecontentinfo.cpp
Laurent Montel's avatar
Laurent Montel committed
252
    remote-content/remotecontentmenu.cpp
253
    remote-content/remotecontentconfiguredialog.cpp
Laurent Montel's avatar
Laurent Montel committed
254
    remote-content/remotecontentconfigurewidget.cpp
255
256
    remote-content/remotecontentdialog.cpp
    remote-content/remotecontentwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
257
    remote-content/remotecontentstatustypecombobox.cpp
258
259
    )

260
set(libmessageviewer_SRCS
261
    ${libmessageviewer_remotecontent}
262
    ${messageviewer_renderer_SRCS}
263
    ${libmessageviewer_conversationviewer_SRCS}
Laurent Montel's avatar
Laurent Montel committed
264
    ${dkim_verify_SRCS}
Laurent Montel's avatar
Laurent Montel committed
265
    ${libmessageviewer_messagepartthemes_default_SRCS}
266
    ${libmessageviewer_htmlwriter_SRCS}
267
    ${libmessageviewer_messagepartthemes_SRCS}
268
    ${libmessageviewer_scamdetection_webengine_SRCS}
269
    ${libmessageviewer_widgets_webengine_SRCS}
Laurent Montel's avatar
Laurent Montel committed
270
271
272
273
274
275
276
277
278
279
280
    ${libmessageviewer_viewer_SRCS}
    ${libmessageviewer_widgets_SRCS}
    ${libmessageviewer_header_SRCS}
    ${libmessageviewer_scamdetection_SRCS}
    ${libmessageviewer_findbar_SRCS}
    ${libmessageviewer_utils_SRCS}
    ${libmessageviewer_antispam_SRCS}
    ${libmessageviewer_job_SRCS}
    ${libmessageviewer_viewerplugins_SRCS}
    settings/messageviewersettings.cpp
    ${libmessageviewer_mailviewer_SRCS}
281
    ${libmessageviewer_interfaces_SRCS}
Laurent Montel's avatar
Laurent Montel committed
282
    ${libmessageviewer_configureplugins_SRCS}
Laurent Montel's avatar
Laurent Montel committed
283
    messagepartthemes.qrc
Laurent Montel's avatar
Laurent Montel committed
284
    )
285

286
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_debug.h IDENTIFIER MESSAGEVIEWER_LOG CATEGORY_NAME org.kde.pim.messageviewer
Laurent Montel's avatar
Laurent Montel committed
287
288
289
290
        DESCRIPTION "messagelib (messageviewer)"
        OLD_CATEGORY_NAMES log_messageviewer
        EXPORT MESSAGELIB
    )
291
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_dkimcheckerdebug.h IDENTIFIER MESSAGEVIEWER_DKIMCHECKER_LOG CATEGORY_NAME org.kde.pim.messageviewer_dkimchecker
Laurent Montel's avatar
Laurent Montel committed
292
293
294
295
296
        DESCRIPTION "messagelib (messageviewer dkim support)"
        EXPORT MESSAGELIB
    )


297
kconfig_add_kcfg_files(libmessageviewer_SRCS
Laurent Montel's avatar
Laurent Montel committed
298
299
    settings/globalsettings_messageviewer.kcfgc
    )
300
301

ki18n_wrap_ui(libmessageviewer_SRCS
Laurent Montel's avatar
Laurent Montel committed
302
303
304
305
    ui/settings.ui
    ui/invitationsettings.ui
    ui/printingsettings.ui
    )
306
307
308


add_library(KF5MessageViewer ${libmessageviewer_SRCS})
Laurent Montel's avatar
Laurent Montel committed
309
if (COMPILE_WITH_UNITY_CMAKE_SUPPORT)
310
311
312
    set_target_properties(KF5MessageViewer PROPERTIES UNITY_BUILD ON)
endif()

313
314
315
generate_export_header(KF5MessageViewer BASE_NAME messageviewer)
add_library(KF5::MessageViewer ALIAS KF5MessageViewer)

316
317
318
319
320
if (${Inotify_FOUND})
    target_include_directories(KF5MessageViewer INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer/;${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer>;${Inotify_INCLUDE_DIRS}")
else()
    target_include_directories(KF5MessageViewer INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer/;${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer>")
endif()
321

322
if (${Qca-qt5_FOUND})
323
324
325
    set(OPTIONAL_PRIVATE qca-qt5)
endif()

326
target_link_libraries(KF5MessageViewer
Laurent Montel's avatar
Laurent Montel committed
327
328
329
330
331
332
333
    PUBLIC
    KF5::MessageCore
    KF5::PimCommon
    KF5::AkonadiCore
    KF5::AkonadiMime
    KF5::Contacts
    KF5::Libkleo
334
    KF5::MimeTreeParser
335
    KF5::Service
Laurent Montel's avatar
Laurent Montel committed
336
    PRIVATE
337
    KF5::SyntaxHighlighting
Laurent Montel's avatar
Laurent Montel committed
338
    KF5::ItemViews
339
    Qt5::Network
Laurent Montel's avatar
Laurent Montel committed
340
    KF5::WebEngineViewer
Laurent Montel's avatar
Laurent Montel committed
341
    KF5::GrantleeTheme
Laurent Montel's avatar
Laurent Montel committed
342
    KF5::MailTransportAkonadi
Laurent Montel's avatar
Laurent Montel committed
343
344
345
346
    KF5::Mime
    KF5::Mbox
    KF5::PimTextEdit
    KF5::Gravatar
347
    KF5::IdentityManagement
Laurent Montel's avatar
Laurent Montel committed
348
    KF5::IconThemes
349
350
351
352
    KF5::I18n
    KF5::KIOFileWidgets
    KF5::KIOWidgets
    KF5::XmlGui
Laurent Montel's avatar
Laurent Montel committed
353
    KF5::AkonadiContact
354
    Grantlee5::Templates
355
    Qt5::PrintSupport
356
    QGpgme
357
    ${Inotify_LIBRARIES}
358
    ${OPTIONAL_PRIVATE}
Laurent Montel's avatar
Laurent Montel committed
359
    )
360

361
362
363
364
set_target_properties(KF5MessageViewer PROPERTIES
    VERSION ${MESSAGEVIEWER_VERSION_STRING}
    SOVERSION ${MESSAGEVIEWER_SOVERSION}
    EXPORT_NAME MessageViewer
Laurent Montel's avatar
Laurent Montel committed
365
    )
366
367
368

install(TARGETS
    KF5MessageViewer
369
    EXPORT KF5MessageViewerTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS}
Laurent Montel's avatar
Laurent Montel committed
370
    )
371

Laurent Montel's avatar
Laurent Montel committed
372
373
374
375
ecm_generate_headers(MessageViewer_Camelcasewebengine_HEADERS
    HEADER_NAMES
    MailWebEnginePage
    MailWebEngineView
376

Laurent Montel's avatar
Laurent Montel committed
377
378
379
380
    REQUIRED_HEADERS MessageViewer_webengine_HEADERS
    PREFIX MessageViewer
    RELATIVE viewer/webengine
    )
Laurent Montel's avatar
Laurent Montel committed
381

Laurent Montel's avatar
Laurent Montel committed
382
383
384
ecm_generate_headers(MessageViewer_Camelcasescam_HEADERS
    HEADER_NAMES
    ScamExpandUrlJob
Laurent Montel's avatar
Laurent Montel committed
385
    ScamCheckShortUrlManager
Laurent Montel's avatar
Laurent Montel committed
386
    ScamCheckShortUrl
Laurent Montel's avatar
Laurent Montel committed
387
388
389
390
    REQUIRED_HEADERS MessageViewer_scam_HEADERS
    PREFIX MessageViewer
    RELATIVE scamdetection
    )
Laurent Montel's avatar
Laurent Montel committed
391

392
if (${Qca-qt5_FOUND})
Laurent Montel's avatar
Laurent Montel committed
393
394
395
396
397
    ecm_generate_headers(MessageViewer_Cameldkimverify_HEADERS
        HEADER_NAMES
        DKIMManagerKey
        DKIMCheckSignatureJob
        DKIMManager
Laurent Montel's avatar
Laurent Montel committed
398
399
        DKIMManagerKeyWidget
        DKIMManagerKeyDialog
Laurent Montel's avatar
Laurent Montel committed
400
        DKIMKeyRecord
Laurent Montel's avatar
Laurent Montel committed
401
        DKIMInfo
Laurent Montel's avatar
Laurent Montel committed
402
        DKIMWidgetInfo
Laurent Montel's avatar
Laurent Montel committed
403
        DKIMCheckPolicy
404
405
        DKIMManagerRules
        DKIMRule
406
        DKIMHeaderParser
407
        DKIMManagerAuthenticationServer
Laurent Montel's avatar
Laurent Montel committed
408
        DKIMViewerMenu
Laurent Montel's avatar
Laurent Montel committed
409
410
        DKIMManageRulesDialog
        DKIMManageRulesWidget
Laurent Montel's avatar
Laurent Montel committed
411
412
413
414
        REQUIRED_HEADERS MessageViewer_dkimverify_HEADERS
        PREFIX MessageViewer
        RELATIVE dkim-verify
        )
Laurent Montel's avatar
Laurent Montel committed
415
endif()
Laurent Montel's avatar
Laurent Montel committed
416

417
418
419
ecm_generate_headers(MessageViewer_Camelremotecontent_HEADERS
    HEADER_NAMES
    RemoteContentConfigureDialog
Laurent Montel's avatar
Laurent Montel committed
420
    RemoteContentMenu
421
422
423
424
425
    REQUIRED_HEADERS MessageViewer_remotecontent_HEADERS
    PREFIX MessageViewer
    RELATIVE remote-content
    )

Laurent Montel's avatar
Laurent Montel committed
426

427
ecm_generate_headers(MessageViewer_Camelcaseviewer_HEADERS
Laurent Montel's avatar
Laurent Montel committed
428
    HEADER_NAMES
429
    AttachmentStrategy
Laurent Montel's avatar
Laurent Montel committed
430
    Viewer
431
    CSSHelperBase
Laurent Montel's avatar
Laurent Montel committed
432
433
434
435
436
437
438
439
    CSSHelper
    ObjectTreeEmptySource
    EditorWatcher
    Stl_Util
    REQUIRED_HEADERS MessageViewer_viewer_HEADERS
    PREFIX MessageViewer
    RELATIVE viewer
    )
440
441

ecm_generate_headers(MessageViewer_Camelcasewidgets_HEADERS
Laurent Montel's avatar
Laurent Montel committed
442
443
444
445
446
447
448
449
    HEADER_NAMES
    InvitationSettings
    PrintingSettings
    ConfigureWidget
    REQUIRED_HEADERS MessageViewer_widgets_HEADERS
    PREFIX MessageViewer
    RELATIVE widgets
    )
450
451

ecm_generate_headers(MessageViewer_Camelcaseutils_HEADERS
Laurent Montel's avatar
Laurent Montel committed
452
    HEADER_NAMES
453
    IconNameCache
Laurent Montel's avatar
Laurent Montel committed
454
    MarkMessageReadHandler
Sandro Knauß's avatar
Sandro Knauß committed
455
456
    MessageViewerUtil
    MimeType
Laurent Montel's avatar
Laurent Montel committed
457
458
459
460
    REQUIRED_HEADERS MessageViewer_utils_HEADERS
    PREFIX MessageViewer
    RELATIVE utils
    )
461
462

ecm_generate_headers(MessageViewer_Camelcaseantispam_HEADERS
Laurent Montel's avatar
Laurent Montel committed
463
464
465
466
467
468
    HEADER_NAMES
    SpamHeaderAnalyzer
    REQUIRED_HEADERS MessageViewer_antispam_HEADERS
    PREFIX MessageViewer
    RELATIVE antispam
    )
469
470

ecm_generate_headers(MessageViewer_Camelcaseinterfaces_HEADERS
Laurent Montel's avatar
Laurent Montel committed
471
    HEADER_NAMES
472
    HtmlWriter
Laurent Montel's avatar
Laurent Montel committed
473
474
475
476
477
478
    BodyPartURLHandler
    URLHandler
    REQUIRED_HEADERS MessageViewer_interfaces_HEADERS
    PREFIX MessageViewer
    RELATIVE interfaces
    )
479

480
481
482
483
484
485
486
487
488
ecm_generate_headers(MessageViewer_Camelcasehtmlwriter_HEADERS
    HEADER_NAMES
    BufferedHtmlWriter
    FileHtmlWriter
    REQUIRED_HEADERS MessageViewer_htmlwriter_HEADERS
    PREFIX MessageViewer
    RELATIVE htmlwriter
    )

489
ecm_generate_headers(MessageViewer_Camelcasesettings_HEADERS
Laurent Montel's avatar
Laurent Montel committed
490
491
492
493
494
495
    HEADER_NAMES
    MessageViewerSettings
    REQUIRED_HEADERS MessageViewer_settings_HEADERS
    PREFIX MessageViewer
    RELATIVE settings
    )
496

Laurent Montel's avatar
Laurent Montel committed
497
498
499
500
ecm_generate_headers(MessageViewer_CamelcaseConfigurePlugins_HEADERS
    HEADER_NAMES
    MessageViewerConfigureSettingsPluginManager
    MessageViewerConfigureSettingsPlugin
Laurent Montel's avatar
Laurent Montel committed
501
    MessageViewerConfigureSettingsPluginWidget
Laurent Montel's avatar
Laurent Montel committed
502
503
504
505
506
    REQUIRED_HEADERS MessageViewer_ConfigurePlugins_HEADERS
    PREFIX MessageViewer
    RELATIVE messageviewerconfigureplugins
    )

507
508

ecm_generate_headers(MessageViewer_Camelcaseheader_HEADERS
Laurent Montel's avatar
Laurent Montel committed
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
    HEADER_NAMES
    HeaderStrategy
    GrantleeHeaderTestStyle
    GrantleeHeaderStyle
    HeaderStyle
    KXFace
    HeaderStyle_Util
    HeaderStylePlugin
    HeaderStyleInterface
    PlainHeaderStyle
    RichHeaderStrategy
    HeaderStylePluginManager
    HeaderStyleMenuManager
    REQUIRED_HEADERS MessageViewer_header_HEADERS
    PREFIX MessageViewer
    RELATIVE header
    )
526
527

ecm_generate_headers(MessageViewer_Camelcaseviewerplugin_HEADERS
Laurent Montel's avatar
Laurent Montel committed
528
529
530
531
532
533
534
535
536
    HEADER_NAMES
    ViewerPluginManager
    ViewerPlugin
    ViewerPluginInterface
    ViewerPluginToolManager
    REQUIRED_HEADERS MessageViewer_viewerplugin_HEADERS
    PREFIX MessageViewer
    RELATIVE viewerplugins
    )
537

Volker Krause's avatar
Volker Krause committed
538
539
540
541
ecm_generate_headers(MessageViewer_Camelcaserenderer_HEADERS
    HEADER_NAMES
    HtmlBlock
    MessagePartRendererBase
542
    MessagePartRendererManager
Volker Krause's avatar
Volker Krause committed
543
544
545
546
547
548
    MessagePartRenderPlugin
    REQUIRED_HEADERS MessageViewer_renderer_HEADERS
    PREFIX MessageViewer
    RELATIVE messagepartthemes/default
    )

549
550
ecm_generate_pri_file(BASE_NAME MessageViewer
    LIB_NAME KF5MessageViewer
Laurent Montel's avatar
Laurent Montel committed
551
    DEPS "PimCommon MessageCore AkonadiCore AkonadiMime KContacts Libkleo MimeTreeParser" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer
Laurent Montel's avatar
Laurent Montel committed
552
    )
553
if (${Qca-qt5_FOUND})
Laurent Montel's avatar
Laurent Montel committed
554
555
556
557
558
559
560
561
562
563
564
565
    install(FILES
        ${MessageViewer_Cameldkimverify_HEADERS}
        DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer
        COMPONENT Devel
        )

    install(FILES
        ${MessageViewer_dkimverify_HEADERS}
        DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer
        COMPONENT Devel
        )
endif()
566

Laurent Montel's avatar
Laurent Montel committed
567

568
install(FILES
Laurent Montel's avatar
Laurent Montel committed
569
    ${MessageViewer_CamelcaseConfigurePlugins_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
570
    ${MessageViewer_Camelcasewebengine_HEADERS}
571
572
573
574
575
    ${MessageViewer_Camelcaseheader_HEADERS}
    ${MessageViewer_Camelcaseviewerplugin_HEADERS}
    ${MessageViewer_Camelcasesettings_HEADERS}
    ${MessageViewer_Camelcaseutils_HEADERS}
    ${MessageViewer_Camelcaseinterfaces_HEADERS}
576
    ${MessageViewer_Camelcasehtmlwriter_HEADERS}
577
    ${MessageViewer_Camelcaseviewer_HEADERS}
578
    ${MessageViewer_Camelremotecontent_HEADERS}
579
580
    ${MessageViewer_Camelcasewidgets_HEADERS}
    ${MessageViewer_Camelcaseantispam_HEADERS}
581
    ${MessageViewer_Camelfindbar_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
582
    ${MessageViewer_Camelcasescam_HEADERS}
Volker Krause's avatar
Volker Krause committed
583
    ${MessageViewer_Camelcaserenderer_HEADERS}
584
585
    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer
    COMPONENT Devel
Laurent Montel's avatar
Laurent Montel committed
586
    )
587
588

install(FILES
Laurent Montel's avatar
Laurent Montel committed
589
    ${MessageViewer_ConfigurePlugins_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
590
    ${MessageViewer_webengine_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
591
    ${MessageViewer_scam_HEADERS}
592
593
594
595
596
    ${MessageViewer_viewerplugin_HEADERS}
    ${MessageViewer_settings_HEADERS}
    ${MessageViewer_header_HEADERS}
    ${MessageViewer_utils_HEADERS}
    ${MessageViewer_interfaces_HEADERS}
597
    ${MessageViewer_htmlwriter_HEADERS}
598
599
600
601
    ${MessageViewer_HEADERS}
    ${MessageViewer_viewer_HEADERS}
    ${MessageViewer_widgets_HEADERS}
    ${MessageViewer_antispam_HEADERS}
602
    ${MessageViewer_findbar_HEADERS}
Volker Krause's avatar
Volker Krause committed
603
    ${MessageViewer_renderer_HEADERS}
604
    ${MessageViewer_remotecontent_HEADERS}
605
606
607
    ${CMAKE_CURRENT_BINARY_DIR}/messageviewer_export.h
    ${CMAKE_CURRENT_BINARY_DIR}/globalsettings_messageviewer.h
    ${CMAKE_CURRENT_BINARY_DIR}/messageviewer_debug.h
608
    ${CMAKE_CURRENT_BINARY_DIR}/config-messageviewer.h
609
610
    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer
    COMPONENT Devel
Laurent Montel's avatar
Laurent Montel committed
611
    )
612
613
614
615
616
617

install(FILES
    ${PRI_FILENAME}
    DESTINATION ${ECM_MKSPECS_INSTALL_DIR})


618
install(FILES header/data/messageviewer_header_themes.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR} )
619
620
621

install(FILES notify/messageviewer.notifyrc DESTINATION ${KDE_INSTALL_KNOTIFY5RCDIR} )
install(FILES scamdetection/data/longurlServices.json DESTINATION ${KDE_INSTALL_DATADIR}/messageviewer )