Convert eclipse into a real Mac-App

I’m using Eclipse for a while now. In the good old days Eclipse has been delivered as a “proper” Mac-App with all libraries contained inside the Application.

But for some time now that is not the case any more. Now an Eclipse for the Mac comes as a folder containing the Application (called Eclipse.app) and a lot of other clutter that i’m not interested in. But when I drag the Eclipse.app into my Application folder and try to start it nothing happens (apart from that nice little Error-Message).

I simply accepted that.

Until today.

Solution

Step one

I opened the Eclipse.app-package by right clicking onto it and selecting ‘Open Package’. That opened a new Finder-Window showing a single folder Contents. Go inside!

There we have

  • a file Info.plist – don’t touch
  • a folder MacOS – we come to that later
  • a folder Resources – leave it as it is

The next thing was to move all the clutter from the folder containing the Eclipse.app (except for the Eclipse.app) into this folder Contents.

Now the folder Contents should look somewhat like this:

Content of Contents
The content of the folder Eclipse.app/Contents

Step two

Now I had to edit the file MacOS/eclipse.ini

Somewhere there are two lines containing something like

--launcher.library
../../../plugins/org.eclipse.equinox.launcher.cocoa.macosx.x86_64_1.1.101.v20120109-1504

By simply removing two of the three ../ I thought everything was fine. But no.

There also have to be two lines like

-startup
../../../plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar

Remove two of the three ../ and be happy. If the line is missing, add it.

So in the End the file should contain four lines like these:

-startup
../plugins/org.eclipse.equinox.launcher_1.2.0.v20110502.jar
--launcher.library
../plugins/org.eclipse.equinox.launcher.cocoa.macosx.x86_64_1.1.101.v20120109-1504

. The exact version-number varies from – well obviously – version to version.

When you are in that file you can also change some Memory values for the Java-VM like the values for -Xms and -Xmx. For more details on that (java heap space memory) ask your favourite search-Engine 😉

That done, you should have a real Mac-Application containing all the stuff needed inside the Eclipse.app.



 
 architectural daughtsman, brother, developer, father, husband, master of forestry sciences, scout


Leave a Reply

Your email address will not be published. Required fields are marked *