Quick history lesson, since you seem to be at a knowledge loss. The Constitution specifically protected slavery:
Article 1, Section 9, Clause 1, "The Migration or Importation of such Persons as any of the States now existing shall think proper to admit, shall not be prohibited by the Congress prior to the Year one thousand eight hundred and eight, but a Tax or duty may be imposed on such Importation, not exceeding ten dollars for each Person"
Slavery lasted for nearly a century under Constutional protection, and by your own logic, all of that enslavement was justified by mere existence of said document. Your position is ridiculous, untenable, and defies all logic or reason. Moreover, a war occurred in order to bring about the institution's end. Not the Supreme Court. War.