KCONFIG_ADD_KCFG_FILES macro: ensure a change of File= in kcfg is picked up
ClosedPublic

Authored by kossebau on Mar 6 2019, 2:44 PM.

Details

Summary

The build configuration depends on the value of the "File=" entry in the
kcfg file, as this file name is used in the build instructions.
So if the name is changed, cmake would need to be rerun.
Adding the kcfgc file to CMAKE_CONFIGURE_DEPENDS makes cmake know about that
dependency.
While this will also result in a reconfiguarion if non-File entries are
edited, this should not happen too often, so the extra costs outweighs the
unexpected and confusing behaviour due to outdated build instructions
in case the File= entry is changed.

Test Plan

Before this change renaming a kcfg file before did not trigger a rerun of cmake,
resulting in outdated builds instructions and unexpected behaviour.
With this change cmake is rerun once the kcgc file is edited, so build
instructions are always up-to-date.

Diff Detail

Repository
R237 KConfig
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
kossebau created this revision.Mar 6 2019, 2:44 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptMar 6 2019, 2:44 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
kossebau requested review of this revision.Mar 6 2019, 2:44 PM
apol accepted this revision.Mar 6 2019, 3:06 PM
apol added a subscriber: apol.

Cool!

This revision is now accepted and ready to land.Mar 6 2019, 3:06 PM

@apol Thanks for review :)

This revision was automatically updated to reflect the committed changes.