THIS IS OUR PREFERRED WINDOWS DEVELOPMENT IDE FOR THE RASPBERRY PI
The reason – you program on your nice fast Windows PC but under the bonnet it copies the files and uses the RPi to actually compile the project which, whilst a bit slower than using a high spec PC, solves all the issues of platform architecture, installed libraries, etc. Its a really nice well implemented and pretty damn painless solution! Oh, and single stepping, run to breakpoint, etc, full on debugging just works – thank you NetBeans gods!
Installing NetBeans
At the time or writing installing Netbeans 11 has a few hoops to jump through – there’s no longer an installer and C/C++ support has to be added (it was all fine in netbeans 8 but since loosing Oracle support lots of changes are underway, hopefully will improve in future versions)
Download the latest NetBeans IDE from https://netbeans.apache.org/download/
There is no installer provided for the new apache version of netbeans (at the time of writing) so select the “binaries” version, save it somewhere. To run it double click the file “netbeans-install-directory\bin\netbeans64.exe”.
You will also need the Java SE Development Kit (JDK) (the Java Runtime Environment (JRE) is not enough). Netbeans needs Jave SE / JDK to be installed in order to function.
Getting C/C++ support working
C/CC++ has been removed in netbeans 10.0 and 11.0 but is scheduled to be re-introduced in netbeans 12.00. Its down to a donation phase of work in the transition from Oracle. However it can easily be added into V10.0 and V11.0.
Menu > Tools > Plugins > Settings tab > Add button. Then on the Update Center Customizer screen:
- Name: Enter something (e.g. “My added plugins”)
- URL: http://updates.netbeans.org/netbeans/updates/8.2/uc/final/distribution/catalog.xml.gz
Click OK
You’ll now have a new entry in the “Configuration of Update Centers”. Ensure it is checked.
Now go to the “Available Plugins” tab and you will see “C/C++” has been added. Select it and press “Install”
NetBeans New Install Configuration
The following are options we like to use to make netbeans behave like other IDE’s we use and to correct things we find annoying.
Turning Off Expand Tabs To Spaces setting
Menu > Tools > Options > Editor > Formatting tab
Select ‘All Languages’ and Category ‘Tabs And Indents’
Turn off ‘Expand Tabs to Spaces’
Set ‘Tab Size’ to 4
Press ‘Apply’
Changing To Uppercase to SHIFT+CTRL+U
Menu > Tools > Options > Keymap > To Uppercase, then select Add Alternative
Menu > Tools > Options > Keymap > To Lowercase, then select Add Alternative
Making The Editor Work As Well As Possible
Tools > Options > Editor > General > Enable Camel Case Navigation = Off
Tools > Options > Editor > Code Completion > Insert Single Proposals Automatically = Off
Tools > Options > Editor > Code Completion > Insert Closing Brackets Automatically = Off
Tools > Options > Editor > Formatting > Language: (do for “C”, “C++” and “C/C++ Header”) >
Indents > # at Start Line = Off
Indents > Indent Case Statements = Off
Braces Placement = Set all to new line
Other > Add Leading Star In Comments = Off
Turning off the grey lines that are shown for intents: Main Menu > View > Show Indent Guide Lines > turn off
Stopping scroll wheel zoom issue
Change zoom in and out to
SHIFT + CTRL + Up Arrow/Down Arrow
Misc things
Tools > Options > Appearance > Show full file path
Creating A Project on The RPi
See here.
10 months ago
Hi @Adam,
thanks for your answer.
I found out that it works with version 21 as well. All you have to do is work with JDK11 and take unpack200.exe from the jdk11 directory.
Regards
Kurt
10 months ago
Nice one thanks for the update. We tend to get it working then not update unless we have to, but will update the page next time we’ve a new computer to set up. They release new Netbeans updates fast….!
10 months ago
Hi,thank you very much for this guide. Unfortunately, this is only for an earlier version (I couldn’t find out which one). Since as with many other applications, something is constantly changing, it is no longer comprehensible for me how to install and configure the current or a newer NetBean IDE. I would like to do remote development for a raspberry0. Netbeans should run on a Windows PC. Has anyone ever given NetBeans a run lately?
10 months ago
Works fine for us with Netbeans 11.0
7 years ago
does this apply to building software/modules on github ?
7 years ago
I am a bit confused the whether both my Mac and my pi3 have to have netbeans C/C++ installed?Thanks
7 years ago
Just your mac/pc
8 years ago
Hi
I tried to run NetBeans on RPI 3 B and got the following error:
Configuring the installer…
Searching for JVM on the system…
Preparing bundled JVM …
/tmp/.nbi-5064746.tmp/jre-8u101-linux-x64.bin: 1: /tmp/.nbi-5064746.tmp/jre-8u101-linux-x64.bin: Syntax error: “)” unexpected
Cannot prepare bundled JVM to run the installer.
Most probably the bundled JVM is not compatible with the current platform.
See FAQ at http://wiki.netbeans.org/FaqUnableToPrepareBundledJdk for more information.
7 years ago
most distro’s for pie are 32 bit even if the processor is 64 bit. A 64 bit os would not help much on it as it only has 1 gig memory… try the 32 bit version
7 years ago
Thanks Jimmy.
That is a eye opener for me…
The programming domain is a bit new for me. :)
Thanks again.
Regards
Adriaan
9 years ago
When I try to build the project I obtain this error: “Can not check remote directories. xargs exited with error code 123”. Help me please!
9 years ago
Great as far as you went. But how do we setup NetBeans to work remotely with the RaspberryPi?
9 years ago
https://raspberry-projects.com/pi/programming-in-c/compilers-and-ides/netbeans-windows/creating-a-new-project