In an war of Ecosystems does it make sense for MS to write software for other platforms?

I have always been annoyed how freely MS gives away software to other platforms. Apple for example doesn't give out garageband etc to Windows even though it would make them tons of money. You don't see MS publishing games for PS3 either. I am not sure why they don't have "One Microsoft" vision at MS where teams are working with each other for benefit of each other and MS. Instead each team is constantly stabbing other in the back just to post better numbers.

Anyone else agree?