correct removal of unnecessary perl libraries