Discussion:
configure mutilates -g option
Bruce Korb
2013-01-12 20:38:38 UTC
Permalink
Hi,

GCC's -g option takes an optional argument.
If you add to the command line:
./configure --enable-debug --disable-fast-install CFLAGS=-ggdb3

at some point, the script will remove the "-g" and then add it back in with a space


+ eval 'ac_val=$ac_configure_args'
++ ac_val=' '\''--enable-debug'\'' '\''--disable-fast-install'\'' '\''CFLAGS=-ggdb3'\'' '\''CC=/usr/bin/gcc'\'' '\''--with-packager=Bruce'\'' '\''--with-packager-version=2013-01-12'\'' '\''--with-packager-bug-reports=***@gnu.org'\'''
[....]

+ eval 'ac_val=$ac_cv_env_CFLAGS_value'
++ ac_val=-ggdb3

+ eval 'ac_val=$ac_save_CFLAGS'
++ ac_val=-ggdb3

+ eval 'ac_val=$ac_try_echo'
++ ac_val='configure:16225: /usr/bin/gcc -std=gnu99 -o conftest -g gdb3 conftest.c -ldl >&5'

I'd like to find the cause, but I just don't have the hours it would take.
Dave Goodell
2013-01-14 14:27:32 UTC
Permalink
Post by Bruce Korb
GCC's -g option takes an optional argument.
./configure --enable-debug --disable-fast-install CFLAGS=-ggdb3
at some point, the script will remove the "-g" and then add it back in with a space
I couldn't reproduce this with a simple autoconf+automake+libtool (2.69/1.13.1/2.42) test project. Can you provide more information about which tool versions and exactly which software project is failing this way? I can't guarantee that I'll have time to look at it, but I would prefer to keep my projects from being bitten in the same way, so I might be able to find some time.

-Dave

Loading...