map -package:base -package:base-compat-batteries -package:basement is:exact package:foldl

Fold pairs into a map.