CMakeLists.txt 16.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
30
31
32
33
34
35
36
37

find_package(Qca-qt5 2.1.0)
set_package_properties(Qca-qt5 PROPERTIES DESCRIPTION "Qt Cryptographic Architecture"
                   URL "https:/download.kde.org/stable/qca-qt5" TYPE OPTIONAL
                   PURPOSE "Needed for kdim support.")

if (${Qca-qt5_FOUND})
    set(USE_DKIM_CHECKER 1)
endif()

38
39
40
41
42
43
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)
44
    add_subdirectory(header/autotests)
Laurent Montel's avatar
Laurent Montel committed
45
46
47
    add_subdirectory(scamdetection/autotests)
    add_subdirectory(scamdetection/tests)
    add_subdirectory(viewerplugins/tests/)
48
    add_subdirectory(htmlwriter/autotests)
Laurent Montel's avatar
Laurent Montel committed
49
    add_subdirectory(viewer/webengine/tests)
50
    add_subdirectory(messagepartthemes/default/autotests)
Laurent Montel's avatar
Laurent Montel committed
51
    add_subdirectory(widgets/autotests/)
52
    add_subdirectory(utils/autotests)
53
54
55
56
endif()
add_subdirectory(pics)
add_subdirectory(kconf_update)
add_subdirectory(about)
57
add_subdirectory(messageviewerheaderplugins)
58

59
if (${Qca-qt5_FOUND})
60
61
    if (BUILD_TESTING)
        add_subdirectory(dkim-verify/autotests)
62
	add_subdirectory(dkim-verify/tests)
63
    endif()
Laurent Montel's avatar
Laurent Montel committed
64
65
66
67
68
    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
69
        dkim-verify/dkimdownloadkeyjob.cpp
70
        dkim-verify/dkimchecksignaturejob.cpp
Laurent Montel's avatar
Laurent Montel committed
71
72
        dkim-verify/dkimcheckauthenticationstatusjob.cpp
        dkim-verify/dkimauthenticationstatusinfo.cpp
Laurent Montel's avatar
Laurent Montel committed
73
        dkim-verify/dkimutil.cpp
74
        dkim-verify/dkimkeyrecord.cpp
Laurent Montel's avatar
Laurent Montel committed
75
        dkim-verify/dkimmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
76
        dkim-verify/dkimresultattribute.cpp
Laurent Montel's avatar
Laurent Montel committed
77
        dkim-verify/dkimwidgetinfo.cpp
Laurent Montel's avatar
Laurent Montel committed
78
        dkim-verify/dkimstoreresultjob.cpp
79
        dkim-verify/dkimheaderparser.cpp
80
        dkim-verify/dkimcheckpolicy.cpp
81
        dkim-verify/dmarcrecordjob.cpp
Laurent Montel's avatar
Laurent Montel committed
82
        )
83
84
endif()

85
if(DEBUG_SIGNATURE)
Laurent Montel's avatar
Laurent Montel committed
86
    add_definitions(-DDEBUG_SIGNATURE)
87
88
endif()

Laurent Montel's avatar
Laurent Montel committed
89
90
91
92
93
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
94
    viewer/webengine/blockexternalresourcesurlinterceptor/blockexternalresourcesurlinterceptor.cpp
95
    viewer/webengine/blockmailtrackingurlinterceptor/blockmailtrackingurlinterceptor.cpp
Laurent Montel's avatar
Laurent Montel committed
96
    )
Laurent Montel's avatar
Laurent Montel committed
97

98
set(libmessageviewer_viewer_SRCS
99
    viewer/attachmentstrategy.cpp
Laurent Montel's avatar
Laurent Montel committed
100
    viewer/csshelper.cpp
101
    viewer/csshelperbase.cpp
Laurent Montel's avatar
Laurent Montel committed
102
103
104
105
106
107
108
109
    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
110
    viewer/mimeparttree/mimetreemodel.cpp
Laurent Montel's avatar
Laurent Montel committed
111
    )
112
113

set(libmessageviewer_widgets_SRCS
Laurent Montel's avatar
Laurent Montel committed
114
115
116
117
118
119
120
121
    widgets/attachmentdialog.cpp
    widgets/configurewidget.cpp
    widgets/printingsettings.cpp
    widgets/htmlstatusbar.cpp
    widgets/vcardviewer.cpp
    widgets/invitationsettings.cpp
    widgets/openattachmentfolderwidget.cpp
    widgets/mailsourceviewtextbrowserwidget.cpp
122
    widgets/submittedformwarningwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
123
    widgets/mailtrackingwarningwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
124
    widgets/mailtrackingdetailsdialog.cpp
125
    widgets/shownextmessagewidget.cpp
Laurent Montel's avatar
Laurent Montel committed
126
    )
