The Genocide¹ and apartheid² conventions both have withdrawal clauses
https://en.m.wikipedia.org/wiki/Genocide_Convention¹
https://en.m.wikipedia.org/wiki/Apartheid_Convention²
same for the statute of the international criminal court
meanwhile the responsibility to protect declarations that enable military interventions are subject to vetos by the permanent members from time to time
taking all this in account are crimes against humanity ever preventable or punishable by international law effectively ?