The link command on mine btw is: gcc *.o -o content -m32 -L/home/user/dmd2/linux/bin32/../lib32 -Xlinker -- export-dynamic -lpq -lmhash -lcurl -lphobos2 -lpthread -lm -lrt The pq, mhash, and curl libraries are used by my application so you might not need those on your app. This is also a 32 bit program.