Fixed makefile. Libraries out of order