Mar 25

Installing Java 1.5 on Mac OS X Panther

Posted by James Netherton | Wednesday 25 March 2009 21:49 PM | In Java, Mac

There is no official support for running / installing Java versions greater than 1.4 on Mac OS X Panther. Here’s how I installed and configured my old Mac Mini G4 OS X Panther machine to run Java 1.5.

1. Download and install Pacifist

2. Download Java 1.5 from the Apple website and run the .dmg file

3. Start Pacifist. Drag the .pkg install file from the mounted Java .dmg file. Select the root of the package hierarchy and click the install button

4. When prompted to overwrite existing files choose ‘Leave Alone’

5. When the installation process has completed you can now set the default Java VM to 1.5. Open a terminal session and run the following:

cd /System/Library/Frameworks/JavaVM.framework/Versions
sudo ln -fhsv 1.5 CurrentJDK

Confirm that everything has worked by executing java -version from the command line.

7 Comments

[Post comment]


1

Posted by Brian Mauter | Friday 22 May 1:50 AM

Dude, you rock! I host my website on a Panther Mac G4 Mini running Tomcat. My only gripe has been the lack of Java 5. Now I can run Quercus inside Tomcat so I can do JSP and PHP at the same time.


2

Posted by James Netherton | Friday 22 May 6:40 AM

Glad you found it useful :)


3

Posted by Tobias | Thursday 25 June 11:45 AM

Hey, a cool and helpful article, but when I tried it out with a simple Swing-App, I got the following error:

dyld: java Undefined symbols:
/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Libraries/libawt.jnilib undefined reference to _kCTForegroundColorFromContextAttributeName expected to be defined in ApplicationServices
/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Libraries/libawt.jnilib undefined reference to _NSAccessibilityTopLevelUIElementAttribute expected to be defined in Cocoa
/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Libraries/libawt.jnilib undefined reference to _NSAccessibilityInsertionPointLineNumberAttribute expected to be defined in Cocoa
Trace/BPT trap

I’m not an experienced Mac-OS- or Unix-user, so maybe I’m missing something obvious. Can you help me?

thanks in advance
Tobias


4

Posted by James Netherton | Thursday 25 June 12:12 PM

Hi Tobias – I did some reading and it seems Swing ends up being broken by the upgrade to Java 1.5.

Google for “undefined reference to _kCTForegroundColorFromContextAttributeName expected to be defined in ApplicationServices” and you’ll see a lot of dicsussion around Panther, Java 1.5 & Swing.

I don’t think there’s any easy way to get Swing working :(


5

Posted by Tobias | Thursday 25 June 12:44 PM

Wow, that was fast. Thanks a lot for your effort!


6

Posted by Bob | Friday 07 August 17:46 PM

The problem I have is when I get to step 4 (When prompted to overwrite existing files choose ‘Leave Alone’) I click leave alone but it doesn’t do anything it just flashes back to the same window


7

Posted by mao | Monday 08 February 16:10 PM

man, you turned a mac-idiot like me to a super java installer! bless u
mind you i followed all the above for a G4 PowerBook pro 10.4 tiger
thanks a lot!


Leave a comment