Seapegasus Blog

All | Hacks | Java Mobility | Mac | Misc | NetBeans | NetBeans_de
« Previous day (Dec 13, 2007) | Main | Next day (Dec 15, 2007) »
20071214 Friday December 14, 2007

JDKs for MacOS?

Yesterday, Apple released a JDK update! :-)
... for JDK4 and JDK5. *sigh* :-[

Let's hope the update does something useful. The "more info" link offered by the Software Updater in the German locale was a 404. I searched the Apple support center and only came up with this English info page (which alas doesn't contain more info, but repeats what I already knew, "it's an update").

Also this week, Apple felt compelled to release a little article about Java and Mac OS 10.5 (Leopard). Don't hold your breath. As much as I appreciate Apple improving their Java profiler, and adding support for 64-bit apps, yadda yadda, it's still a pity the whole article says no word about the Apple JDK 6. *sigh* It doesn't even contain the number 6. *SIGH* (Although it contains the digit 6. I checked.)

I still have the JDK 6 Dev Preview released by the Apple Dev connection (a download which seems now gone from the ADC.) Why does Apple develop their own JDK? They do it so they can add these guys to it. (Why they do it so slowly, I don't know.) If you want to know what Java on the Mac looks like without those typical controls, have a look at this BSD port of JDK6 for Mac OS 10.4 and 10.5: Soy Latte JDK 6.

You can download SoyLatte into any directory you like, then expand it (I used bunzip2 soylatte16-i386-1.0.tar.bz2 and tar -xf soylatte16-i386-1.0.tar in the Terminal), and then symlink to it from /System/Library/Frameworks/JavaVM.framework/Versions/1.6/Home, so NetBeans can find and identify it as a JDK in the Java Platform manager. Afterwards don't forget to go to the properties of the project you want to use it with, and switch it to use the SoyLatte Java platform.

It seems to make sense to place SoyLatte in the /sw/ directory, but if you save it to a directory in your home dir instead, then you can compile and run the demos and samples that come with it as normal user. I do have X11 installed, but I haven't figured out how I can make NetBeans run the demos directly in X11, although it readily recogizes the projects as netbeans projects. (If you figured it out, leave a comment.) If I run the samples from the commandline in the X11 terminal, they don't look pretty ;-) (as expected), but they work well.

In case you like SoyLatte so much that you want to get rid of the developer preview jdk, read Joshy's blog.

PS: Two people asked recently, so if you don't know either how to set up the javadoc popups in netbeans, here's an 'F'AQ answer to you.

Posted by seapegasus ( Dec 14 2007, 07:03:47 PM CET ) Permalink Comments [1]


Weihnachtsgeschenk fuer NetBeans-Fan gesucht?

Wie Ihr wisst, gibt es ja schon schon ziemlich viele NetBeans-Bücher auf Englisch und anderen Sprachen. Und wie steht es mit deutschsprachiger Literatur? Hier ein kleiner Überblick:

Wow, nette Sammlung! Hoffe ich habe keines vergessen. Also, falls Ihr Euch noch was zu Weihnachten wünschen wollt... :-)

Posted by seapegasus ( Dec 14 2007, 06:49:22 PM CET ) Permalink


Solaris vs MacBook

During the Sun Tech days in Frankfurt, I discovered a Solaris Installfest booth. Shortly before the end of the last session, I showed up with a Mac Book pro and Parallels Desktop, and asked for a Solaris disk... >:-D The guy said, "Sure... go ahead!"

So I created a virtual machine for Solaris 11 and inserted the DVD. I had to hit the (virtual machine's) reboot button two or three times until Parallels won the fight and tore control over the DVD drive from the iron grasp of MacOS. Or something.

Anyway, I was positively surprised how slim the Solaris installer looked. No clicking through 32 pages to set up drivers. It's almost like MacOS, it asks for your time zone and locale etc, and figures out the rest.

Unfortunately, installation of 7 Gigs of software took longer than I expected. Everybody was leaving (see photo)... They switched off the network, and then the lights... And I was only 49% done. I had to go to the airport, I could not wait another hour in the conference center for the installation to complete. Well I thought, I know now that it works, so I'll just close the MacBook (to put it in sleep mode) and reinstall Solaris on Thursday. It's a pity to have to delete the half-finished VM and lose this one hour, but actually no big deal.

So on Thursday, back in the office, I woke up the MacBook, expecting a broken VM with a broken (interrupted) Solaris installation to greet me. Nothing of that sort! MacOS had sorted it out, the installer hadn't even noticed the day-long interruption. It simply continued where it had been, and completed the installation. :-o I don't know whether I was just lucky, or whether it's meant to be like that. Anyway, Solaris runs in the MacBook's VM!

There is only one problem: Parallels does not allow direct write access to the virtual Solaris partition, and seemingly it cannot offer Solaris a recognizable default network device. What, no MacBook drivers? ;-) Here is a solution I found in moazam's blog: Parallels comes with extra drivers for this purpose, you just have to know where to find them.

  1. In MacOS, mount the file /Library/Parallels/Tools/vmtools.iso (in the Parallels menu, "Devices > CD/CVD > Connect Image")
  2. In Solaris, read the Readme and then execute /media/PRLTOOLS/Drivers/Network/RTL8029/SOLARIS/network.sh in the Terminal (as root!)
  3. Reboot Solaris (i.e. the VM)

One tip: The "Connect image" (mount) command is a very useful work-around to get data from MacOS into Parallel's VM! Your image will show up in Solaris' /media/ directory.

Another tip: Same as in MacOS, you can drag and drop files and folders from Nautilus into the Terminal, and it will spell out their paths. E.g. type "cd " into the Terminal, drag a folder onto the Terminal window, and it will complete to "cd '/path/to/whatever/directory/'".

PS: How did I manage to save this as draft and not post it all week?

Posted by seapegasus ( Dec 14 2007, 02:19:08 PM CET ) Permalink


Calendar

Content

Search

Links

RSS Feeds

Recent...