lewashby 56 Junior Poster
garrett@mint-desktop ~ $ c++ -v
Using built-in specs.
COLLECT_GCC=c++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.6/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.6.3-1ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --enable-plugin --enable-objc-gc --disable-werror --with-arch-32=i686 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) 

Do I have the GNU C++ compiler? If so how do I launch it? If not how do I get it?

Dani AI

Generated

— Yes: the system-side C++ driver is present. The compiler is a command-line tool (invoked as g++ or c++), not a GUI program. You "launch" it by running it on a source file to produce an executable, then run that executable from the shell.

Quick example — create hello.cpp:

#include <iostream>

int main() {
    std::cout << "Hello, world\n";
    return 0;
}

Compile and run:

g++ -std=c++11 -Wall hello.cpp -o hello
./hello

To verify the installed compiler and where it lives, run which g++ and g++ --version. If a compiler were missing on Ubuntu/Mint, install the common build tools (recommended) with:

sudo apt-get update
sudo apt-get install build-essential

That will install g++ plus make and essential headers.

If you need newer C++ features, add the appropriate standard flag (for example -std=c++11 or later) or install a newer toolchain. For general reference see the GCC project and Ubuntu's guidance on development tools at .

Common issues: forgetting #include <iostream>, compiling C++ files as C (make sure file ends in .cpp), or missing build-essential (causes missing headers or linker errors).

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.