127

Laurent Montel's avatar
Laurent Montel committed
128
129
130
set(libmessageviewer_widgets_webengine_SRCS
    widgets/mailsourcewebengineviewer.cpp
    )
131

132
set(libmessageviewer_header_SRCS
Laurent Montel's avatar
Laurent Montel committed
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
    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
    )
148
149

set(libmessageviewer_scamdetection_SRCS
Laurent Montel's avatar
Laurent Montel committed
150
151
152
153
    scamdetection/scamdetectionwarningwidget.cpp
    scamdetection/scamdetectiondetailsdialog.cpp
    scamdetection/scamattribute.cpp
    scamdetection/scamcheckshorturl.cpp
154
    scamdetection/scamexpandurljob.cpp
Laurent Montel's avatar
Laurent Montel committed
155
    scamdetection/scamcheckshorturlmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
156
    )
157

Laurent Montel's avatar
Laurent Montel committed
158
159
160
set(libmessageviewer_scamdetection_webengine_SRCS
    scamdetection/scamdetectionwebengine.cpp
    )
161

162
set(libmessageviewer_findbar_SRCS
Laurent Montel's avatar
Laurent Montel committed
163
164
    findbar/findbarsourceview.cpp
    )
165
166

set(libmessageviewer_utils_SRCS
167
    utils/iconnamecache.cpp
Laurent Montel's avatar
Laurent Montel committed
168
169
    utils/markmessagereadhandler.cpp
    utils/messageviewerutil.cpp
Sandro Knauß's avatar
Sandro Knauß committed
170
    utils/mimetype.cpp
Laurent Montel's avatar
Laurent Montel committed
171
    )
172

Laurent Montel's avatar
Laurent Montel committed
173
174
175
176
set(libmessageviewer_htmlwriter_webengine_SRCS
    htmlwriter/webengineparthtmlwriter.cpp
    htmlwriter/webengineembedpart.cpp
    )
177

178
179
180
181
182
183
set(libmessageviewer_htmlwriter_SRCS
    ${libmessageviewer_htmlwriter_webengine_SRCS}
    htmlwriter/bufferedhtmlwriter.cpp
    htmlwriter/filehtmlwriter.cpp
    )

184
set(libmessageviewer_antispam_SRCS
Laurent Montel's avatar
Laurent Montel committed
185
186
187
    antispam/spamheaderanalyzer.cpp
    antispam/antispamconfig.cpp
    )
188
189

set(libmessageviewer_job_SRCS
Laurent Montel's avatar
Laurent Montel committed
190
191
    job/modifymessagedisplayformatjob.cpp
    )
192
193

set(libmessageviewer_viewerplugins_SRCS
Laurent Montel's avatar
Laurent Montel committed
194
195
196
197
198
    viewerplugins/viewerpluginmanager.cpp
    viewerplugins/viewerplugin.cpp
    viewerplugins/viewerplugininterface.cpp
    viewerplugins/viewerplugintoolmanager.cpp
    )
199

Laurent Montel's avatar
Laurent Montel committed
200
201
set(libmessageviewer_configureplugins_SRCS
    messageviewerconfigureplugins/messageviewerconfiguresettingsplugin.cpp
Laurent Montel's avatar
Laurent Montel committed
202
    messageviewerconfigureplugins/messageviewerconfiguresettingspluginmanager.cpp
Laurent Montel's avatar
Laurent Montel committed
203
    messageviewerconfigureplugins/messageviewerconfiguresettingspluginwidget.cpp
Laurent Montel's avatar
Laurent Montel committed
204
205
    )

206
207
208
209
set(libmessageviewer_messagepartthemes_default_SRCS
    messagepartthemes/default/converthtmltoplaintext.cpp
    messagepartthemes/default/defaultrenderer.cpp
    messagepartthemes/default/htmlblock.cpp
210
    messagepartthemes/default/messagepartrenderermanager.cpp
211
    messagepartthemes/default/plugins/attachmentmessagepartrenderer.cpp
212
    messagepartthemes/default/plugins/messagepartrenderer.cpp
Sandro Knauß's avatar
Sandro Knauß committed
213
    messagepartthemes/default/plugins/textmessagepartrenderer.cpp
Sandro Knauß's avatar
Sandro Knauß committed
214
    messagepartthemes/default/plugins/quotehtml.cpp
215
    messagepartthemes/default/messagepartrenderbase.cpp
Volker Krause's avatar
Volker Krause committed
216
    messagepartthemes/default/messagepartrenderplugin.cpp
217
    messagepartthemes/default/messagepartrendererfactory.cpp
218
219
    )

