Page 1 of 1
Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 8:41 pm
by ctrl
I'v ebeen using CodeLite for my CS course and it was working fine until it suddenly would not compile anything correctly. When I tried to fix it, I found out that somehow I had reset my compiler to mingw32-make.exe (this is on Windows), so I set it back to the compiler I had been using (mingw32-g++.exe), and there is suddenly an unrecognized compiler option that I can't remove.
----------Build Started--------
C:\Windows\system32\cmd.exe /c ""C:/Program Files (x86)/MinGW-4.6.1/bin/mingw32-g++.exe" -j 2 "cs102_wsp.mk""
mingw32-g++.exe: error: 2: No such file or directory
mingw32-g++.exe: error: unrecognized option '-j'
----------Build Ended----------
0 errors, 0 warnings
Any ideas?
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 8:43 pm
by ctrl
Probably should have added that I have checked everything I can think to check, like linker options, compiler options, build tool switches, etc.
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 8:58 pm
by eranif
ctrl wrote:Probably should have added that I have checked everything I can think to check, like linker options, compiler options, build tool switches, etc.
You changed the wrong tool.
From:
"Settings -> build settings -> build system -> build tool"
Change:
mingw32-g++ to mingw32-make
You chnaged the build tool (the 'make' to 'g++;)
if you want to change the compiler, its from:
"settings -> build settings -> compilers -> gnu g++ -> tools"
Eran
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 9:14 pm
by ctrl
Is there a certain format I have to use? Do I have to change the environment variables? Because when I change the build tool back to mingw32-make.exe and put in a compiler name under Build Settings-->Compiler-->gnu g++-->tools it just gives me an error:
----------Build Started--------
C:\Windows\system32\cmd.exe /c ""C:/Program Files (x86)/MinGW-4.6.1/bin/mingw32-make.exe" -j 2 -f "cs102_wsp.mk""
----------Building project:[ Filestream - Debug ]----------
mingw32-make[1]: Entering directory `C:/Users/Alan/My Documents/cs102/Filestream'
'g++' is not recognized as an internal or external command,
operable program or batch file.
mingw32-make[1]: *** [/main.o.d] Error 1
mingw32-make.exe: *** [All] Error 2
mingw32-make[1]: Leaving directory `C:/Users/Alan/My Documents/cs102/Filestream'
----------Build Ended----------
0 errors, 0 warnings
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 9:28 pm
by eranif
You probably modified the PATH of you system within codelite.
Did you alter PATH environment variable anywhere in codelite?
Do you have g++ in the path (it looks like its not in the path)
Try adding the MinGW bin directory path to the PATH environment variable
from:
setting -> environment variable
and add:
Code: Select all
PATH=C:\Program Files (x86)\MinGW-4.6.1\bin;$(PATH)
Eran
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 10:04 pm
by ctrl
I've tried modifying the environment variables and the PATH environment variable under Build Settings-->Compiler and it just gives me this huge list of issues:
----------Build Started--------
C:\Windows\system32\cmd.exe /c ""C:/Program Files (x86)/MinGW-4.6.1/bin/mingw32-make.exe" -j 2 -f "cs102_wsp.mk""
----------Building project:[ Filestream - Debug ]----------
mingw32-make[1]: Entering directory `C:/Users/Alan/My Documents/cs102/Filestream'
g++: error: Files: No such file or directory
g++: error: (x86)\MinGW-4.6.1\bin;C:\Program: Invalid argument
g++: error: Files\Common: No such file or directory
g++: error: Files\Microsoft: No such file or directory
g++: error: Shared\Windows: No such file or directory
g++: error: Live;C:\Program: Invalid argument
g++: error: Files: No such file or directory
g++: error: (x86)\Common: No such file or directory
g++: error: Files\Microsoft: No such file or directory
g++: error: Shared\Windows: No such file or directory
g++: error: Live;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\INTEL\ICLS: No such file or directory
g++: error: CLIENT\;C:\PROGRAM: Invalid argument
g++: error: FILES\INTEL\ICLS: No such file or directory
g++: error: CLIENT\;C:\PROGRAM: Invalid argument
g++: error: FILES\BROADCOM\BROADCOM: No such file or directory
g++: error: 802.11: No such file or directory
g++: error: NETWORK: No such file or directory
g++: error: ADAPTER;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\MICROSOFT: No such file or directory
g++: error: DIRECTX: No such file or directory
g++: error: SDK: No such file or directory
g++: error: (AUGUST: No such file or directory
g++: error: 2007)\UTILITIES\BIN\X86;C:\Windows\SYSTEM32;C:\Windows;C:\Windows\SYSTEM32\WBEM;C:\Windows\SYSTEM32\WINDOWSPOWERSHELL\V1.0\;;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\QUICKTIME\QTSYSTEM\;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\INTEL\OPENCL: No such file or directory
g++: error: SDK\2.0\BIN\X86;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\INTEL\OPENCL: No such file or directory
g++: error: SDK\2.0\BIN\X64;C:\PROGRAM: Invalid argument
g++: error: FILES\INTEL\INTEL(R): No such file or directory
g++: error: MANAGEMENT: No such file or directory
g++: error: ENGINE: No such file or directory
g++: error: COMPONENTS\DAL;C:\PROGRAM: Invalid argument
g++: error: FILES\INTEL\INTEL(R): No such file or directory
g++: error: MANAGEMENT: No such file or directory
g++: error: ENGINE: No such file or directory
g++: error: COMPONENTS\IPT;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\INTEL\INTEL(R): No such file or directory
g++: error: MANAGEMENT: No such file or directory
g++: error: ENGINE: No such file or directory
g++: error: COMPONENTS\DAL;C:\PROGRAM: Invalid argument
g++: error: FILES: No such file or directory
g++: error: (X86)\INTEL\INTEL(R): No such file or directory
g++: error: MANAGEMENT: No such file or directory
g++: error: ENGINE: No such file or directory
g++: error: COMPONENTS\IPT;C:\Program: Invalid argument
g++: error: Files\WIDCOMM\Bluetooth: No such file or directory
g++: error: Software\;C:\Program: Invalid argument
g++: error: Files\WIDCOMM\Bluetooth: No such file or directory
g++: error: Software\syswow64;C:\Program: Invalid argument
g++: error: Files: No such file or directory
g++: error: (x86)\Windows: No such file or directory
g++: error: Live\Shared;C:\Program: Invalid argument
g++: error: Files: No such file or directory
g++: error: (x86)\CodeLite;;C:\MinGW-4.6.1\bin: Invalid argument
mingw32-make[1]: *** [/main.o.d] Error 1
mingw32-make.exe: *** [All] Error 2
mingw32-make[1]: Leaving directory `C:/Users/Alan/My Documents/cs102/Filestream'
----------Build Ended----------
0 errors, 0 warnings
I'm not really sure why it's accessing system files, but I'm pretty sure that it's not supposed to do that...
Re: Can't remove unrecognized compiler option
Posted: Wed Oct 24, 2012 10:21 pm
by ctrl
Nevermind, I figured it out. In an earlier attempt to fix it, I had gone to Build Settings-->Compilers-->Advanced and changed the global include path. It was supposed to be blank, so I changed it and it works now. Thanks for the help!