10

I upgraded Ubuntu 14.02 to Ubuntu 16.04 and realized that NetBeans was no longer working after the upgrade. So I installed netbeans again from the command line:

sudo apt install netbeans

But after the installation, when I opened NetBeans, it was still not giving me the option for making a C/C++ project.

no C option

Can anybody please help with this problem?

4 Answers4

18

The answer provided by https://askubuntu.com/users/22949/eliah-kagan did not work for Ubuntu 19.04 with NetBeans 11 since the C++ plugin is not available under "Netbeans Distribution" when I tried it.

To install C++, I also had to select the Update Center labeled "NetBeans 8.2 Plugin Portal". It appears that C++ is not in the latest distribution yet, so I had add the legacy Update Center. enter image description here

After adding this update center, I was able to locate and install the C++ plugin as shown in the previous answer, and then create a C++ HelloWorld program in NetBeans 11 on Ubuntu 19.04 enter image description here

ScottK
  • 291
  • 2
  • 9
9

Install the C/C++ plugin in NetBeans.

In NetBeans, go to ToolsPlugins.

Then in Available Plugins, in the C/C++ category, check the box for C/C++, then click Install to start the installation.

Source: Enabling C/C++/Fortran in the IDE


If no update centers are enabled in NetBeans for installing and updating plugins, then you may see a completely empty list under Available Plugins. (Less commonly, if some are enabled but they do not provide the C/C++ plugin, then you may see some plugins but not that one.)

The Plugins dialog box, Available Plugins tab, listing no plugins at all.

The solution is to go to the Settings tab, look in the list of Update Centers, and check the box for NetBeans Distribution.

Selecting NetBeans Distribution in Update Centers in the Settings tab.

Then you can go back to the Available Plugins tab and the C/C++ plugin should be listed. You may have to click the Check for Newest button (though I didn't have to).

enter image description here

Eliah Kagan
  • 119,640
2

I had a similar problem, the Netbean Docs didn't help because there was no C/C++ option in the
Tools --> Plugins --> Available Plugins section to work from.

This video: Adding C/C++ Plugins to Netbeans on Mac/PC/Linux solved it. Steps below:

From the NetBeans Header Menu:

  • Click --> Tools
  • Click --> Plugins
  • The Plugins window will open. In the Plugins window --> select the Settings tab.
  • Click on the button marked Add
  • In the Name Field enter: NetBeans Distribution
  • In the URL field enter the following URL: http://updates.netbeans.org/netbeans/updates/8.2/uc/final/distribution/catalog.xml.gz
  • Click --> OK
  • Click on the Updates tab
  • Click on Check for updates. If there are any updates, select them and click the Update button
  • Click on the Available Plugins tab
  • You can now select the plugins you want to install.
  • After installation, they should be in the "Installed" Section under "User Installed Plugins"
  • Close tab
  • Click File --> New Project
  • You should see C/C++ available as an option now.


source

Kelly
  • 623
1

my specs here:
ubuntu 18.04
netbeans 11.3
jdk14.0.1 (from oracle)

First, make it sure you have unpack200 working on the right place:

ls -l `locate unpack200` # the real file was at: /usr/lib/jvm/java-11-openjdk-amd64/bin/unpack200
cd "/usr/lib/jvm/jdk-14.0.1/bin" # or to where the error requested unpack200 to be at
sudo ln -vs /usr/lib/jvm/java-11-openjdk-amd64/bin/unpack200 ./

On netbeans > tools > plugins > settings, add this repository "NbDevDarkBeans": http://bits.netbeans.org/dev/nbms-and-javadoc/lastSuccessfulBuild/artifact/nbbuild/nbms/updates.xml.gz Click on "check for updates", mark and install "C/C++" will be a newer version than other repositories, here: 1.31.5.1, btw this will also support C++17 projects! Obs.: I got this repository tip from here: https://stackoverflow.com/a/59835093/5648245

VeganEye
  • 161