Add a useful DebugStore

This is usefull for debugging what's being passed through to the store
plugin.
Revert "Revert "Remove redundant build writes""

This reverts commit 8ac9c72f1e6497882136d629292691fa81057b63.
build pkg/lib on make pkg