The best laid plans of mice and men…

Entries Tagged as 'C'

I’ve been a fan of the NetBeans environment for developing for a long time. Yes, there’s a great deal of resistance to it because it’s not OpenSource (it’s an Oracle sponsored project), but it’s free for Windows, OS-X, and Linux.

Many think NetBeans is only an IDE for Java development. That’s definitely not the case. NetBeans will do Java, HTML5, C/C++, Fortan, Groovy, PHP, and many more (with plug-ins)… and works with both Tomcat and GlassFish (GlassFish is actually bundled with several NetBeans packages — but you do not have to install it if you’re not going to use it).

NetBeans is written in Java, and you need not only a JRE (runtime), but also a JDK (development kit)… on Java.com (also an Oracle project — they purchased Sun) you can download bundles for many operating systems including JRE, JDK, and NetBeans (you can also install them individually).

Getting NetBeans and C/C++ to work on Linux is a snap, you just need your development tools setup before you install / run NetBeans. I’d considered install on Windows pretty straight forward as well, but since I’ve helped two different people get it working in the last week, and several a few months ago I’m going to write a quick list of the steps involved.

While not all of these steps need to be done in the order I’m listing them in, unless you really know what you’re doing (and why would you be reading this if you already know how to make this work), just follow the steps. If you have any problems getting this to work, use my contact page — I definitely want to improve my instructions (no — I’m not going to put screen shots and make it a guide for people who’ve never seen a computer before… it’s a development environment, so I’m working on the premise you either know C/C++ or you’re taking a class in it).

At the end of the article are some links that might help (please search the internet if the links are broken).

Download and install the latest JRE (or the one you’ve been told to if taking a class).

Download and install the latest JDK (or the one you’ve been told to / matches the JRE).

Download and install the latest NetBeans full package (it’s the right most column, if you’re worried about disk space, don’t install GlassFish).

Download and install MinGW in C:\MinGW

Run the mingw-get-setup.exe file and select the C++ compiler, development environment, MSYS
base (we’ll install the rest in the next step).

Download and install MSYS into C:\MinGW\msys\1.0 (watch the navigation pane to insure you don’t get an extra 1.0 in the path). Let the install “normalize” (that’ll remove duplicate copies of tools.

Add the following to the Windows path (you will need admin rights — if you don’t have admin rights then you’ll have to launch NetBeans through a batch file that adds them to the windows path before executing NetBeans).

c:\MinGW\bin

c:\MinGW\MSys\1.0\bin

Launch NetBeans and do the following:

tools->plugins
insure C++ is installed/enabled

tools->preferences->C++
if necessary add the MinGW toolchain and accept defauls (NetBeans should locate all the required components).

Dr Dennis Ritchie, one of the creators of Unix and the inventor of the C language passed away after a long term illness today.

Along with Ken Thompson, Brian Kernighan, Douglas McIlroy, and Joe Ossanna, Dr Ritchie was one of the key creators of the Unix operating system at Bell Labs during the 1960s and 70s.

Also while at Bell Labs, Dr Ritchie created C, one of the most widely used programming languages in the world. It is familiar to almost every modern-day developer and been the basis for additional computer languages.

In 1999, Dr Ritchie’s influence and accomplishments won official notice when he was awarded the US National Medal of Technology – the highest honor America can bestow on a technologist.