Kasperian Moving Parts

kinda like Batman, but with a wife and 3 kids

Eclipse versus Netbeans


Now, this one I’m really speaking out of the side of my head on… This is totally based on first impressions of NetBeans, albeit after 3<x<5 hours have been invested in said first impressions…

I’ve been using Eclipse and CDT for a while for my day job at VMware (which, by the by, totally rocks!!!). And for the most part, Eclipse+CDT really does a nice job at helping me maneuver around our very large code base and lowering the learning curve after I’ve figured out how to teach it about include paths that it can’t figure out on its own. As a C++ IDE, it’s very nice, responsive, stable, and it definitely helps in learning the code base via being able to quickly search, view inheritance hierarchies/object references, and quickly take you to definitions/declarations/usages. I had an itch to scratch with VIM keybindings and from what I’ve seen, viPlugin fits the bill very nicely. In fact, I’ve just today broken down and sent off my $21 for the wee beastie.

In response to a previous blog of mine, someone suggested that I look at NetBeans and SunStudio (which is built atop NetBeans) as alternatives to Eclipse as a C++ IDE, so I took some time to learn and explore today. I am definitely impressed with NetBeans in general, and their attention to C++ as a core component (as opposed to Eclipse, which provides C++ as a plugin, albeit a much-more-core plugin than previous). And NetBeans does a much nicer job, imho, in UI clarity as well as getting up and running quickly. Very nice attention to detail, and very good online help. I was up and running with our very large code base in NetBeans almost immediately–orders of magnitude quicker than doing the same thing in Eclipse.

And then I tried to set up NetBeans’ Code Assistance. For 4+ hours, on and off (each iteration took a painfully long time to discover that I’d still not gotten it right). Now… to be fair, it sure seems like NetBeans has some nice sophistication here, and gives you 3 ways of discovering how to construct your code model and code assistance goodness:

  1. Examining a binary (depends on compiling with CFLAGS/CXXFLAGS=”-g3 -gdwarf-2″, iiuc)
  2. Examining a bunch of build output/shared object code (also depends on compiling with CFLAGS/CXXFLAGS=”-g3 -gdwarf-2″, iiuc)
  3. Finding its way through a mess of C/C++ source/header files (this is what Eclipse/CDT does, I think?)

However, try as I might, no matter how I told the code assistance wizard to do its thing, it only ended up finding 31 C (not even C++) files. Needless to say, no code assistance or navigability joy was mine, which makes this fantastic IDE… much less than useful for me, unfortunately.

One other thing that gives Eclipse a thumbs-up here is the Perforce plugin for Eclipse. I don’t think one exists for NetBeans 6.

And I personally much-prefer the speed and good looks of SWT over Swing, which gives Eclipse another ++.

So, all in all, I REALLY do like NetBeans. I will have to poke at it some more later, and would LOVE it (dear LazyWeb) if someone could point me in the right direction to getting Code Assistance working. But for the time being, I think I’ll stick with Eclipse+CDT+VIM keybindings.

Author: Jason 'vanRijn' Kasper

My name is Jason 'vanRijn' Kasper. I am the ring leader of the amazing Kasper family. I am unashamedly a Christian Nerd. These are our stories....


  1. Try disabling Properties -> Code Assistance -> C/C++ compiler -> Preprocessor Definitions.

    The definitions are causing the code assistance not to work in my case.

  2. Pingback: Eclipse versus Netbeans

  3. Interesting. I’m trying just now to figure out how to teach eclipse+CDT about include paths. Will try Netbeans too in a few then as I didn’t know it could make a decent C/C++ IDE. Cheers.

  4. So as I understand the Project explorer doesn’t contain the majority of your source files – is this correct? This might be caused by improper value of the “Source Files” folder in the 4-th page of “New Project” wizard.

  5. I’m one of the Netbeans C/C++ pack developers.

    I’d like to help you with getting code assistance right; but I need to ask you some questions. Could we contact via e-mail?

    (As I understand you are the owner of the site, in this case you know my e-mail – could you send me your a letter then?)

  6. Hi Vladimir!

    No, actually, the project explorer contains all of my source files–it’s just the code assistance that is only finding 31 C files.

    And I’d definitely love the help!! I’ll e-mail you privately right after I hit send here. =:)

  7. There’s a Perforce plugin for Netbeans 6 here:

    It doesn’t seem to support multiple changelists though.

  8. Hi, Jason, Has Vladimir helped you solve the problem?
    I’m using netbeans cpp 6.5.1 and 6.7. It mostly works with a little performance glitch. Just think you should update your page if you have got it work.

  9. Hi Minghua. Actually, no, I never could get it working in NetBeans. I’m using old-school emacs now. =:/

  10. Hi, Jason, Sorry to here that. I’ll post the tricks that worked for me for 6.5.1. There are still some problems with 6.7 but hope they get fixed in 6.7.1 or later.

    The ability to do an accurate tagging is the very valuable feature of Netbeans.

    And thanks to you for spending time to experiment and sharing the result here.

  11. Minghua: I’d be very interested in any information you can share about how to make tagging work better. =:)

  12. Hi, Jason, I posted my experience on Netbeans forum:

    Please see if it could help you.

    I use the make log file approach. It does not have
    to be built with “-g3 -gdwarf-2” flags, but needs
    some filtering of the gcc command lines so that
    netbeans could understand them.

Leave a Reply

Required fields are marked *.


This site uses Akismet to reduce spam. Learn how your comment data is processed.