Fix box collection sorting with mixed architecture

When the box collection consists of a mix of entries with architecture
information and without architecture information, ensure the values are
a common type so sorting does not result in an error.