Index: lib/MsgUtils/cmake/MsgUtils.cmake =================================================================== diff -u -r8165b9eb5d23253e5d38b6ffde9d1a21cb1cbc52 -r9d547159d805f3a0b0f2f6a11f4e34feb5117b65 --- lib/MsgUtils/cmake/MsgUtils.cmake (.../MsgUtils.cmake) (revision 8165b9eb5d23253e5d38b6ffde9d1a21cb1cbc52) +++ lib/MsgUtils/cmake/MsgUtils.cmake (.../MsgUtils.cmake) (revision 9d547159d805f3a0b0f2f6a11f4e34feb5117b65) @@ -57,7 +57,7 @@ ) endfunction() -# \brief This function custom command to generate/update a message handling INI. +# \brief This function adds a custom command to generate/update a message handling INI. # \param[in] _input_confs list of message conf files to use to generate the INI # \param[in] _output_ini path to the INI file to create or update # \param[in] _target_name name of the custom target to add @@ -75,14 +75,24 @@ endforeach() list(JOIN _files ", " _file_list) - add_custom_target(${_target_name} + add_custom_command( + DEPENDS + ${MSGUTILS_SCRIPTS_DIR}/msgutils/MsgData.py + ${MSGUTILS_SCRIPTS_DIR}/msgutils/MsgIni.py + ${MSGUTILS_SCRIPTS_DIR}/GenerateMsgIni.py + ${MSGUTILS_SCRIPTS_DIR}/msgutils/templates/MsgIni.jinja + ${${_input_confs}} + OUTPUT + ${_output_ini} COMMAND ${PROJECT_PYTHON} ${MSGUTILS_SCRIPTS_DIR}/GenerateMsgIni.py ${${_input_confs}} ${_output_ini} - COMMENT "Generating/updating LeahiRt message INI ${_output_ini} from input ${_file_list}" + COMMENT "Generating/updating message INI ${_output_ini} from input ${_file_list}" VERBATIM ) + + add_custom_target(${_target_name} DEPENDS ${_output_ini}) endfunction() # \brief This function adds a custom command to generate a Protobuf file from inputted message conf files