--- On Sun, 5/25/08, Sebastian Magri <[EMAIL PROTECTED]> wrote:

> From: Sebastian Magri <[EMAIL PROTECTED]>
> Subject: Re: [gentoo-user] Setting CFLAGS for a single build
> To: gentoo-user@lists.gentoo.org
> Date: Sunday, May 25, 2008, 1:49 AM
> 2008/5/25 Alan McKinnon <[EMAIL PROTECTED]>:
> 
> > On Saturday 24 May 2008, Erik Ruotsalainen wrote:
> > > On Sat, May 24, 2008 at 10:02:50AM +0000, dhk
> wrote:
> > > > How can I modify the CFLAGS before emerging
> a package?  I want to
> > > > add -g2 to the compile of libxml2 so I can
> step through their
> > > > functions.  If I add -g2 to CFLAGS in
> make.conf it will do it for
> > > > all packages which is not what I want.
> > > >
> > > > Thanks,
> > > >
> > > > Dave
> > > > --
> > > > gentoo-user@lists.gentoo.org mailing list
> > >
> > > Same way as with USE flags, I think.
> > >
> > > # CFLAGS="-g2" emerge libxml2
> >
> > This works, but is not recommended.
> >
> > Portage will not remember those settings in a way that
> can be
> > duplicated, so the next time that package gets
> remerged (especially as
> > part of a deep update) it will be recompiled without
> the custom CFLAGS.
> >
> > This is a serious blunder and non-trivial to detect
> and fix. It violates
> > the sacrosanct Law Of No Unexpected Side Effects
> >
> > Alan is rigth, the best practice is not to declare any
> environment variable
> or USE Flag before the emerge sentence, but use the
> configuration files in
> "/etc/portage"
> 

Interesting discussion. I'm glad I peeked in.

Here's some more treatment:

http://gentoo-wiki.com/CflagsExceptions

-mw




      
-- 
gentoo-user@lists.gentoo.org mailing list

Reply via email to