When I moved to OSX from Linux for work, there was the choice of homebrew, which blasted crap all over /usr and screwed around with SIP, vs MacPorts that worked within the constraints of the way OSX works, including frameworks and versioning for things like Java and Python.
MacPorts just works, installs everything under /opt and integrates the ports into the OSX world, including things like launchctl services etc.
It seems better built and based on the solid BSD ports architecture.
Also, brew broke my machine a vouple times too many. It’s there, installed, but nothing it does is in the PATH. I keep it because I need to help other engineers who bet their machines on it behaving well.