Comparison shows before and after of Google Earth on Ubuntu with after looking more native.

Earlier today we shared a post on fixing ugly fonts in Google Earth on Ubuntu, a small tweak that makes a big difference to how the app looks on your Linux desktop.

In the comments under that post, reader Daniele80 pointed us in the direction of a related ‘hack’ to make Google Earth look native under Ubuntu.

Emphasis on look since it doesn’t magically rework the interactive atlas’ underlying toolkit, merely match and mimic the look of real GTK apps better.

Be warned: the steps below are not for the fainthearted or inexperienced. If things go wrong – they could – the easiest way to revert will be to uninstall and reinstall Google Earth using the Deb installer available on Google’s website. Insert joke about scorched earth and start again.

With caution out of the window way, let’s begin…

1. Open Nautilus as Root

First, open up a new file manager window as root. This will allow you to edit and delete system files. To do this, open your Terminal app and run the following command:

gksu nautilus /opt/google/earth/free

A new file manager window will appear with a lot of files in it.

2. Remove Files

Next, we need to make Google Earth use the underlying libraries on our system, rather than the ones Google bundles it with. This will make things look less like a Windows 95 throwback and more like something that resembles modern apps.

Delete the following files ONLY:

  • libcurl.so.4
  • libGLU.so.1
  • libnss_mdns4_minimal.so.2
  • libQtCore.so.4
  • libQtGui.so.4
  • libQtNetwork.so.4
  • libQtWebKit.so.4

Don’t close the file manager window yet (but you can wipe the bead of sweat off your brow as the hardest part is now done).

3. Edit the Launcher

Gedit

With its old libraries gone, we need to make sure Google Earth doesn’t freak out when we open it. To do this, edit the app shortcut/launcher. Right click on the googleearth file (in the root nautilus I told you not to close), and choose Edit/Open in Gedit (you can use any text editor).

In the text editor, add the following before the final line:

  • export LD_PRELOAD=libfreeimage.so.3

Remember to hit Save, then hit it again to make sure. You can then close Gedit.

4. Add Required File

To finish things off, download the following file and place it in the /opt/google/earth/free folder. This final critical element is what allows the app to look native on Ubuntu:

[32-bit LINK BROKEN]

Using a 64-bit version of Ubuntu? You have to download the following file in addition to the one above, and place it in the /opt/google/earth/free folder too:

[64-bit LINK BROKEN]

The Result:

A more native looking Google Earth on Ubuntu

All that’s left to do is open up Google Earth and marvel at the difference between its stock look and that you’ve enabled.

Troubleshooting

Google Earth refusing to open after you’ve done this? You can likely fix it by installing some extra packages.

Open a terminal and run:

  • sudo apt-get install libcurl4-openssl-dev libqtwebkit4

Then try again. If you continue to have issues… Well, I did say at the start there was a potential to break things! Just uninstall Google Earth, download the Deb from Google, and reinstall – it may look less pretty, but it will be functional.

groups.google.com via Daniele80