Fix windows build
ClosedPublic

Authored by kfunk on Jan 25 2019, 12:44 PM.

Details

Summary

We need to export symbols when building the library, but import them
when using the library.

Fixes issues like:

.../moc_nicknamewidget.cpp(65): error C2491: 'ContactEditor::NicknameWidget::staticMetaObject': definition of dllimport static data member not allowed

Diff Detail

Repository
R459 Akonadi Contacts
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
kfunk created this revision.Jan 25 2019, 12:44 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptJan 25 2019, 12:44 PM
Restricted Application added a subscriber: kde-pim. · View Herald Transcript
kfunk requested review of this revision.Jan 25 2019, 12:44 PM
kfunk added a reviewer: mlaurent.

Does this work when building both with and without tests?

kfunk added a comment.Apr 1 2019, 8:10 AM

This works, yes, I don't see how that change could break it.

dvratil accepted this revision.EditedApr 1 2019, 8:16 AM

Thanks, the BUILD_TESTING variable affects the export macro used for some classes, so I wasn't sure.

This revision is now accepted and ready to land.Apr 1 2019, 8:16 AM
This revision was automatically updated to reflect the committed changes.