Skip to content

Commit 372240c

Browse files
raphaelcoefficPhil Mitchell
authored and
Phil Mitchell
committed
fix(cmake): define python code dependencies in AddHWGen macro
1 parent f1fde63 commit 372240c

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

cmake/Macros.cmake

+5-3
Original file line numberDiff line numberDiff line change
@@ -120,15 +120,17 @@ function(AddHWGenTarget input template output)
120120
# Inputs
121121
set(INPUT_JSON ${CMAKE_CURRENT_BINARY_DIR}/${input})
122122
set(TEMPLATE ${RADIO_DIRECTORY}/util/hw_defs/${template}.jinja)
123-
set(LEGACY_JSON ${RADIO_DIRECTORY}/util/hw_defs/legacy_names.py)
123+
set(GEN_PY_DEPS
124+
${RADIO_DIRECTORY}/util/hw_defs/generator.py
125+
${RADIO_DIRECTORY}/util/hw_defs/legacy_names.py
126+
)
124127

125128
# Command
126129
set(GEN_JSON ${GEN_JSON} -t ${TEMPLATE} -T ${FLAVOUR} ${INPUT_JSON})
127130

128131
add_custom_command(OUTPUT ${output}
129132
COMMAND ${GEN_JSON} > ${output}
130-
DEPENDS ${INPUT_JSON} ${LEGACY_JSON} ${TEMPLATE} ${RADIO_DIRECTORY}/src/hal/key_driver.h
131-
)
133+
DEPENDS ${INPUT_JSON} ${TEMPLATE} ${GEN_PY_DEPS})
132134
endfunction()
133135

134136
macro(AddHeadersSources)

0 commit comments

Comments
 (0)