Contrary to the CMake FAQ, but consistent with what I have been reading elsewhere, it does not seem possible for me with CMake 2.8.6 to add a generated file as a dependency to a target, even in the same directory.
I have done something similar to the following: add_custom_command(OUTPUT foo.ext) add_executable(foo foo2.ext) add_custom_target(foo_custom DEPENDS foo.ext) set_source_files_properties(foo.ext PROPERTIES GENERATED TRUE) add_dependencies(foo foo_custom) The above will not cause a dependency of foo on foo.ext, and when attempting to run make, throws an error of: No rule to make target 'CMakeFiles/foo_custom.dir/requires' Could anyone please shine some light on this? What I have been reading elsewhere (CMake mailing list, stackoverflow, etc.) is that the majority of the time, attempting something similar to the above does not succeed. Could this fix be included among 2.8.8 updates?
-- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake