License costs are a factor, yes, but they are not the only cost, and in most cases not the significant one.
In some cases the offerings are similar enough that it moves the needle. PostgreSQL for example is a good candidate- Oracle is expensive, and the number of people interacting with it is limited. Plus the fundamentals of Oracle and PostgreSQL are more-or-less the same.
On the other extreme the cost of training and support dwarfs the license cost. If all staff come with knowing how to use say Windows and Excel,but require training and support for say Linux Desktop and Libre Office, then the "free" thing costs more.
It's no accident that OSS has done better on the backend than the front end.
Success for OSS means putting the right product in the right place, taking all things (not just license cost) into account.
(Aside: corruption is a red herring, corrupt officials and companies can be corrupt regardless of software license.)