Actually the opposite. Open source pretty means anyone can download the source code, build it with Xcode, and run it on their own Mac. If it was harder or impossible to run closed source code on Macs, that would actually encourage the development of more open source apps.But if they did lock down their system like iOS, but one which also runs Xcode for Mac-based apps, I also suspect many people would defend it. "Steve Jobs said PCs are trucks and this is better because it's a tailored, curated experience. It's safer…"
Would developers complain? Obviously, it would backstab open-source.
Right now, that is the current method to freely distribute iOS apps completely outside the App Store: put an Xcode project for an iOS app on Github. Anyone with a current Mac, Xcode, and an AppleID can download the project from Github, build, and run it on their own iOS or iPadOS devices. So any iOS devices running stock iOS (e.g. not managed by corporate or school IT) are not really completely locked down.
$99 more for a dev enrollement, and you can even distribute open source apps to a few of your friends, family, etc.