Auto generated files in a project are pretty common. There are generally 3 scenarios for this in a project that needs auto-generated files:
- An external pre-built tool generates files pre-compilation and then the generated files get checked in to the tree
- The tool is compiled in-tree but is again used to generate files pre-compilation and then check them into tree
- The tool is built during the main build step and then it also generates the needed files just in time.
Arguably, the last method is usually the better one since it keeps friction to a minimum during development by always generating latest files according to any changes done locally and also prevents against the human error of someone foregetting to commit the separately generated files, or having a time period where the tree is out of sync because the generated files and hand written files were committed separately. There is a con as well that such files are not available for someone going through the code statically for understanding or debugging. But one could always couple both methods if so desired.