Re: [CMake] add_custom_command and re-running command when target in DEPENDS was updated

2016-08-29 Thread Maciej Mrozowski
On poniedziaƂek, 29 sierpnia 2016 23:31:59 CEST you wrote: > add_custom_command documentation says: > > > The DEPENDS option specifies files on which the command depends. If any > dependency is an OUTPUT of another custom command in the same directory > (CMakeLists.txt file) CMake automatically

[CMake] add_custom_command and re-running command when target in DEPENDS was updated

2016-08-29 Thread Maciej Mrozowski
Hello, I have a project that goes something along the lines of: (...) add_jar(generator src/javafile.java) (...) get_target_property(GENERATOR_PATH generator JAR_FILE) (...) add_custom_command ${CMAKE_CURRENT_BINARY_DIR}/generated.cpp COMMAND ${Java_JAVA_EXECUTABLE -jar ${GENERATOR_PATH} --ou