Bug 1099282 - clang doesn't understand -fstack-protector-strong
Summary: clang doesn't understand -fstack-protector-strong
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: llvm
Version: 23
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Nobody's working on this, feel free to take it
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-05-20 02:39 UTC by Timothy St. Clair
Modified: 2016-06-05 14:39 UTC (History)
8 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2016-06-05 14:39:41 UTC


Attachments (Terms of Use)

Comment 1 Timothy St. Clair 2014-05-20 02:43:19 UTC
Description of problem:
Failure on configure.

Version-Release number of selected component (if applicable):
llvm-3.4-6.fc20.x86_64 

How reproducible:
100%

Steps to Reproduce:
1. Run configure on a standard application
2. Failure on invalid flag '-fstack-protector-strong'

Actual results:
Failure 

Expected results:
Success

Additional info: 

https://issues.apache.org/jira/browse/MESOS-1385


llvm-config --cxxflags
-I/usr/include  -DNDEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches  -m64 -mtune=generic -fomit-frame-pointer -std=c++11 -fvisibility-inlines-hidden -fno-exceptions -fPIC -Woverloaded-virtual -Wcast-qual

Comment 2 Adam Jackson 2014-05-29 20:06:41 UTC
Fedora's default CFLAGS assume gcc is the compiler, that's not about to change.  Presumably clang needs to learn more command-line compatibility with gcc, and/or you need to filter that flag out of CFLAGS when you build.

Comment 3 Timothy St. Clair 2014-05-30 13:50:31 UTC
There appears to be a work-a-round, but I don't think it should fail out of the gate: 

https://lists.fedoraproject.org/pipermail/devel/2014-May/199477.html

--------------------------

If you're building RPMs locally, you can drop your own definition of
__global_cflags into '~/.rpmmacros':

%__global_cflags    -O2 -g ..etc..

If you are building a package that uses an autoconf-generated
configure script, then simply setting CFLAGS before running configure
should be enough, eg:

  CFLAGS="$(
    rpm --eval '%{__global_cflags}' |
      sed 's/-fstack-protector-strong//'
  )" \
  ./configure

--------------------------

Comment 4 Adam Jackson 2014-11-19 16:28:32 UTC
Reassign to nobody@.  I have no time and no interest in working on clang, and the only reason it's even in the llvm package is because it can't be built any other way.

If anyone wishes to volunteer for comaintainer with a focus on clang, please let me know (preferably with direct email, if it's in bz I'll likely miss the request), I'll be happy to hook you up.

Comment 5 Fedora End Of Life 2015-05-29 11:54:05 UTC
This message is a reminder that Fedora 20 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 20. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '20'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 20 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 6 Jan Kurik 2015-07-15 14:40:13 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle.
Changing version to '23'.

(As we did not run this process for some time, it could affect also pre-Fedora 23 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora23

Comment 7 Jan Včelák 2016-06-05 14:39:41 UTC
-fstack-protector-strong was added in clang 3.8. It should work in Fedora 24


Note You need to log in before you can comment on or make changes to this bug.