No input/outputPaths in XCode project when using "add_custom_command"
I use XCode 10.1 and CMake 3.15.0-rc1 In my project I generate a number of source files at build time using "add_custom_command", which looks like this:
add_custom_command(OUTPUT ${out} COMMAND ${cmd} DEPENDS ${dep})
My expectation is that ${out} list will be added into "outputPaths" and ${dep} - into "inputPaths" of the shell script build phase. But, both lists are empty. As a result, XCode build fails saying that source file was not found. When I then look into the source tree I see that the source file exists. If I run the build again (making no changes), it succeeds. Everything works just fine on Microsoft Visual Studio - Outputs and Additional dependencies are set to what they should be set. I see here that this problem appears to be fixed some time ago (v3.9?). Still, it does not work for me.