Difficulty with add_executable() with generated files

(1) since the generator is yours you can make it generate a list file that can be included using
https://cmake.org/cmake/help/latest/command/include.html, so the content of the generated file may defined a CMake variable, e.g. GENERATED_FILES which contains the list of generated file.

You can
include(generated_file.cmake OPTIONAL)
so that inclusion would not break if file is not there, but you’ll have to run cmake twice to get it right.

or you statically know the list of file (as @ben.boeckel said)

or you generate the list of file during configuration using https://cmake.org/cmake/help/latest/command/execute_process.html so that the to-be-include file is ensured to exists (provided execute_process happens before include).
In that last case you may have to rerun cmake manually when nodes_definition.json changes, unless
you add https://cmake.org/cmake/help/latest/prop_dir/CMAKE_CONFIGURE_DEPENDS.html property to nodes_definition.json file so that cmake will be rerun as soon as nodes_definition.json changes.

Now @ben.boeckel advised against this solution in the past: CMAKE_CONFIGURE_DEPENDS with newly created file so may be he can explain why.