3

autoconf save ./configure command line to config.h

view full story
linux-howto

http://unix.stackexchange.com – Some binaries save the command line used to configure them inside the binary (I don't remember any that do, otherwise I'd check the source). Is there a way to obtain the command line used as a macro in configure.ac? For example, if I compile my code with ./configure --foo bar CXX=g++ I would like to save --foo bar CXX=g++ to a macro in config.h so it can be output by the binary using a flag ./myprogram -V Version 1.0, compiled using: "./configure --foo bar CXX=g++" (HowTos)