Make main.py more platform independant