Sort the cache, making the manifest deterministic given the same resources