On Windows, make sure sys.argv[0] is set correctly.