This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to suppress "warning: -fPIC ignored for target..." under Cygwin


Under Cygwin, GCC prints out the following warning and the head of
each file it compiles when using -fPIC.

I want to avoid removing PIC because its not clear to me when PIE may
(or may not) be automatically present. That is, users of older
platforms may not have it by default.

What is the -Wno-XXX used to disable the warning? How do I suppress
the extraneous output?

Thanks in advance.

**********

$ make
g++ -DNDEBUG -O3 -g2 -fPIC -march=native -pipe
-DCRYPTOPP_NO_UNALIGNED_DATA_ACCESS -c shacal2.cpp
shacal2.cpp:1:0: warning: -fPIC ignored for target (all code is
position independent)
 // shacal2.cpp - by Kevin Springle, 2003
 ^
g++ -DNDEBUG -O3 -g2 -fPIC -march=native -pipe
-DCRYPTOPP_NO_UNALIGNED_DATA_ACCESS -c seed.cpp
seed.cpp:1:0: warning: -fPIC ignored for target (all code is position
independent)
 // seed.cpp - written and placed in the public domain by Wei Dai
 ^
g++ -DNDEBUG -O3 -g2 -fPIC -march=native -pipe
-DCRYPTOPP_NO_UNALIGNED_DATA_ACCESS -c shark.cpp
shark.cpp:1:0: warning: -fPIC ignored for target (all code is position
independent)
 // shark.cpp - written and placed in the public domain by Wei Dai
 ^

...


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]