Bug 418905 - Unable to build as static library because of interaction w/ GenerateExportHeader
Summary: Unable to build as static library because of interaction w/ GenerateExportHeader
Status: RESOLVED FIXED
Alias: None
Product: frameworks-kirigami
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: Master
Platform: Other All
: NOR normal
Target Milestone: Not decided
Assignee: Marco Martin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-03-16 02:12 UTC by Charles Barto
Modified: 2020-08-22 14:19 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Charles Barto 2020-03-16 02:12:18 UTC
SUMMARY
It's not possible to build as a static library, because kirigami sets the STATIC_LIBRARY variable to "1" when building as a static library, then it tries to use GenerateExportHeader, which has code like the following:

get_property(type TARGET ${TARGET_LIBRARY} PROPERTY TYPE)
if(NOT ${TYPE} STREQUAL "STATIC_LIBRARY" ...)

this if statement fails, because the "${type}" parameter is expanded to STATIC_LIBRARY, which is then expanded by the if statement to "1"!

STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Nicolas Fella 2020-08-22 14:19:49 UTC
I believe this has been fixed. I can build a static build fine.