Makefile and library housekeeping