Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 554038 - media-gfx/imagemagick-6.9.1.7: has idiotic *FLAGS sanitization that breaks CFLAGS
Summary: media-gfx/imagemagick-6.9.1.7: has idiotic *FLAGS sanitization that breaks CF...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal major (vote)
Assignee: Gentoo Graphics Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-05 20:26 UTC by Michał Górny
Modified: 2015-07-09 04:53 UTC (History)
1 user (show)

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


Attachments
build log (build.log,49.76 KB, text/x-log)
2015-07-06 18:02 UTC, Xavier Miller
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-07-05 20:26:45 UTC
Long story short, someone decided that it's a good idea to remove duplicate words from CFLAGS.

So:

CFLAGS="-march=k8-sse3 -mcx16 -msahf --param l1-cache-size=64 --param l1-cache-line-size=64 --param l2-cache-size=512 -O2 -pipe -frecord-gcc-switches"

get turned into:

CFLAGS="-march=k8-sse3 -mcx16 -msahf --param l1-cache-size=64 l1-cache-line-size=64 l2-cache-size=512 -O2 -pipe -frecord-gcc-switches"

Could someone tell those ekhms not to fiddle with flags? Not to mention what would happen if someone had some -Bstatic -Bdynamic...
Comment 1 Xavier Miller gentoo-dev 2015-07-06 18:02:08 UTC
Created attachment 406268 [details]
build log

Same for me:

CFLAGS="-march=core2 -mcx16 -msahf -mpclmul -mpopcnt -msse4.2 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=256 -mtune=core2 -fomit-frame-pointer -O2"

Becomes: 
libtool: compile:  x86_64-gentoo-linux-gnu-gcc -std=gnu99 -std=gnu99 -DHAVE_CONFIG_H -I. -I. -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng16 -pthread -I/usr/include/librsvg-2.0 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/OpenEXR -I/usr/include/openjpeg-2.1 -fopenmp -march=core2 -mcx16 -msahf -mpclmul -mpopcnt -msse4.2 --param l1-cache-size=32 l1-cache-line-size=64 l2-cache-size=256 -mtune=core2 -fomit-frame-pointer -O2 -Wall -fexceptions -DMAGICKCORE_HDRI_ENABLE=0 -DMAGICKCORE_QUANTUM_DEPTH=16 -c magick/accelerate.c  -fPIC -DPIC -o magick/.libs/magick_libMagickCore_6_Q16_la-accelerate.o
x86_64-gentoo-linux-gnu-gcc: error: l1-cache-line-size=64: No such file or directory
Comment 2 Tim Harder gentoo-dev 2015-07-08 01:40:10 UTC
Fixed in the tree without a revision bump since I'm assuming it would have broken builds for most people using explicitly expanded -march=native CFLAGS or similar and not broken for others with simpler settings.
Comment 3 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-07-09 04:53:53 UTC
As a side note, upstream reverted the commit after my report.