2021-06-12 09:59:31 +00:00
|
|
|
function(canonical_string in_string out_string)
|
|
|
|
string(TOUPPER ${in_string} _arg_uppercase)
|
2020-03-29 05:44:48 +00:00
|
|
|
string(REGEX REPLACE "[ -]" "_" _arg_fixed ${_arg_uppercase})
|
2021-06-12 09:59:31 +00:00
|
|
|
set(${out_string} ${_arg_fixed} PARENT_SCOPE)
|
2020-03-29 05:44:48 +00:00
|
|
|
endfunction()
|
2021-05-18 05:59:52 +00:00
|
|
|
|
|
|
|
# Добавление общего префикса ко всем переменным в списке
|
|
|
|
function(list_transform_prepend var prefix)
|
2021-05-30 17:32:08 +00:00
|
|
|
set(temp "")
|
2021-06-12 09:59:31 +00:00
|
|
|
foreach(filename ${${var}})
|
|
|
|
list(APPEND temp "${prefix}${filename}")
|
2021-05-30 17:32:08 +00:00
|
|
|
endforeach()
|
|
|
|
set(${var} "${temp}" PARENT_SCOPE)
|
2021-05-18 05:59:52 +00:00
|
|
|
endfunction()
|