I have a custom target'download_files' that is not part of the build, so users can call it manually. Now I would like to add another custom target that performs the custom target 'download_files' and then still build the all target. Is that possible in cmake? This is what I tried:
add_custom_target(download_files)
add_custom_target(download_and_build DEPENDS download_files all)
I do this because I do not always want to download the files, but it might still be convenient to have a target that does both in one go.
It seems that 'all' is not really a target, although CMake configure and generate goes well.
ninja: error: '../all', needed by 'CMakeFiles/download_and_build ', missing and no known rule to make it