SlickEdit Community

General => Community Forum => Topic started by: rlaa on October 28, 2009, 02:53:02 pm

Title: VisualSlick with cygwin g++ compiler error
Post by: rlaa on October 28, 2009, 02:53:02 pm
I am getting the following error when I compiled the code with cygwin g++ compiler.

===============================
C:\vslick\win\vs-help>C: & cd C:\vslick\win\vs-help

C:\vslick\win\vs-help>echo VSLICKERRORPATH="C:\vslick\win\vs-help"
VSLICKERRORPATH="C:\vslick\win\vs-help"

C:\vslick\win\vs-help>"C:\Program Files\SlickEditV14.0.2\win\vsbuild" -signal 9009 -command g++ -c  -x c++  -g -o "Debug/samp1.o"  C:/vslick/win/files/samp1.c
VSLICKERRORPATH="C:\vslick\win\vs-help"
g++ -c -x c++ -g -o Debug/samp1.o C:/vslick/win/files/samp1.c
vsbuild: File not found (g++)

C:\vslick\win\vs-help>
======================

Title: Re: VisualSlick with cygwin g++ compiler error
Post by: SlickEdit Support on October 28, 2009, 05:58:53 pm
Try going to Build > GNU C/C++ Options > Compile tab and change "Compiler:" to 'g++-4' (no quotes) instead of the standard 'g++'.  You will need to do the same thing on the link tab.  This is a change in the new Cygwin package, and SlickEdit doesn't not account for it yet. 
Title: Re: VisualSlick with cygwin g++ compiler error
Post by: lowellbro on November 10, 2009, 12:35:00 am
Hey,

I'm having similar difficulties. Here is one error I get.

E:\Slickedit\hi>E: & cd E:\Slickedit\hi

E:\Slickedit\hi>E:\ProgramFiles\SlickEditV14.0.2\win\vsbuild -signal 9009 -command make -f "E:\Slickedit\hi\hi.mak" CFG=Debug
VSLICKERRORPATH="E:\Slickedit\hi"
make -f E:\Slickedit\hi\hi.mak CFG=Debug
g++-3 -c  -v  -g -o "Debug/hi.o"  hi.cpp
/bin/sh: g++-3: command not found
make: *** [Debug/hi.o] Error 127

E:\Slickedit\hi>E: & cd E:\Slickedit\hi

E:\Slickedit\hi>E:\ProgramFiles\SlickEditV14.0.2\win\vsbuild -signal 9009 -command make -f "E:\Slickedit\hi\hi.mak" CFG=Debug
VSLICKERRORPATH="E:\Slickedit\hi"
make -f E:\Slickedit\hi\hi.mak CFG=Debug
g++-4 -c  -v  -g -o "Debug/hi.o"  hi.cpp
/bin/sh: g++-4: command not found
make: *** [Debug/hi.o] Error 127

E:\Slickedit\hi>


I have had slickedit for a little over a week now and have yet to succeed in compiling a simple hello world program. (Note I can compile the same program in Netbeans so I believe all of the cygwin files are in there proper locations.)
Title: Re: VisualSlick with cygwin g++ compiler error
Post by: SlickEdit Support on November 10, 2009, 08:26:31 pm
Confirm the name of g++.  It could be g++, g++-3, or g++-4.  Looks like SlickEdit cannot find g++.
Title: Re: VisualSlick with cygwin g++ compiler error
Post by: DaveyC on November 11, 2009, 12:25:50 am
cygwin/bin contains a shortcut called g++.exe but for some reason it's not found when issuing the command from a shell. Is that
normal behaviour for windows shortcuts?
Title: Re: VisualSlick with cygwin g++ compiler error
Post by: lowellbro on November 12, 2009, 02:44:28 pm
cygwin/bin contains "g++.exe" shortcut (This shortcut links to other shortcuts that eventually link to "g++-3" application which is located in the cygwin/bin folder.) "g++-4" application is also located in the cygwin/bin.

originally the path of "g++.exe" shortcut did not it exist in right click->properties->Target:.  The path did show up in right click->properties->Comments: /etc/alternatives/g++. I created a new "g++.exe" shortcut and put the path /etc/alternatives/g++ in the Target: field. This seems to have had no effect.
Title: Re: VisualSlick with cygwin g++ compiler error
Post by: lowellbro on November 16, 2009, 09:01:41 pm
Solution to my errors.
1.) make sure path to cygwin is set in PATH. in windows do Control Panel --> System --> Advanced --> Environment Variables --> System Variables --> Edit --> Path    then add C:\cygwin\usr\local\bin;c:\cygwin\bin;
2.) change g++ to g++-3 or g++-4 in the make file as mentioned above. Or rename either g++-3 or g++-4 applications located in C:\cygwin\bin to g++