hi can anyone suggest me where ro download a GNU c++ compiler, which i can use in ubuntu and also on windows with Netbeans IDE. and also GNU tools.
What about using GCC ?
Quoting it's homepage :
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Java, and Ada, as well as libraries for these languages (libstdc++, libgcj,...).
It will definitly work on Ubuntu ; it's even provided through the package system (sorry, my system is in french) :
$ apt-cache show g++
Package: g++
...
Description-fr: Compilateur C++ du projet GNU
Le compilateur C++ du projet GNU. Un compilateur C++ relativement portable
et capable de bonnes optimisations.
For informations about Windows support, you can have a look at : http://gcc.gnu.org/install/specific.html#windows
Something like MinGW or Cygwin will probably do :-)
Quoting MinGW's homepage :
MinGW, a contraction of "Minimalist GNU for Windows", is a port of the GNU Compiler Collection (GCC), and GNU Binutils, for use in the development of native Microsoft Windows applications.
For netbeans, I can't tell : I don't use it -- not for C++, at least...
Getting everything you need on Debian/Ubuntu is very easy:
sudo apt-get install build-essential
If you are using any Linux/Unix/Solaris OS it is available unless you have explicitly not installed. That said, if you still wish to install GNU C++ compiler, use this command
sudo aptitude install build-essential
and if you wish to download it on your windows, steps are here on Minimalist GNU for Windows