Bug 1309080 - net-snmp-config specifies redhat-hardened-cc1 in cflags and causes gcc failure without redhat-rpm-config
net-snmp-config specifies redhat-hardened-cc1 in cflags and causes gcc failur...
Product: Fedora
Classification: Fedora
Component: net-snmp (Show other bugs)
x86_64 Linux
unspecified Severity medium
: ---
: ---
Assigned To: Jan Safranek
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2016-02-16 14:20 EST by George Joseph
Modified: 2016-02-24 06:31 EST (History)
2 users (show)

See Also:
Fixed In Version: net-snmp-5.7.3-9.fc24
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-02-24 06:31:35 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description George Joseph 2016-02-16 14:20:23 EST
Description of problem:

net-snmp-config --cflags returns 
"-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1" but if redhat-rpm-config isn't installed, compilation will fail because redhat-hardened-cc1 won't be found.

It should be up to the developer whether a hardened build is required for their app even if the net-snmp packages were built hardened.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. run net-snmp-config --cflags without redhat-rpm-config installed
2. try to compile a stub program

Actual results:

-DNETSNMP_ENABLE_IPV6 -fno-strict-aliasing -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -D_RPM_4_4_COMPAT -Wformat -Ulinux -Dlinux=linux -D_REENTRANT -D_GNU_SOURCE -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -fwrapv -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib64/perl5/CORE -I. -I/usr/include
gcc: error: /usr/lib/rpm/redhat/redhat-hardened-cc1: No such file or directory

Expected results:

-DNETSNMP_ENABLE_IPV6 -fno-strict-aliasing -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_RPM_4_4_COMPAT -Wformat -Ulinux -Dlinux=linux -D_REENTRANT -D_GNU_SOURCE -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -fwrapv -fno-strict-aliasing -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib64/perl5/CORE -I. -I/usr/include

No -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1

Additional info:
Comment 1 Jan Safranek 2016-02-24 06:31:35 EST
net-snmp-config --cflags now does not report any flags used to compile net-snmp. I'll update F24 and rawhide.

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