Change equals/ equiv / weakEquiv definition.
Fix several issues