I'm using asn1c in order to produce from one or more .asn1 files a series of .h and .c files into a given folder.
These C files have no correspondence in names with the original asn1 files.
These files must be linked together with mine in order to obtain a working executable. I'd love to be able to:
- Automatically generate the files in the build directory to avoid polluting the rest of the project (probably done with
add_custom_target) - Specify the dependency of my executable on those files, so that the
asn1cexecutable is automatically run if the files are missing or if one of the.asn1files is updated. - Automatically add ALL generated files to the compilation of my executable.
Since the generated files are not known in advance it's ok to just glob whatever the contents of the output directory of the asn1c command - as long as the directory is not empty I'm happy.