New programmer: Build issue

General questions regarding the usage of CodeLite
akii
CodeLite Curious
Posts: 5
Joined: Tue Jul 01, 2014 3:22 pm
Genuine User: Yes
IDE Question: C++
Contact:

New programmer: Build issue

Post by akii » Tue Jul 01, 2014 3:32 pm

Hello
I am new to programming as well as codelite. I installed version6.0, complier MinGW (Codelite-4.8.1) and GNU gdb debugger .

I tried building the simplest possible program as shown below but it shows one error

Code: Select all

#include <iostream>
int main()
{
	cout<<"hello";
	return 0
}
The build output is as follows:

Code: Select all

C:\Windows\system32\cmd.exe /c "mingw32-make -e -f  Makefile"
----------Building project:[ test - Debug ]----------
mingw32-make[1]: Entering directory 'C:/Users/iswerya/Documents/codelite/test'
/usr/bin/sh: Hewlett-Packardbing++.exe: command not found
mingw32-make[1]: *** [Debug/main.cpp.o.d] Error 127
test.mk:96: recipe for target 'Debug/main.cpp.o.d' failed
mingw32-make[1]: Leaving directory 'C:/Users/iswerya/Documents/codelite/test'
mingw32-make: *** [All] Error 2
Makefile:4: recipe for target 'All' failed
1 errors, 0 warnings
Kindly guide me.

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

Re: New programmer: Build issue

Post by eranif » Tue Jul 01, 2014 5:53 pm

You are having the classic problem where there is another g++ on your system (with sh.exe) to fix this, you need to "tell" make to ignore the sh.exe, to do this:

Settings -> Build Settings -> Compilers -> <Your Compiler Name> -> Tools -> MAKE

Your current value is set to:

Code: Select all

mingw32-make -e
Change it to:

Code: Select all

mingw32-make -e SHELL=cmd.exe 
Eran
Make sure you have read the HOW TO POST thread

akii
CodeLite Curious
Posts: 5
Joined: Tue Jul 01, 2014 3:22 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: New programmer: Build issue

Post by akii » Wed Jul 02, 2014 7:50 am

Thank you. I did as you said. but it still shows erroe

C:\Windows\system32\cmd.exe /c "mingw32-make -e SHELL=cmd.exe -e -f Makefile"
"----------Building project:[ test - Debug ]----------"
mingw32-make[1]: Entering directory 'C:/Users/iswerya/Documents/codelite/test'
The system cannot find the path specified.
mingw32-make[1]: *** [Debug/main.cpp.o.d] Error 1
mingw32-make: *** [All] Error 2
test.mk:96: recipe for target 'Debug/main.cpp.o.d' failed
mingw32-make[1]: Leaving directory 'C:/Users/iswerya/Documents/codelite/test'
Makefile:4: recipe for target 'All' failed
1 errors, 0 warnings

I have attached the screenshot of the change that you asked me to make. Please comment.
You do not have the required permissions to view the files attached to this post.

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

Re: New programmer: Build issue

Post by eranif » Wed Jul 02, 2014 9:35 am

Try changing the paths to Windows style paths? (i.e. with volume etc )

So this:

Code: Select all

\Hewlett-Packard\bin\g++.exe
Will become something like:

Code: Select all

C:\Hewlett-Packard\bin\g++.exe
Eran
Make sure you have read the HOW TO POST thread

akii
CodeLite Curious
Posts: 5
Joined: Tue Jul 01, 2014 3:22 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: New programmer: Build issue

Post by akii » Wed Jul 02, 2014 12:32 pm

When i try to change it to
C:\Hewlett-Packard\bin\g++.exe

It goes back to
\Hewlett-Packard\bin\g++.exe
as soon as i change it.

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

Re: New programmer: Build issue

Post by eranif » Wed Jul 02, 2014 1:05 pm

This is fixed in git head. Can you build a new windows version from git?

Eran
Make sure you have read the HOW TO POST thread

akii
CodeLite Curious
Posts: 5
Joined: Tue Jul 01, 2014 3:22 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: New programmer: Build issue

Post by akii » Wed Jul 02, 2014 2:04 pm

Umm I am very new to programming.I do not even understand the terms that you used. Is there any link or manual that I can follow?

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

Re: New programmer: Build issue

Post by eranif » Wed Jul 02, 2014 2:20 pm

akii wrote:Umm I am very new to programming.I do not even understand the terms that you used. Is there any link or manual that I can follow?
I will upload a new installer and will link it here.

Stay tuned
Eran
Make sure you have read the HOW TO POST thread

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

Re: New programmer: Build issue

Post by eranif » Wed Jul 02, 2014 2:42 pm

Try using this codelite:

http://codelite.org/downloads/tmp/codel ... w4.8.1.exe

Once downloaded and installed, let codelite rescan your compilers:

Settings->Build Settings->Compilers->Add Compilers->Scan computer for installed compilers
Accept the suggestions
compilers.png
Eran
You do not have the required permissions to view the files attached to this post.
Make sure you have read the HOW TO POST thread

akii
CodeLite Curious
Posts: 5
Joined: Tue Jul 01, 2014 3:22 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: New programmer: Build issue

Post by akii » Thu Jul 03, 2014 1:16 pm

It still doesnt work.. :|

Post Reply