Corrected test for equality of definitions for packages.