Clean up platform assignment

By using ``case`` instead of giant ``if…elif…else`` statements, you can save a lot of space and power. In this commit, I favored using permissive conditions (using *value*), but I'm not sure this is even necessary.

I'm also unsure of the possible cases for the capitalization of ``mingw``, but that case can probably be simplified as well.