0

I am trying to get the command line arguments of ./configure in confdefs.h using something like:

AC_DEFINE_UNQUOTED([CONFIGURATION], ["$@"], [Configuration commandline parameters])

But it gets evaluted to

#define CONFIGURATION "darwin12.4.0"

What am I doing wrong?

4

1 回答 1

1

这是正确的方法:

AC_INIT([programname], 1.0, ...)
configure_flags="$*"
AC_DEFINE_UNQUOTED([CONFIG_FLAGS], ["$configure_flags"], [Flags passed to configure])
于 2013-08-03T15:01:07.683 回答