add support in get_software_libdir to only retain library subdirs with certain files