Gentoo Archives: gentoo-dev

From: Ned Ludd <solar@g.o>
To: "Robin H. Johnson" <robbat2@g.o>
Cc: Gentoo Developers <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] per package cflags (was Re: Do we want optimal performance?)
Date: Thu, 09 Sep 2004 03:43:13
Message-Id: 1094701375.9661.610.camel@simple
In Reply to: Re: [gentoo-dev] per package cflags (was Re: Do we want optimal performance?) by "Robin H. Johnson"
1 On Wed, 2004-09-08 at 22:26, Robin H. Johnson wrote:
2 > On Wed, Sep 08, 2004 at 09:51:15PM -0400, Travis Tilley wrote:
3 > > Daniel Goller wrote:
4 > > >although i am against overly tweaking CFLAGS, someone suggested
5 > > >something that might be more sane to ask for:
6 > > >
7 > > >/etc/portage/packages.cflags
8 > > >
9 > > >an easy way to maintain your cflags you worked so hard for to obtain,
10 > > >you can trade them in the forums or ebay and then append to your file,
11 > > >not much work to implement in my eyes, and all the testing work is done
12 > > >by those who want it
13 > > mkdir /etc/portage and copy this file there (MUCH thanks to solar for
14 > > writing this. he like... kicks ass an stuff). it implements an
15 > > /etc/portage/package.cflags without needing to patch portage. i think
16 > > this might require portage 2.0.51_pre... no idea, i havent used 2.0.50
17 > > in a while.
18 > [snip]
19 > Could this be generalized to do /etc/portage/package.env like somebody
20 > else asked for?
21 >
22 > And then simply put a CFLAGS line in the file referenced by package.env,
23 > as it seems that it really would belong there.
24
25 I played with that idea for a few mins, but unfortunately I found no
26 easy way in bash to deal with the quotes.
27 Assuming this syntax.
28
29 sys-apps/paxctl CFLAGS="-Os -fomit-frame-pointer"
30 sys-devel/gdb CFLAGS="-O2 -g3"
31 app-misc/beep FEATURES="sfperms sandbox" LDFLAGS="-Wl,-z,now
32 -Wl,-z,relro"
33 dev-libs/openssl CFLAGS="-O3 -fno-omit-frame-pointer -m32"
34 ..
35
36 Maybe somebody else is motivated to do it from the basic idea. I gave up
37 and settled for the easy way out of package.cflags package.ldflags here
38 locally.
39
40 --
41 Ned Ludd <solar@g.o>
42 Gentoo (hardened,security,infrastructure,embedded,toolchain) Developer

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies