SUMMARY Please make it clear in ECMAddAppIcon documentation that the resulting sources must be added in the executable target directly. ecm_add_app_icon doesn't work as expected at least on Windows if you add the sources in an intermediate STATIC or OBJECT library. I made this mistake in KTimeTracker, fixed it like this: http://commits.kde.org/ktimetracker/e712367404548bf200fb86e7ca2850f0c0785a4a Kate is still broken: https://bugs.kde.org/show_bug.cgi?id=415260 STEPS TO REPRODUCE 1. 2. 3. OBSERVED RESULT EXPECTED RESULT SOFTWARE/OS VERSIONS Windows: 10 macOS: Linux/KDE Plasma: (available in About System) KDE Plasma Version: KDE Frameworks Version: Qt Version: ADDITIONAL INFORMATION
No need, the doc already says it must be used with the 'executable target': « # will be added to the executable target whose sources are specified by # ``<sources_var>`` »
(In reply to Christophe Giboudeaux from comment #1) > No need, the doc already says it must be used with the 'executable target': > > « # will be added to the executable target whose sources are specified by > # ``<sources_var>`` » This phrase does not imply that the sources must be added into add_executable() directly. In a case when you have part of application code (defined in variable MYLIB_SOURCES) compiled into library "mylib", the condition "whose sources are specified by MYLIB_SOURCES" still holds true. However the icon will not be added into the executable target. Our discussion also proves that this existing sentence is hard to read and understand correctly. Also, I think saying the same thing twice in different words is not bad.