Check for gcc 4.8 and fix boost linking on Debian