> Apple is using its position in one market (phone hardware sales) to exclude competition in another (app sales). It's a text book example of an antitrust violation.
Antitrust law considers the entire market, not just how one company treats their own customers. Apple's policies have no effect on your ability to sell apps on Android.
Here's an example of what would be potentially anti-competitive behavior by Apple: if they made 3rd party developers sign exclusivity contracts that said in order to sell in the Apple App Store, they have to agree to NOT sell a version of the same app in the Google Play store. That would be Apple using its position in the market to exclude competition.
But Apple does not do this. Developers are free to release the same app on Apple and Android, and customers are free to buy into the Apple system or the Android system. Competition exists and is robust. In fact, as measured by unit sales and installed base, Android is arguably ahead of Apple.
> You don't have to buy software to run on a Mac exclusively from Apple, for example.
This is Apple's choice in how they configure those computers; it's not legally mandated.