Brandon J. Van Every wrote:
DEPLIST(chicken build chicken-ffi-macros chicken-more-macros tweaks)
SIMPLE_SCM_TO_C(chicken)

You could take advantage of variable macro arguments. The token "${ARGN}" will be replaced by arguments beyond those explicitly named. Try something like this (untested):

MACRO(SIMPLE_SCM_TO_C root)
 SET(deplist ${ARGN})
 ADD_SUFFIX(deplist .scm)
 ADD_CUSTOM_COMMAND(
   OUTPUT ${Chicken_BINARY_DIR}/${root}.c
   MAIN_DEPENDENCY ${root}.scm
   DEPENDS ${deplist}
COMMAND ${VALID_CHICKEN} ${Chicken_SOURCE_DIR}/${root}.scm -output-file ${Chicken_BINARY_DIR}/${root}.c ${CHICKEN_FLAGS}
 )
ENDMACRO(SIMPLE_SCM_TO_C)

SIMPLE_SCM_TO_C(chicken build chicken-ffi-macros chicken-more-macros tweaks)

-Brad
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to