Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 343681

Summary: net-misc/curl-7.21.1 enforces -g0
Product: Gentoo Linux Reporter: Hugo Mildenberger <Hugo.Mildenberger>
Component: [OLD] LibraryAssignee: Daniel Black (RETIRED) <dragonheart>
Status: RESOLVED FIXED    
Severity: QA CC: qa
Priority: High Keywords: InVCS
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Hugo Mildenberger 2010-11-01 11:28:31 UTC
While having "-g" in CFLAGS, I wondered why curl disables debugging alltogether. Somehow curl replaces "-g" by "-g0". 

Here is an excerpt:

libtool: compile:  i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I../include/curl -I../include -I../include -I../lib -I../lib -march=pentium4 -mtune=pentium4 -O2 -pipe -Wall -fstack-protector -g0 -Wno-system-headers -pthread -MT connect.lo -MD -MP -MF .deps/connect.Tpo -c connect.c -o connect.o >/dev/null 2>&1
Comment 1 Hugo Mildenberger 2010-11-01 12:03:47 UTC
Curl's configures script enables the generation of debug info only if "--enable-debug" was given. Unfortunately, this options also sets the DEBUGBUILD preprocessor symbol, and this runs against Gentoo's philosophy of having debug symbols ready independent from special debug builds (which are specifically controlled by passing the "debug" use flag to emerge or ebuild).  
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2011-02-02 23:18:24 UTC
While a hasq is usually bad form, it might be valid in this case.
Comment 3 Tomáš Chvátal (RETIRED) gentoo-dev 2011-02-19 17:23:07 UTC
Fixed in 7.21.4