JonBlog
Thoughts on website ideas, PHP and other tech topics, plus going car-free
NetBeans won’t start on Mac with apostrophes in the path
Categories: Mac

This week I started a new job, which came with a nice shiny new MacBook Pro – running OS X. I’m brand new to this platform, and whilst I prefer the openness of Linux, the Mac appears to just work. It’s flawless with wifi, mobile internet, secondary monitors – everything I’ve thrown at it. Meanwhile at home, Ubuntu and Ubuntu Netbook Remix (both Lucid Lynx) often drop wireless connections to my G and N routers, whilst the Mac hasn’t yet dropped a connection. My main laptop (running the full version of Ubuntu) will detect my Hanns-G HD monitor, but there is a full-screen flicker every so often; on the Mac it’s perfect. On the netbook (using Remix) there are desktop lockups that last for 15 seconds or so.

So hats off to Apple for making a highly stable platform, though I’ll still be rooting for Linux to catch up. To be fair, it’s hardly a fair comparison  – Linux needs to run on hundreds of thousands of different hardware configurations, and it’s not possible to test on more than a few of these. Apple meanwhile can test all their target platforms, and there’s just a handful of them.

Anyway the point of this post (!) is to note a bug with NetBeans on OS X. I’m running versions 9.6.1 and 10.6.3 respectively, though I’m not sure how much they matter. Java as reported at the shell is version 1.6.0_17. I’ve found that if the NetBeans executable is in a path containing an apostrophe, it pops up in the dock and then dies quickly – regardless of whether it’s started from the dock or the CLI. This is the syslog that results:

Sep 22 21:15:11 milly [0x0-0xc80c8].org.netbeans.ide.baseide.201007282301[27915]: /Applications/Jon's stuff/NetBeans 6.9.1.app/Contents/MacOS/../Resources/NetBeans/bin/../platform/lib/nbexec: eval: line 535: unexpected EOF while looking for matching `''<br /><br />
Sep 22 21:15:11 milly [0x0-0xc80c8].org.netbeans.ide.baseide.201007282301[27915]: /Applications/Jon's stuff/NetBeans 6.9.1.app/Contents/MacOS/../Resources/NetBeans/bin/../platform/lib/nbexec: eval: line 536: syntax error: unexpected end of file

In the short term, the solution is to move the application to a path that doesn’t contain the offending character. I will file a bug with the NetBeans team in due course.

Update: bug filed.

Update 10 Nov: the Netbeans team won’t fix; sigh. But the ticket is high up in Scroogle results, so at least other folks should find a fix quickly. ‘Tis an edge case, I know.

Leave a Reply