Filter out unused parts of lib in makefile for distributability