Fix order of library flags in Makefile. (Not sure how this didn't come up before...)