Bug 81482 - gcc won't compile system headers without warnings
gcc won't compile system headers without warnings
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
8.0
i686 Linux
medium Severity low
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
:
: 81483 (view as bug list)
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-01-09 15:41 EST by Pat Gunn
Modified: 2007-04-18 12:49 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2003-01-10 09:30:09 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Pat Gunn 2003-01-09 15:41:44 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2) Gecko/20021126

Description of problem:
When I use the following gcc flags:
gcc -g -pedantic-errors  -Wall -O -pedantic -Wunused-parameter -Wunused-variable
-Wuninitialized -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wconversion
-Wsign-compare -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations
-Wmissing-format-attribute -Wpadded -Wredundant-decls -Wunreachable-code
-Winline -Wdisabled-optimization

On code that includes math.h on redhat8,
it gives the following error:

In file included from /usr/include/math.h:362,
                 from standard.h:107,
                 from ambs.h:27,
                 from amma.h:15,
                 from amvpv.h:14,
                 from amvpv.c:1:
/usr/include/bits/mathinline.h: In function `fabsf':
/usr/include/bits/mathinline.h:446: passing arg 1 of `__builtin_fabsf' as
`float' rather than `double' due to prototype
make[1]: *** [Linux_x86_glibc-2.2.93_gcc.debug/amvpv.o] Error 1


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


How reproducible:
Always

Steps to Reproduce:
See above

Additional info:
Comment 1 Pat Gunn 2003-01-10 09:19:50 EST
*** Bug 81483 has been marked as a duplicate of this bug. ***
Comment 2 Jakub Jelinek 2003-01-10 09:30:09 EST
Either remove -Wconversion, or get rid of -pedantic-errors, you cannot have both.
<math.h> has to declare functions required by the standard to use float
arguments. -Wconversion is there to help playing together with code without
prototypes, but you really cannot use any of the *f or *l functions in them
anyway.

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