CMake: provide a convenient external name for modules
The target name for a module is annoyingly long and hard-to-read. Set a parent-scope variable with a nicer name to the full target name.
This commit is contained in:
parent
cefb437324
commit
87be4c4a81
@ -67,7 +67,9 @@
|
|||||||
# already handles skip-reasons and collects them for reporting.
|
# already handles skip-reasons and collects them for reporting.
|
||||||
#
|
#
|
||||||
# The target defined this way is called "calamares_<TYPE>_<module-name>",
|
# The target defined this way is called "calamares_<TYPE>_<module-name>",
|
||||||
# e.g. "calamares_viewmodule_packagechooserq".
|
# e.g. "calamares_viewmodule_packagechooserq". The function sets a variable
|
||||||
|
# in its **calling** scope, `<module-name>_TARGET` with the full name
|
||||||
|
# of the target.
|
||||||
|
|
||||||
include( CMakeParseArguments )
|
include( CMakeParseArguments )
|
||||||
|
|
||||||
@ -226,4 +228,6 @@ function( calamares_add_plugin )
|
|||||||
message( "" )
|
message( "" )
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
set(${NAME}_TARGET ${target} PARENT_SCOPE)
|
||||||
endfunction()
|
endfunction()
|
||||||
|
Loading…
Reference in New Issue
Block a user