Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Sergei Trofimovich <slyich@gmail.com>
To: Ian Kumlien <pomac@vapor.com>
Cc: Ian Kumlien <pomac@demius.net>, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] Btrfs-progs: -U_FORTIFY_SOURCE before -D
Date: Sun, 10 Feb 2013 01:06:26 +0300	[thread overview]
Message-ID: <20130210010626.487a8044@sf> (raw)
In-Reply-To: <20130209185720.GR15780@pomac.netswarm.net>

[-- Attachment #1: Type: text/plain, Size: 1676 bytes --]

On Sat, 9 Feb 2013 19:57:20 +0100
Ian Kumlien <pomac@vapor.com> wrote:

> On Sat, Feb 09, 2013 at 09:02:06PM +0300, Sergei Trofimovich wrote:
> > On Sat,  9 Feb 2013 00:30:21 +0100
> > Ian Kumlien <pomac@demius.net> wrote:
> > 
> > > My builds are cluttered with:
> > > <command-line>:0:0: warning: "_FORTIFY_SOURCE" redefined [enabled by
> > > default]
> > > 
> > > Which makes it hard to tell if something breaks or not.
> > 
> > > I don't know about you, but bilding with 
> > > GCC 4.7.2 on gentoo, this is a issue.
> > 
> > Unfortunately it's a gentoo specific gcc bug. I'd suggest reporting
> > it to bugs.gentoo.org. That -D by default breaks linux's perf as well
> > (due to -D_FOTIFY_SOURCE=2 -Werror in perf sources).
> 
> Is it? There is a workaround in the android build system for compilers
> on ubuntu.
> 
> Where can i find that bug report?

I think you need to fill the new one.

> This is not a emerge, this is a normal system build.

Yeah, gentoo has patched gcc specs so you get -D_FORTIFY_SOURCE=2
in gcc command line by default.

http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo/src/patchsets/gcc/4.6.0/gentoo/10_all_default-fortify-source.patch?view=markup

> > Current workaround is to pass AM_CFLAGS to make:
> >     make AM_CFLAGS=stuff_w/o_fortify_source
> > It's what gentoo's live ebuild does.
> 
> I can't see it here in the live ebuild... 

sys-fs/btrfs-progs/btrfs-progs-9999.ebuild:
...
src_compile() {
        emake \
                CC="$(tc-getCC)" \
                AM_CFLAGS=-D_FILE_OFFSET_BITS=64 \
                ...
}

This line overrides in-Makefiles AM_CFLAGS.

-- 

  Sergei

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  reply	other threads:[~2013-02-09 22:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-08 23:30 [PATCH] Btrfs-progs: -U_FORTIFY_SOURCE before -D Ian Kumlien
2013-02-09 18:02 ` Sergei Trofimovich
2013-02-09 18:57   ` Ian Kumlien
2013-02-09 22:06     ` Sergei Trofimovich [this message]
2013-02-09 22:33       ` Ian Kumlien
2013-02-12 14:18   ` David Sterba

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130210010626.487a8044@sf \
    --to=slyich@gmail.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=pomac@demius.net \
    --cc=pomac@vapor.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox