Jamaica/OpenJDK on Windows

This week, I got Jamaica with OpenJDK running on Win32 for the first time. Yay!Β  What a stupid system to develop on, though :-/ I wonder, how can any full-time Windows developer stay sane for any longer than a couple of weeks? Ok, maybe the average developer isn’t using Cygwin together with the Visual Studio Toolchain and the autotools to build stuff πŸ˜‰

Time to repent

Some days ago I digged out, what turned to be a long-standing (JDK1.3 days) bug in the JNI specification
. Apparently, it still isn’t fixed. The issue in question is, should GetStringChars() return a zero-terminated string or not? The specification is silent about this, so a sane application developer MUST assume, it is not. A JVM developer is relatively free to return either a zero-terminated jchar array (like Hotspot does, but AFAICS, not always either), or not-zero-terminated jchar array (like a couple of VMs apparently do, like Jamaica, and I think gcj and jamvm too). It is a shame that this issue never has been fixed.

I posted to core-libs-dev@openjdk.java.net about this, and started an interesting little thread. The most hilarious response so far has been:

The developers at Sun found the correct way to interpreting the specification; the other ones followed it blindfolded. It is now time to repent.

Let me also quote Mark from IRC:

I guess it is a special kind of developers who can correctly interpret specs and Sun got them all πŸ™‚

Unfortunately, fixing this on the side of Jamaica would mean relatively drastic changes to the internal string representation OR a very inefficient GetStringChars(). Bah.

Back to Classpath hacking

These days I did finally some more Classpath hacking. The last couple of months, the Classpath project was seemingly undead. That left me in some kind of coding depression πŸ˜‰ But I think that Classpath has it’s own right for existence. There are several reasons why I will continue (and re-energize) my support for this project:

  • The process is completely open for anybody. There are almost no constraints, except for contributors to produce quality code and sign the copyright assignment with the FSF. I understand that it’s necessary for OpenJDK to have a lot of constraints, after all, this is the reference and they have a _much_ broader userbase than Classpath. Also, they don’t seem to believe in free, self-regulating processes, but more in governed, regulated-from-the-top processes.
  • Several projects are using GNU Classpath, and probably will do so for a long time. From the top of my head, there’s GCJ, Kaffe, JamVM, JNode, Jalimo. Cacao has some support for OpenJDK, but this seems very early still.
  • I really have no idea what to hack on OpenJDK. Of course, there’s the occasional bug that I care about, sometimes a fix for something that I come over when trying to intergrate with Jamaica, but that’s pretty much it. It is not really possible for me to add cool new features or something similar, that’s completely caught in complicated processes AFAICS (see above).
  • It’s not really possible to fix bugs quickly, because things are hidden away. Nobody knows what’s already done behind Sun’s walls. Every week or two they throw over code that’s finished, but it’s hard to take part in any development.
  • I believe the Classpath code is slimmer than OpenJDK, and (in my experience) the inter-package-dependencies are not so twisted as in OpenJDK. This seems to make it more suitable for small-footprint and embedded scenarios.
  • Hacking Classpath is so much fun. Even if nobody cares about it, it’s still a satisfying feeling to implement some missing classes here, fix a bug there and be useful for the one user that might be left πŸ˜‰ After all, the ‘Free’ in Classpath means really Free, not the semi-Free of OpenJDK (cool: the code is under a Free license, uncool: most things else is still behind closed doors, and some will surely remain so forever, just because it is OpenJDK and Sun).

In this spirit, I started to implement javax.tools for Classpath. In the next couple of days we try to get back our JAPI pages, that appear to be broken or at least not updated since over a year (ugh). Also, Andrew announced today the creation of another hybrid project called BrandWeg, that combines Classpath with OpenJDK pieces. Kindof like inverse IcedTea. Also, Andrew continued with his JMX implementation which is really cool. Stefan Huehner seems to contribute lots of cleanup patches and Mario works on his sound API. We are not dead yet! Long live Classpath! Yay! πŸ˜‰

Axiom M3 speakers on Super T amp

Last time I wrote about the Super T amp, I had some problems with my old speakers. Well, it turned out that it wasn’t the speakers’ fault. I only had my volume too high on my laptop line out (headphone out infact, this is the problem), driving the amp into distortion. Setting them toΒ  ~70% solved the problem. The improvement from my old amp to the Super T amp with the old speakers already was impressive. But…

Some days after christmas I finally received my new speakers after some smaller problems with the german duty office (Axiom quickly helped out and refunded the ~70€ I payed too much). I quickly wired them to the amp and put on on of the CDs from that Radiohead box I received as present. Gosh! What sound is that? It’s like the band is playing right in my living room πŸ˜‰

During the last 2 weeks I re-listened a couple of albums. The amp/speakers combo really shines in all respects. The sound is super clean, it reproduces perfectly what’s on the disc. It has stompy bass (awesome for such little amp and speakers), and very clear mids and trebles. However, the best feature is probably it’s balancedness. It simply doesn’t get in the way of the music. It has remarkably good drive even for serious rock albums, but where it really shines IMO is quiet acoustic music (like Anouar Brahem, Beck’s ‘Sea Change’ or BjΓΆrks ‘Vespertine’) and well recorded classical music. And listening such multi-layered music like Radiohead is just awesome now. (I mean, even more awesome than it was before πŸ˜‰ ).

Find more good reviews of the amp here and here, and for the speakers here, here and here. Short version: you can’t do anything wrong for the <$500 that this setup costs. It delivers audiophile sound reproduction at a fraction of what you’d pay for comparable high-end equipment.

On a side note, I wasn’t lucky enough to get tickets for neither Neil Young nor Radiohead in Europe. Well, that saved me some serious money (~130€ for Neil and ~50€ for Radiohead). I spent this on the Radiohead ‘In Rainbows’ disc box before they are sold out too…