220
221
222
223
set(libmessageviewer_interfaces_SRCS
    interfaces/htmlwriter.cpp
    )

224
set(libmessageviewer_SRCS
Laurent Montel's avatar
Laurent Montel committed
225
    ${dkim_verify_SRCS}
Laurent Montel's avatar
Laurent Montel committed
226
    ${libmessageviewer_messagepartthemes_default_SRCS}
227
    ${libmessageviewer_htmlwriter_SRCS}
228
    ${libmessageviewer_messagepartthemes_SRCS}
229
    ${libmessageviewer_scamdetection_webengine_SRCS}
230
    ${libmessageviewer_widgets_webengine_SRCS}
Laurent Montel's avatar
Laurent Montel committed
231
232
233
234
235
236
237
238
239
240
241
    ${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}
242
    ${libmessageviewer_interfaces_SRCS}
Laurent Montel's avatar
Laurent Montel committed
243
    ${libmessageviewer_configureplugins_SRCS}
Laurent Montel's avatar
Laurent Montel committed
244
    )
245

246
247
qt5_add_resources(libmessageviewer_SRCS messagepartthemes.qrc)

Laurent Montel's avatar
Laurent Montel committed
248
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
249
ecm_qt_declare_logging_category(libmessageviewer_SRCS HEADER messageviewer_dkimcheckerdebug.h IDENTIFIER MESSAGEVIEWER_DKIMCHECKER_LOG CATEGORY_NAME org.kde.pim.messageviewer_dkimchecker)
250
kconfig_add_kcfg_files(libmessageviewer_SRCS
Laurent Montel's avatar
Laurent Montel committed
251
252
    settings/globalsettings_messageviewer.kcfgc
    )
253
254

ki18n_wrap_ui(libmessageviewer_SRCS
Laurent Montel's avatar
Laurent Montel committed
255
256
257
258
    ui/settings.ui
    ui/invitationsettings.ui
    ui/printingsettings.ui
    )
259
260
261
262
263
264


add_library(KF5MessageViewer ${libmessageviewer_SRCS})
generate_export_header(KF5MessageViewer BASE_NAME messageviewer)
add_library(KF5::MessageViewer ALIAS KF5MessageViewer)

