Fix build on Linux

Porting the original Debian patch from http://sourceforge.net/p/launchy/patches/32/