How to make program in Python run in 32 and 64 bits

1

I have a program made in Python (3.5) under 64-bit operating system, is it possible to have it run in 64 and 32-bit in windows?

NOTE: I used Pyinstaller to compile the program to run on windows machines that do not have python installed.

    
asked by anonymous 03.07.2017 / 01:13

1 answer

1
  • If you create the executable for 32bit for Windows it will run on windows32bit and windows64bit.

  • If compiling for Windows 64bits will only run on 64bit

  • If it is in Linux then you have to create an executable for each distro (debian, fedora, etc.) and for each type of processor.

  

Just to note that Python is not compiled, what Pyinstaller is a standalone executable with the full python application plus the its .py (or a Bytecode of it, I do not know the core to state in detail) / p>      

    

Seethatpython.exeand.pydgotogether.

Windows

IfitisaWindows-onlyexecutable,justinstallthe Pyinstaller for Windows 32bit (x86), I believe that for this you must first install the Python for windows-32bit and then install pip on it, then install:

pip install pyinstaller

Be careful that if you have multiple versions of Python it is best to point the entire Python path before running pip and pyinstaller , I recommend that you read this: PIP work-with-multiple-versions-of-python-installed-in -parallel

    
03.07.2017 / 01:25