Fix bug in Makefile that causes linking to fail