Closed
Bug 1418398
Opened 8 years ago
Closed 8 years ago
gcc on Gentoo defines _FORTIFY_SOURCE as a built-in causing compilation failures when we redefine it
Categories
(Firefox Build System :: General, defect)
Firefox Build System
General
Tracking
(firefox59 fixed)
RESOLVED
FIXED
mozilla59
| Tracking | Status | |
|---|---|---|
| firefox59 | --- | fixed |
People
(Reporter: gsvelto, Assigned: gsvelto)
References
Details
Attachments
(1 file)
Gentoo's current stable GCC ebuild patches the sources so that _FORTIFY_BUILD is defined as a built-in if __OPTIMIZE__ is set:
https://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo/src/patchsets/gcc/5.4.0/gentoo/10_all_default-fortify-source.patch?view=markup
This causes build failures because we re-define _FORTIFY_BUILD at configuration time.
Comment 1•8 years ago
|
||
What's correct protocol here? Do we handle this somehow in our config, or should gentoo stop doing this now that it's upstreamed? (Seems like the latter to me...?)
| Assignee | ||
Comment 2•8 years ago
|
||
I don't know, I'm tempted to file a Gentoo bug.
Comment 3•8 years ago
|
||
Gentoo should stop doing this. Until such time, perhaps bootstrap can print out instructions to --disable-hardening?
Comment 4•8 years ago
|
||
(In reply to :froydnj (on leave until 2018, ni? or email if necessary) from comment #3)
> Gentoo should stop doing this. Until such time, perhaps bootstrap can print
> out instructions to --disable-hardening?
That won't work until I figure out how to solve Bug 1418052 :)
| Assignee | ||
Comment 5•8 years ago
|
||
Quick update: while the fix for this is trivial, version 6.4.0 of GCC has just been marked stable on Gentoo and from the looks of it it doesn't seem to define _FORTIFY_SOURCE anymore. I'll double-check it later today.
| Assignee | ||
Comment 6•8 years ago
|
||
I was wrong, this applies to version 6.4.0 too, updating the title to reflect that. I've got a quick fix almost ready.
Summary: gcc-5.4.0 on Gentoo defines _FORTIFY_SOURCE as a built-in causing compilation failures when we redefine it → gcc on Gentoo defines _FORTIFY_SOURCE as a built-in causing compilation failures when we redefine it
| Assignee | ||
Updated•8 years ago
|
Assignee: nobody → gsvelto
Status: NEW → ASSIGNED
| Comment hidden (mozreview-request) |
Comment 8•8 years ago
|
||
| mozreview-review | ||
Comment on attachment 8930118 [details]
Bug 1418398 - Always un-define _FORTIFY_SOURCE before defining it;
https://reviewboard.mozilla.org/r/201288/#review206516
Attachment #8930118 -
Flags: review?(mh+mozilla) → review+
| Assignee | ||
Comment 9•8 years ago
|
||
Thanks Mike!
Comment 10•8 years ago
|
||
Pushed by gsvelto@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/6c027fdb55dd
Always un-define _FORTIFY_SOURCE before defining it; r=glandium
Comment 11•8 years ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox59:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Updated•8 years ago
|
Product: Core → Firefox Build System
You need to log in
before you can comment on or make changes to this bug.
Description
•