Useful tricks and tips for Geeks

I’ve encountered a number of SlashDot posts over the past week or so which discuss some of the more useful aspects of several computing tools that I use regularly. I’d commented on the first two individually (Forgotten Unix Tricks and Useful Vim Tricks) but since then, several more have emerged.

So, here are the links to each of them in one post, showing their original titles (not mine):

If someone (not me) were to make these into a book, I reckon it would prove to be quite popular. I know I’d certainly buy a copy.

Installing Emacs on Solaris

I tried to install emacs on a Solaris 10 system earlier today and ran into trouble along the way. It wasn’t anything major but I was not able to find the solution on the web so I’m publishing my comments here.

The Problem

I downloaded, unpacked and installed the emacs binaries (version 22.0.91) as well as all specified dependencies from sunfreeware.com but when I tried to run emacs from the command-line after installling, I got the following error:

ld.so.1: emacs: fatal: /usr/local/lib/libpng.so.3: wrong ELF class: ELFCLASS64

It turns out that the latest version of the libpng library (1.2.21) was built as 64-bit library but all of the other dependencies of emacs that I downloaded (including emacs itself) were built as 32-bit files. Naturally, a 32-bit application cannot load a 64-bit library and thus the error above.

The Solution

The solution was as simple as reverting to an earlier version of the libpng library (1.2.20) which seems to have been built in 32-bit. I was able to download this from ftp://ftp.sunfreeware.com/pub/freeware/sparc/10