Export extra preprocessor defines into a header
Several preprocessor macros (e.g. GAUDI_V20_COMPAT
, BOOST_FILESYSTEM_VERSION=3
) are passed to the compiler using the -D
flag when building Gaudi [projects].
If cling(/gInterpreter
) is used directly then these macros are not automatically defined. They are, however, propagated to the genreflex
command line, so they are consistently defined inside cling when dictionaries are loaded.
This can lead to inconsistent results and cling errors if cling is used before any dictionary loading is triggered. (For example, the stderr in this test.)
If the Gaudi cmake generated a header containing
#ifndef GAUDI_V20_COMPAT
#define GAUDI_V20_COMPAT
#endif
and so on, this could be loaded with cling to guarantee consistency.