265
target_include_directories(KF5MessageViewer INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer/;${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer>;${Inotify_INCLUDE_DIRS}")
266

267
if (${Qca-qt5_FOUND})
268
269
270
    set(OPTIONAL_PRIVATE qca-qt5)
endif()

271
target_link_libraries(KF5MessageViewer
Laurent Montel's avatar
Laurent Montel committed
272
273
274
275
276
277
278
    PUBLIC
    KF5::MessageCore
    KF5::PimCommon
    KF5::AkonadiCore
    KF5::AkonadiMime
    KF5::Contacts
    KF5::Libkleo
279
    KF5::MimeTreeParser
Laurent Montel's avatar
Laurent Montel committed
280
    PRIVATE
281
    KF5::SyntaxHighlighting
Laurent Montel's avatar
Laurent Montel committed
282
    KF5::ItemViews
Sandro Knauß's avatar
Sandro Knauß committed
283
    Qt5::Network
Laurent Montel's avatar
Laurent Montel committed
284
    KF5::WebEngineViewer
Laurent Montel's avatar
Laurent Montel committed
285
    KF5::LibkdepimAkonadi
Laurent Montel's avatar
Laurent Montel committed
286
287
    KF5::GrantleeTheme
    KF5::KaddressbookGrantlee
Laurent Montel's avatar
Laurent Montel committed
288
    KF5::MailTransportAkonadi
Laurent Montel's avatar
Laurent Montel committed
289
290
291
292
293
    KF5::Mime
    KF5::Mbox
    KF5::PimTextEdit
    KF5::Gravatar
    KF5::IconThemes
294
295
296
297
    KF5::I18n
    KF5::KIOFileWidgets
    KF5::KIOWidgets
    KF5::XmlGui
298
299
    Grantlee5::TextDocument
    Grantlee5::Templates
300
    Qt5::PrintSupport
301
    QGpgme
302
    ${Inotify_LIBRARIES}
303
    ${OPTIONAL_PRIVATE}
Laurent Montel's avatar
Laurent Montel committed
304
    )
305

306
307
set(OPTIONAL_PRIVATE qca-qt5)

308
309
310
311
set_target_properties(KF5MessageViewer PROPERTIES
    VERSION ${MESSAGEVIEWER_VERSION_STRING}
    SOVERSION ${MESSAGEVIEWER_SOVERSION}
    EXPORT_NAME MessageViewer
Laurent Montel's avatar
Laurent Montel committed
312
    )
313
314
315
316

install(TARGETS
    KF5MessageViewer
    EXPORT KF5MessageViewerTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS} ${LIBRARY_NAMELINK}
Laurent Montel's avatar
Laurent Montel committed
317
    )
318

Laurent Montel's avatar
Laurent Montel committed
319
320
321
322
323
324
325
326
327
ecm_generate_headers(MessageViewer_Camelblockmailtrackingurlinterceptor_HEADERS
    HEADER_NAMES
    BlockMailTrackingUrlInterceptor

    REQUIRED_HEADERS MessageViewer_blockmailtrackingurlinterceptor_HEADERS
    PREFIX MessageViewer
    RELATIVE viewer/webengine/blockmailtrackingurlinterceptor
    )

Laurent Montel's avatar
Laurent Montel committed
328
329
330
331
ecm_generate_headers(MessageViewer_Camelcasewebengine_HEADERS
    HEADER_NAMES
    MailWebEnginePage
    MailWebEngineView
332

Laurent Montel's avatar
Laurent Montel committed
333
334
335
336
    REQUIRED_HEADERS MessageViewer_webengine_HEADERS
    PREFIX MessageViewer
    RELATIVE viewer/webengine
    )
Laurent Montel's avatar
Laurent Montel committed
337

Laurent Montel's avatar
Laurent Montel committed
338
339
340
ecm_generate_headers(MessageViewer_Camelcasescam_HEADERS
    HEADER_NAMES
    ScamExpandUrlJob
Laurent Montel's avatar
Laurent Montel committed
341
    ScamCheckShortUrlManager
Laurent Montel's avatar
Laurent Montel committed
342
    ScamCheckShortUrl
Laurent Montel's avatar
Laurent Montel committed
343
344
345
346
    REQUIRED_HEADERS MessageViewer_scam_HEADERS
    PREFIX MessageViewer
    RELATIVE scamdetection
    )
Laurent Montel's avatar
Laurent Montel committed
347

348
if (${Qca-qt5_FOUND})
Laurent Montel's avatar
Laurent Montel committed
349
350
351
352
353
    ecm_generate_headers(MessageViewer_Cameldkimverify_HEADERS
        HEADER_NAMES
        DKIMManagerKey
        DKIMCheckSignatureJob
        DKIMManager
Laurent Montel's avatar
Laurent Montel committed
354
355
        DKIMManagerKeyWidget
        DKIMManagerKeyDialog
Laurent Montel's avatar
Laurent Montel committed
356
        DKIMKeyRecord
Laurent Montel's avatar
Laurent Montel committed
357
        DKIMInfo
Laurent Montel's avatar
Laurent Montel committed
358
        DKIMWidgetInfo
Laurent Montel's avatar
Laurent Montel committed
359
360
361
362
        REQUIRED_HEADERS MessageViewer_dkimverify_HEADERS
        PREFIX MessageViewer
        RELATIVE dkim-verify
        )
Laurent Montel's avatar
Laurent Montel committed
363
endif()
Laurent Montel's avatar
Laurent Montel committed
364
365


366
ecm_generate_headers(MessageViewer_Camelcaseviewer_HEADERS
Laurent Montel's avatar
Laurent Montel committed
367
    HEADER_NAMES
368
    AttachmentStrategy
Laurent Montel's avatar
Laurent Montel committed
369
    Viewer
370
    CSSHelperBase
Laurent Montel's avatar
Laurent Montel committed
371
372
373
374
375
376
377
378
    CSSHelper
    ObjectTreeEmptySource
    EditorWatcher
    Stl_Util
    REQUIRED_HEADERS MessageViewer_viewer_HEADERS
    PREFIX MessageViewer
    RELATIVE viewer
    )
379
380

ecm_generate_headers(MessageViewer_Camelcasewidgets_HEADERS
Laurent Montel's avatar
Laurent Montel committed
381
382
383
384
385
386
387
388
    HEADER_NAMES
    InvitationSettings
    PrintingSettings
    ConfigureWidget
    REQUIRED_HEADERS MessageViewer_widgets_HEADERS
    PREFIX MessageViewer
    RELATIVE widgets
    )
389
390

ecm_generate_headers(MessageViewer_Camelcaseutils_HEADERS
Laurent Montel's avatar
Laurent Montel committed
391
    HEADER_NAMES
392
    IconNameCache
Laurent Montel's avatar
Laurent Montel committed
393
    MarkMessageReadHandler
Sandro Knauß's avatar
Sandro Knauß committed
394
395
    MessageViewerUtil
    MimeType
Laurent Montel's avatar
Laurent Montel committed
396
397
398
399
    REQUIRED_HEADERS MessageViewer_utils_HEADERS
    PREFIX MessageViewer
    RELATIVE utils
    )
400
401

ecm_generate_headers(MessageViewer_Camelcaseantispam_HEADERS
Laurent Montel's avatar
Laurent Montel committed
402
403
404
405
406
407
    HEADER_NAMES
    SpamHeaderAnalyzer
    REQUIRED_HEADERS MessageViewer_antispam_HEADERS
    PREFIX MessageViewer
    RELATIVE antispam
    )
408
409

ecm_generate_headers(MessageViewer_Camelcaseinterfaces_HEADERS
Laurent Montel's avatar
Laurent Montel committed
410
    HEADER_NAMES
411
    HtmlWriter
Laurent Montel's avatar
Laurent Montel committed
412
413
414
415
416
417
    BodyPartURLHandler
    URLHandler
    REQUIRED_HEADERS MessageViewer_interfaces_HEADERS
    PREFIX MessageViewer
    RELATIVE interfaces
    )
418

419
420
421
422
423
424
425
426
427
ecm_generate_headers(MessageViewer_Camelcasehtmlwriter_HEADERS
    HEADER_NAMES
    BufferedHtmlWriter
    FileHtmlWriter
    REQUIRED_HEADERS MessageViewer_htmlwriter_HEADERS
    PREFIX MessageViewer
    RELATIVE htmlwriter
    )

428
ecm_generate_headers(MessageViewer_Camelcasesettings_HEADERS
Laurent Montel's avatar
Laurent Montel committed
429
430
431
432
433
434
    HEADER_NAMES
    MessageViewerSettings
    REQUIRED_HEADERS MessageViewer_settings_HEADERS
    PREFIX MessageViewer
    RELATIVE settings
    )
435

Laurent Montel's avatar
Laurent Montel committed
436
437
438
439
ecm_generate_headers(MessageViewer_CamelcaseConfigurePlugins_HEADERS
    HEADER_NAMES
    MessageViewerConfigureSettingsPluginManager
    MessageViewerConfigureSettingsPlugin
Laurent Montel's avatar
Laurent Montel committed
440
    MessageViewerConfigureSettingsPluginWidget
Laurent Montel's avatar
Laurent Montel committed
441
442
443
444
445
    REQUIRED_HEADERS MessageViewer_ConfigurePlugins_HEADERS
    PREFIX MessageViewer
    RELATIVE messageviewerconfigureplugins
    )

446
447

ecm_generate_headers(MessageViewer_Camelcaseheader_HEADERS
Laurent Montel's avatar
Laurent Montel committed
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
    HEADER_NAMES
    HeaderStrategy
    GrantleeHeaderTestStyle
    GrantleeHeaderStyle
    HeaderStyle
    KXFace
    HeaderStyle_Util
    HeaderStylePlugin
    HeaderStyleInterface
    PlainHeaderStyle
    RichHeaderStrategy
    HeaderStylePluginManager
    HeaderStyleMenuManager
    REQUIRED_HEADERS MessageViewer_header_HEADERS
    PREFIX MessageViewer
    RELATIVE header
    )
465
466

ecm_generate_headers(MessageViewer_Camelcaseviewerplugin_HEADERS
Laurent Montel's avatar
Laurent Montel committed
467
468
469
470
471
472
473
474
475
    HEADER_NAMES
    ViewerPluginManager
    ViewerPlugin
    ViewerPluginInterface
    ViewerPluginToolManager
    REQUIRED_HEADERS MessageViewer_viewerplugin_HEADERS
    PREFIX MessageViewer
    RELATIVE viewerplugins
    )
476

Volker Krause's avatar
Volker Krause committed
477
478
479
480
ecm_generate_headers(MessageViewer_Camelcaserenderer_HEADERS
    HEADER_NAMES
    HtmlBlock
    MessagePartRendererBase
481
    MessagePartRendererManager
Volker Krause's avatar
Volker Krause committed
482
483
484
485
486
487
    MessagePartRenderPlugin
    REQUIRED_HEADERS MessageViewer_renderer_HEADERS
    PREFIX MessageViewer
    RELATIVE messagepartthemes/default
    )

488
489
ecm_generate_pri_file(BASE_NAME MessageViewer
    LIB_NAME KF5MessageViewer
490
    DEPS "PimCommon MessageCore AkonadiCore AkonadiMime Contacts Libkleo MimeTreeParser" FILENAME_VAR PRI_FILENAME INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer
Laurent Montel's avatar
Laurent Montel committed
491
    )
492
if (${Qca-qt5_FOUND})
Laurent Montel's avatar
Laurent Montel committed
493
494
495
496
497
498
499
500
501
502
503
504
    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()
505

Laurent Montel's avatar
Laurent Montel committed
506

507
install(FILES
Laurent Montel's avatar
Laurent Montel committed
508
    ${MessageViewer_CamelcaseConfigurePlugins_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
509
    ${MessageViewer_Camelcasewebengine_HEADERS}
510
511
512
513
514
    ${MessageViewer_Camelcaseheader_HEADERS}
    ${MessageViewer_Camelcaseviewerplugin_HEADERS}
    ${MessageViewer_Camelcasesettings_HEADERS}
    ${MessageViewer_Camelcaseutils_HEADERS}
    ${MessageViewer_Camelcaseinterfaces_HEADERS}
515
    ${MessageViewer_Camelcasehtmlwriter_HEADERS}
516
517
518
    ${MessageViewer_Camelcaseviewer_HEADERS}
    ${MessageViewer_Camelcasewidgets_HEADERS}
    ${MessageViewer_Camelcaseantispam_HEADERS}
519
    ${MessageViewer_Camelfindbar_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
520
    ${MessageViewer_Camelcasescam_HEADERS}
Volker Krause's avatar
Volker Krause committed
521
    ${MessageViewer_Camelcaserenderer_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
522
    ${MessageViewer_Camelblockmailtrackingurlinterceptor_HEADERS}
523
524
    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/MessageViewer
    COMPONENT Devel
Laurent Montel's avatar
Laurent Montel committed
525
    )
526
527

install(FILES
Laurent Montel's avatar
Laurent Montel committed
528
    ${MessageViewer_ConfigurePlugins_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
529
    ${MessageViewer_webengine_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
530
    ${MessageViewer_scam_HEADERS}
531
532
533
534
535
    ${MessageViewer_viewerplugin_HEADERS}
    ${MessageViewer_settings_HEADERS}
    ${MessageViewer_header_HEADERS}
    ${MessageViewer_utils_HEADERS}
    ${MessageViewer_interfaces_HEADERS}
536
    ${MessageViewer_htmlwriter_HEADERS}
537
538
539
540
    ${MessageViewer_HEADERS}
    ${MessageViewer_viewer_HEADERS}
    ${MessageViewer_widgets_HEADERS}
    ${MessageViewer_antispam_HEADERS}
541
    ${MessageViewer_findbar_HEADERS}
Volker Krause's avatar
Volker Krause committed
542
    ${MessageViewer_renderer_HEADERS}
Laurent Montel's avatar
Laurent Montel committed
543
    ${MessageViewer_blockmailtrackingurlinterceptor_HEADERS}
544
545
546
    ${CMAKE_CURRENT_BINARY_DIR}/messageviewer_export.h
    ${CMAKE_CURRENT_BINARY_DIR}/globalsettings_messageviewer.h
    ${CMAKE_CURRENT_BINARY_DIR}/messageviewer_debug.h
547
    ${CMAKE_CURRENT_BINARY_DIR}/config-messageviewer.h
548
549
    DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5}/messageviewer
    COMPONENT Devel
Laurent Montel's avatar
Laurent Montel committed
550
    )
551
552
553
554
555
556

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


557
install(FILES header/data/messageviewer_header_themes.knsrc DESTINATION ${KDE_INSTALL_KNSRCDIR} )
558
559
560

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