The Supreme Court actually just left it up to the states. More than one state supreme court has said it is unconstitutional because it violates their state constitution. All you need to do is get a liberal majority on your state court and then bring them a gerrymandering case. They will make it illegal in your state.
Existing gerrymanders can't affect any state's supreme court makeup. Some states pick supremes by popular vote and some have the governor pick them. And the governor is picked by state-wide popular vote. So it is entirely possible to outlaw gerrymandering state-by-state.
I think we are going to see the problem with gerrymandering in 2020: When you diddle the district boundaries to win as many districts as possible by 5% it is a disaster when you are down by 10%. There are no "safe" districts. Some heavily gerrymandered states will wind up with zero Republican Representatives.