Removing excess libraries