G++

hey, I want to know the best G++ compiler for windows and a link to the download please. Thanks for the help!
Well, my problem is that when I use PUTTY on my computer and I try to access another computer using SSH, I get this error. I would assume it's because of my compiler. What can I do to fix this?

[xxx@cycle4 ~]$ gedit exchangeSort.cpp
cannot open display:
Run 'gedit --help' to see a full list of available command line options.
putty doesnt support GUI..

for that you need to use reflectionX or something like that. google ReflectionX

you can download g++ from
www.gnu.org
, compile it on windows and use it.
You need to use X11 port forwarding so that the gedit program can use your computer's display. http://e.molioner.dk/guides/puttyx11

If you are on Windows (I presume you are since you are using PUTTY), you will also have to start an X display host. I recommend XMing. http://www.straightrunning.com/XmingNotes/

explanation
If you SSh into the other computer, and type

echo $DISPLAY

at the command prompt, you will be informed that the variable either doesn't exist or has a value of zero (or some other invalid value). This is because the other computer sees you as a TTY (a text terminal) as opposed to a GUI system.

All X GUI programs require this variable to have a valid value, so that they can 'talk' to the GUI display.

Once you do that, you should be able to use graphical programs over the X connection.
Keep in mind that the system you are dialing into may have the ports required to do that kind of thing closed. If that is the case, you will have to use a TTY editor. Try one of emacs, vi, or pico.

Hope this helps.

[edit] Yeah... reflectionX is good too... :-)
Last edited on
Gnome edit is a GUI program, use a console-based text editor like nano or vim with SSH.
codeblocks is an Ide and it also comes with mingw (if you select download with mingw or something like that) witch has or is a g++ compiler

search codeblocks on google, its the first page
Topic archived. No new replies allowed.