From 34880197169f623b899b6b689c69ef847df4a7c6 Mon Sep 17 00:00:00 2001 From: Vern Paxson Date: Wed, 1 May 2024 17:09:30 -0700 Subject: [PATCH] configuration hooks to enable gen-zam to take multiple arguments --- Gen-ZAM.cmake | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Gen-ZAM.cmake b/Gen-ZAM.cmake index d1e29ef..4186aaa 100644 --- a/Gen-ZAM.cmake +++ b/Gen-ZAM.cmake @@ -3,10 +3,10 @@ # GEN_ZAM_OUTPUT_H. # # The macro also creates a target that can be used to define depencencies on the -# generated files. The name of the target includes the input template filename +# generated files. The name of the target includes the input template directory # to make it unique, and is added automatically to bro_ALL_GENERATED_OUTPUTS. -macro (gen_zam_target gzInput) - get_filename_component(gzInputBasename "${gzInput}" NAME) +macro (gen_zam_target gzInputDir) + get_filename_component(gzInputBasename "${gzInputDir}" NAME) set(target "gen-zam-${gzInputBasename}") string(REGEX REPLACE "/" "-" target "${target}") @@ -41,8 +41,8 @@ macro (gen_zam_target gzInput) add_custom_command( OUTPUT ${GEN_ZAM_OUTPUT_H} - COMMAND ${GEN_ZAM_EXE} ARGS ${gzInput} - DEPENDS ${gzInput} ${GEN_ZAM_EXE} + COMMAND ${GEN_ZAM_EXE} ARGS ${GEN_ZAM_SRC} + DEPENDS ${GEN_ZAM_SRC} ${GEN_ZAM_EXE} COMMENT "[gen-zam] Generating ZAM operations" WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})