Skip to content

Commit 553c4c7

Browse files
committed
[cmake] Change template to respect repo name
1 parent 3aedcf8 commit 553c4c7

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

tools/build_script_generator/cmake/resources/CMakeLists.txt.in

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ set_source_files_properties(
2222
%% endif
2323

2424
%% if sources | length
25-
add_library(modm OBJECT
25+
add_library({{ repo }} OBJECT
2626
%% for file, flags in sources | sort
2727
{{ file | relocate | modm.posixify }}
2828
%% endfor
@@ -37,25 +37,25 @@ add_library(modm OBJECT
3737

3838
%% endif
3939

40-
add_library(modm_warnings INTERFACE)
41-
add_library(modm_options INTERFACE)
42-
add_library(modm_arch_options INTERFACE)
40+
add_library({{ repo }}_warnings INTERFACE)
41+
add_library({{ repo }}_options INTERFACE)
42+
add_library({{ repo }}_arch_options INTERFACE)
4343

44-
modm_target_config_create(modm modm_arch_options modm_options modm_warnings)
44+
modm_target_config_create({{ repo }} {{ repo }}_arch_options {{ repo }}_options {{ repo }}_warnings)
4545

4646
%% if include_paths | length
47-
target_include_directories(modm SYSTEM PUBLIC
47+
target_include_directories({{ repo }} SYSTEM PUBLIC
4848
%% for path in include_paths | sort
4949
{{ path | relocate | modm.posixify }}
5050
%% endfor
5151
)
5252

5353
%% endif
5454

55-
target_link_libraries(modm
55+
target_link_libraries({{ repo }}
5656
PUBLIC
57-
modm_arch_options
57+
{{ repo }}_arch_options
5858
PRIVATE
5959
project_options
60-
modm_options
61-
modm_warnings)
60+
{{ repo }}_options
61+
{{ repo }}_warnings)

0 commit comments

Comments
 (0)