dpkg: Gather information about all installed packages on demand

This eliminates the need for multiple "dpkg-query --show" calls
dpkg: Gather dependency information about all installed packages on demand

This is done using one dpkg-query call
dpkg: Determine primary architecture on initialization

This eliminates the need for multiple "dpkg --print-architecture" calls
dpkg: Determine diversions on demand