Author Topic: cc1plus.exe: unrecognized option `-Winvalid-pch'  (Read 9631 times)

Micah

  • Guest
cc1plus.exe: unrecognized option `-Winvalid-pch'
« on: November 05, 2005, 02:36:09 am »
I'm trying to build Code::Blocks from source. So far I have followed these instructions to the letter
http://wiki.codeblocks.org/index.php/Compiling_wxWidgets_2.6.1_to_develop_Code::Blocks_%28MSW%29


Error:
Switching to target: tinyXML
mingw32-g++.exe   -Wall -g -pipe -mthreads -fmessage-length=0 -fexceptions -Winvalid-pch -DHAVE_W32API_H -D__WXMSW__ -DWXUSINGDLL -DcbDEBUG -DTIXML_USE_STL -DCB_PRECOMP -DWX_PRECOMP -DEXPORT_LIB    -IC:\source\wxWidgets-2.6.2\include -IC:\source\wxWidgets-2.6.2\lib\codeblocks\msw -IC:\source\wxWidgets-2.6.2\contrib\include -Isdk\wxscintilla\include  -IC:\Programs\MinGW\include -c sdk\tinyxml\tinyxml.cpp -o .objs\2.6\sdk\tinyxml\tinyxml.o
cc1plus.exe: unrecognized option `-Winvalid-pch'


I searched the web for -Winvalid-pch but couldn't find anything on it. :(

Code::Blocks Version 1.0 Release Candidate 2 (downloaded and installed from
http://prdownloads.sourceforge.net/codeblocks/codeblocks-1.0rc2.exe?download

$ mingw32-g++ -v
Reading specs from c:/Programs/MinGW/bin/../lib/gcc-lib/mingw32/3.2.3/specs
Configured with: ../gcc/configure --with-gcc --with-gnu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls --enable-languages=c++,f77,objc --disable-win32-registry --disable-shared --enable-sjlj-exceptions
Thread model: win32
gcc version 3.2.3 (mingw special 20030504-1)

wxWidgets 2.6.2 from
http://prdownloads.sourceforge.net/wxwindows/wxMSW-2.6.2.zip

grv575

  • Guest
Re: cc1plus.exe: unrecognized option `-Winvalid-pch'
« Reply #1 on: November 05, 2005, 02:48:40 am »
Update to a recent mingw

$ mingw32-gcc -v
...
gcc version 3.4.4 (mingw special)

This should be added to the wiki I guess.

(btw, -Winvalid-pch tells the search engine to look for pages which do not contain "Winvalid-pch".  What you really want is to search google for Winvalid-pch)

Micah

  • Guest
Re: cc1plus.exe: unrecognized option `-Winvalid-pch'
« Reply #2 on: November 07, 2005, 06:36:19 pm »
Thanks, I updated MinGW and everything seems to be working well now. I'm not quite sure how I ended up getting such an old version since according to the website 3.4.2 has been out for over a year and I installed MinGW less than 6 months ago.

(btw, -Winvalid-pch tells the search engine to look for pages which do not contain "Winvalid-pch".  What you really want is to search google for Winvalid-pch)

I tried searching for "Winvalid-pch", and "invalid-pch" and was not able to come up with any information on it on google.com or groups.google.com. :(

Offline yop

  • Regular
  • ***
  • Posts: 387
Re: cc1plus.exe: unrecognized option `-Winvalid-pch'
« Reply #3 on: November 07, 2005, 07:59:44 pm »
From the mingw manual, chapter 3.8 (http://gcc.gnu.org/onlinedocs/gcc-4.0.2/gcc/Warning-Options.html#index-Winvalid_002dpch-286)
Quote
-Winvalid-pch
    Warn if a precompiled header (see Precompiled Headers) is found in the search path but can't be used.
Life would be so much easier if we could just look at the source code.