2727ARCH_STR = platform .architecture ()[0 ]
2828
2929# OS_POSTFIX is for directories/files names in cefpython sources
30+ # and doesn't include architecture type, just OS name.
31+
3032# OS_POSTFIX2 is for platform name in cefpython binaries
33+ # and includes architecture type (32bit/64bit).
34+
3135# CEF_POSTFIX2 is for platform name in upstream CEF binaries
36+ # and includes architecture type (32bit/64bit).
37+
3238OS_POSTFIX = ("win" if platform .system () == "Windows" else
3339 "linux" if platform .system () == "Linux" else
3440 "mac" if platform .system () == "Darwin" else "unknown" )
@@ -353,17 +359,23 @@ def _detect_distrib_dir():
353359 # Will only be set when called from scripts that had version
354360 # number arg passed on command line: build.py, build_distrib.py,
355361 # make_installer.py, etc.
356- if LINUX :
357- # On Linux buildig 32bit and 64bit separately, so don't
362+ if LINUX or MAC :
363+ # - On Linux buildig 32bit and 64bit separately, so don't
358364 # delete eg. 64bit distrib when building 32bit distrib.
359365 # Keep them in different directories.
366+ # - On Mac only 64bit is supported.
360367 dirname = ("distrib_{version}_{postfix2}"
361368 .format (version = version , postfix2 = OS_POSTFIX2 ))
362- else :
369+ elif WINDOWS :
363370 # On Windows both 32bit and 64bit distribs are built at
364371 # the same time.
365- # On Mac only 64bit is supported.
366- dirname = "distrib_{version}" .format (version = version )
372+ dirname = ("distrib_{version}_{win32}_{win64}"
373+ .format (version = version ,
374+ win32 = OS_POSTFIX2_ARCH [WINDOWS ]["32bit" ],
375+ win64 = OS_POSTFIX2_ARCH [WINDOWS ]["64bit" ]))
376+ else :
377+ dirname = ("distrib_{version}_{postfix}"
378+ .format (version = version , postfix = OS_POSTFIX ))
367379 DISTRIB_DIR = os .path .join (BUILD_DIR , dirname )
368380
369381
0 commit comments