Include header files using command line option?

I found the -include option. Does this what you want?

-include file

Process file as if “#include “file”” appeared as the first line of
the primary source file. However, the
first directory searched for file is
the preprocessor’s working directory
instead of the directory containing
the main source file. If not found
there, it is searched for in the
remainder of the “#include “…””
search chain as normal.

If multiple -include options are given, the files are included in the
order they appear on the command line.

Leave a Comment