Again a more generic fix for #438

now:
1/ we discard packages with cyclic dependencies
2/ we only keep the package P_k (name = P, version = k) iff reverse-deps(P_k) = U reverse-deps(P_j) for all other version j of P.