Use an environment variable for Codelite development paths

Discussion about CodeLite development process and patches
sdolim
CodeLite Veteran
Posts: 69
Joined: Fri Oct 24, 2008 10:29 pm
Contact:

Re: Use an environment variable for Codelite development paths

Post by sdolim »

coder99 wrote:

Code: Select all

----------Building project:[ clTest - Debug ]----------
g++ -c  "C:/Program Files/CodeLite-n/clTest/cltest_app.cpp" -g -mthreads -DHAVE_W32API_H -D__WXMSW__ -D__WXDEBUG__ -D_UNICODE -IC:\wxWidgets-2.8.9-n\lib\gcc_dll\mswud -IC:\wxWidgets-2.8.9-n\include -DWXUSINGDLL -Wno-ctor-dtor-privacy -pipe -fmessage-length=0    -D__WX__  -o ./Debug/cltest_app.o
In file included from C:/Program Files/CodeLite-n/clTest/cltest_app.cpp:1:
C:/Program Files/CodeLite-n/clTest/cltest_app.h:4:20: wx/app.h: No such file or directory 
Do you have msys installed? If so, this might help:

I had trouble with the -IC:\wxWidgets... flag until I added SHELL=cmd to my environment variables. It seems that "make" will try to use "sh" to execute commands unless you override it by setting SHELL. And sh doesn't like backslashes as path separators. That's why g++ can't find the header files.
coder99
CodeLite Expert
Posts: 167
Joined: Wed Oct 22, 2008 6:50 am
Contact:

Re: Use an environment variable for Codelite development paths

Post by coder99 »

Thank you for the comment; it might be applicable in my case.

Is that SHELL= the WinXP cmd.exe??
---- edit --

defining
SHELL=cmd.exe
resolved this problem for me..

I will make it a part of my defaults.
Last edited by coder99 on Sat Nov 15, 2008 11:38 pm, edited 1 time in total.

Win 10/11 64-bit, MSVC 2019/2022, wxWidgets 3.2.1, CodeLite 17.0 Mint 21.2

coder99
CodeLite Expert
Posts: 167
Joined: Wed Oct 22, 2008 6:50 am
Contact:

Re: Use an environment variable for Codelite development paths

Post by coder99 »

I have now re-installed CL, repeated the creation of the wxWidget GUI test app and I get the same error; but when I define SHELL=cmd.exeit all works as advertised :-)

Win 10/11 64-bit, MSVC 2019/2022, wxWidgets 3.2.1, CodeLite 17.0 Mint 21.2

User avatar
eranif
CodeLite Plugin
Posts: 6367
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Use an environment variable for Codelite development paths

Post by eranif »

coder99 wrote:I have now re-installed CL, repeated the creation of the wxWidget GUI test app and I get the same error; but when I define SHELL=cmd.exeit all works as advertised :-)
You should really mention that you are using MSYS next time...

Eran
Make sure you have read the HOW TO POST thread
sdolim
CodeLite Veteran
Posts: 69
Joined: Fri Oct 24, 2008 10:29 pm
Contact:

Re: Use an environment variable for Codelite development paths

Post by sdolim »

coder99 wrote:Is that SHELL= the WinXP cmd.exe??
Yes. I just set SHELL to "cmd" (no .exe needed) in CL's Environment Variables.
User avatar
eranif
CodeLite Plugin
Posts: 6367
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Use an environment variable for Codelite development paths

Post by eranif »

sdolim wrote:Yes. I just set SHELL to "cmd" (no .exe needed) in CL's Environment Variables.
He already fixed his problem :D
Eran
Make sure you have read the HOW TO POST thread
coder99
CodeLite Expert
Posts: 167
Joined: Wed Oct 22, 2008 6:50 am
Contact:

Re: Use an environment variable for Codelite development paths

Post by coder99 »

I was unaware that I was using MSYS;
it has been installed some time ago for use with Eclipse IIRC, but I certainly did not use it intentionally.

Win 10/11 64-bit, MSVC 2019/2022, wxWidgets 3.2.1, CodeLite 17.0 Mint 21.2

User avatar
eranif
CodeLite Plugin
Posts: 6367
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Use an environment variable for Codelite development paths

Post by eranif »

coder99 wrote:but I certainly did not use it intentionally
I know, thats the problem when using eclipse :D
Eran
Make sure you have read the HOW TO POST thread
coder99
CodeLite Expert
Posts: 167
Joined: Wed Oct 22, 2008 6:50 am
Contact:

Re: Use an environment variable for Codelite development paths

Post by coder99 »

FWIW, the reason I went looking for alternatives was Eclipse ;-)

and found Codelite :-)

But seriously, if this is a problem, is there a way to check for it at installation time or perhaps simply set the SHELL environment variable by default?

Win 10/11 64-bit, MSVC 2019/2022, wxWidgets 3.2.1, CodeLite 17.0 Mint 21.2

User avatar
eranif
CodeLite Plugin
Posts: 6367
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Use an environment variable for Codelite development paths

Post by eranif »

To tell you the truth, I wasnt even aware of this environment variable until Scott point it out... so this one is new for me like for you

Eran
Make sure you have read the HOW TO POST thread
Post Reply