Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 410537 - app-cdr/cdrtools-3.01_alpha07 does not fully respect CFLAGS
Summary: app-cdr/cdrtools-3.01_alpha07 does not fully respect CFLAGS
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal QA (vote)
Assignee: Daniel Pielmeier
URL:
Whiteboard:
Keywords: EBUILD, PATCH
Depends on:
Blocks:
 
Reported: 2012-04-02 11:31 UTC by Michael Palimaka (kensington)
Modified: 2012-04-28 17:13 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,355.12 KB, text/plain)
2012-04-02 11:31 UTC, Michael Palimaka (kensington)
Details
cdrtools-3.01_alpha07.ebuild.patch (cdrtools-3.01_alpha07.ebuild.patch,453 bytes, patch)
2012-04-09 07:11 UTC, Michael Palimaka (kensington)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Palimaka (kensington) gentoo-dev 2012-04-02 11:31:46 UTC
Created attachment 307475 [details]
build.log

While user CFLAGS are included, "-O" is added by the build system:

make[2]: Entering directory `/var/tmp/portage/app-cdr/cdrtools-3.01_alpha07/work/cdrtools-3.01/inc'
x86_64-pc-linux-gnu-gcc -O -march=native -O2 -ggdb -finput-charset=ISO-8859-1 -fexec-charset=UTF-8 -DSCHILY_BUILD -IOBJ/amd64-linux-cc -I../incs/amd64-linux-cc -I../include -D_GNU_SOURCE -D__OPRINTF__ -c -o OBJ/amd64-linux-cc/align_test.o align_test.c


Portage 2.1.10.54 (hardened/linux/amd64, gcc-4.5.3-asneeded, glibc-2.14.1-r2, 3.3.0-hardened-gnu x86_64)
=================================================================
System uname: Linux-3.3.0-hardened-gnu-x86_64-06-17-with-gentoo-2.1
Timestamp of tree: Mon, 02 Apr 2012 09:15:01 +0000
app-shells/bash:          4.2_p24
dev-java/java-config:     2.1.11-r3
dev-lang/python:          2.7.2-r3, 3.2.2-r1
dev-util/cmake:           2.8.7-r5
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1
sys-apps/openrc:          0.9.9.3
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.68
sys-devel/automake:       1.9.6-r3, 1.11.3
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.5.3-r2
sys-devel/gcc-config:     1.6
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.3 (virtual/os-headers)
sys-libs/glibc:           2.14.1-r2
Repositories: gentoo sunrise kensington qt kde x-portage
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA AdobeFlash-10.1 AdobeFlash-10.3"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -ggdb"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /var/qmail/alias /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=native -O2 -ggdb"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs collision-protect distlocks ebuild-locks fixlafiles multilib-strict news parallel-fetch protect-owned sandbox sfperms split-elog split-log splitdebug strict test unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync"
FFLAGS=""
GENTOO_MIRRORS="http://mirror.internode.on.net/pub/gentoo/ http://distfiles.gentoo.org/"
LANG="en_AU.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--hash-style=gnu"
LINGUAS="en en_US"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /var/lib/layman/kensington /var/lib/layman/qt /var/lib/layman/kde /usr/local/portage"
SYNC="rsync://rsync.au.gentoo.org/gentoo-portage"
USE="aac acl acpi alsa amd64 apache2 apng asf background bash-completion bazaar berkdb bzip2 cairo cleartype cli consolekit corefonts cracklib crashreporter crypt cups cxx dbus deblob dep device-mapper dri dvd ebook exceptions fam ffmpeg flac fontconfig gdbm git glib gmp gold gpm handbook hardened iconv ipv6 ithreads jit jpeg justify kde kontact lastfm less libnotify mikmod minizip mmx mng modules mp3 mp4 mpeg mta mudflap multilib ncurses nls nptl nptlonly ogg opengl openmp optimized-qmake pam pax_kernel pcap pcre phonon player png policykit pppd private-headers qt3support qt4 readline rss semantic-desktop session sftp sha512 smbclient spell sse sse2 ssl ssse3 startup-notification suhosin svg symlink sysfs tcpd theora threads threadsafe tiff truetype udev unicode upnp uuid vhosts vorbis webm xft xorg xscreensaver xvfb zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="*" APACHE2_MODULES="dav alias auth_basic authn_default auth_digest authn_file authz_host authz_user autoindex cgi deflate dir filter headers include info log_config mime mime_magic negotiation proxy proxy_http rewrite speling status vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" DRACUT_MODULES="crypt crypt-gpg lvm mdraid" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en en_US" PHP_TARGETS="php5-3 php5-4" RUBY_TARGETS="ruby19" USERLAND="GNU" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Daniel Pielmeier gentoo-dev 2012-04-08 11:56:14 UTC
But -O gets overridden by -O2 as it comes later in the gcc command line. The only thing I can imagine would be if the user does not want any optimization at all and use the default of -O0.
Comment 2 Michael Palimaka (kensington) gentoo-dev 2012-04-09 07:11:46 UTC
Created attachment 308279 [details, diff]
cdrtools-3.01_alpha07.ebuild.patch

(In reply to comment #1)
> But -O gets overridden by -O2 as it comes later in the gcc command line. The
> only thing I can imagine would be if the user does not want any optimization
> at all and use the default of -O0.

Indeed, so not exactly a show-stopper, but still important IMO.

Attached is a patch to correct the report in comment #0, as well as remove instances (which I originally missed) where -O3 -fexpensive-optimizations is also added.
Comment 3 Michael Palimaka (kensington) gentoo-dev 2012-04-09 07:33:36 UTC
(In reply to comment #1)
> But -O gets overridden by -O2 as it comes later in the gcc command line. The
> only thing I can imagine would be if the user does not want any optimization
> at all and use the default of -O0.
Comment 4 Daniel Pielmeier gentoo-dev 2012-04-28 17:13:47 UTC
+  28 Apr 2012; Daniel Pielmeier <billie@gentoo.org> cdrtools-3.00.ebuild,
+  cdrtools-3.01_alpha07.ebuild:
+  Fix bug #410537 to respect CFLAGS. Thanks to Michael (kensington) for the
+  report and the ebuild patch.