This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Configuration: On Windows, Tools|Options|C/C++|Build Tools Base Directory: C:\prog\MinGW\bin C Compiler: C:\prog\MinGW\bin\gcc.exe C++ Compiler: C:\prog\MinGW\bin\g++.exe Make Command: C:\prog\MinGW\msys\1.0\bin\make.exe Debugger Command: C:\prog\MinGW\bin\gdb.exe Tools|Options|C/C++|Other File Type(MIME) : File Extensions C++ File: C, c++, cc, cpp, cxx, mm C File: c, cpp, i, m How to reproduce Create a new C/C++ Application project. Select main file type to be created C++. This generates main.cpp. Close the project. Create a new C/C++ Application project project2. Uncheck "Create main File" Create a directory src in the project root. Copy main.cpp from project1 into it. Ad existing item src/main.cpp Clean and build Result: gcc -c -g -MMD -MP -MF "build/Debug/MinGW-Windows/src/main.o.d" -o build/Debug/MinGW-Windows/src/main.o src/main.cpp Issue 1) is that the wrong compiler is used for a .cpp file Issue 2) (for me) is that I cannot change the compiler to match the file. After exploring options, I cannot see how NetBeans can guess the compiler from the file extension because cpp is used for both C File and C++ File. So that leaves the question how a project can be reconfigured from using gcc to using g++.
Sorry, I failed to notice that the compiler can be configured per file.