President Obama said he welcomes indications that the Supreme Court may rule that same-sex couples have the constitutional right to marry.

"My sense is that the Supreme Court is about to make a shift, one that I welcome, which is to recognize that — having hit a critical mass of states that have recognized same-sex marriage — it doesn’t make sense for us to now have this patchwork system," Obama said in an interview Tuesday with BuzzFeed News. "“It’s time to recognize that under the equal protection clause of the United States Constitution, same-sex couples should have the same rights as anybody else.”

Obama's comments came the day after Alabama plunged into judicial uncertainty when dozens of counties refused to comply with a federal judge's order striking down a ban on same-sex marriage in the state. The judge, Callie V.S. Granade, will hold a hearing Thursday on whether officials should be required to marry same-sex couples. According to the Human Rights Campaign as of Tuesday night officials in 41 of Alabama's 67 counties refused to issue marriage licenses to same-sex couples. Roy Moore, the chief justice of the state supreme court, told local officials to ignore the federal ruling.

Moore erected a two-and-a-half ton monument of the Ten Commandments in the Alabama Judicial Building that a federal appeals court ordered removed in 2003. Moore did not comply with the ruling and was removed from the bench in 2003. He reclaimed the seat more than a decade later.

Obama recalled that Moore had a "similar problem" with the idea that he couldn't "put a huge Ten Commandments statue in the middle of your courthouse" but that ultimately federal law was obeyed. 

"I think that the same thing will end up happening here,” Obama told BuzzFeed. “I think that the courts at the federal level will have something to say to him.”

The Web site asked whether the issue could be compared to Alabama's civil rights history and Gov. George Wallace blocking the door at the University of Alabama to prevent integration. The president said the comparison is not exact, but the same legal principle is involved.

“I won’t say it’s a perfect analogy, but there’s a core principle here that’s at stake, which is we have a supremacy clause in our Constitution,” Obama said. “When federal law is in conflict with state law, federal law wins out.”