Quantcast

Re: Cross compiling 32 bit application from a 64 bit Windows

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Cross compiling 32 bit application from a 64 bit Windows

ragini dahihande
Hello Guy,

I have one doubt.
If I have 64 bit of windows machine and I installed 32 bit python on that system.
If I create exe by PyInstaller that exe can be executed on 32 bit Windows ?

Mean for 32 bit windows exe no need to run project on 32 bit windows.
Using only 32 bit python we can create it.

Am I correct?

Thanks,
Ragini

On Tuesday, October 26, 2010 at 9:34:51 AM UTC+5:30, Andy wrote:
Hi Guys!

I've got a new computer which has the 64-bit version of Windows 7.  In
it I installed the 64-bit versions of Python, wxPython, and MySQLdb
too.  With them I made a couple of applications that compile
beautifully with PyInstaller (<a href="http://www.pyinstaller.org/ticket/25" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwww.pyinstaller.org%2Fticket%2F25\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEUne3D_ZwNNReXeY0V8hZZnwwXVg&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwww.pyinstaller.org%2Fticket%2F25\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEUne3D_ZwNNReXeY0V8hZZnwwXVg&#39;;return true;">http://www.pyinstaller.org/ticket/25).
Thanks to all involved.

The problem is that most of the people to whom I'd be giving copies of
my compiled programs use 32-bit versions of Windows.  I already tried,
and sure enough, programs compiled in my 64-bit machine don't run in
32-bit machines.  Is there a way to compile with PyInstaller 32-bit
applications from a 64-bit computer?

Thanks,
Andy

--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Cross compiling 32 bit application from a 64 bit Windows

Steve Barnes


On 29/12/2016 06:20, ragini dahihande wrote:

> Hello Guy,
>
> I have one doubt.
> If I have 64 bit of windows machine and I installed 32 bit python on
> that system.
> If I create exe by PyInstaller that exe can be executed on 32 bit Windows ?
>
> Mean for 32 bit windows exe no need to run project on 32 bit windows.
> Using only 32 bit python we can create it.
>
> Am I correct?
>
> Thanks,
> Ragini
>

Yes you are.

For several years now I have been using a Windows 7 64 bit machine to
build python based code that runs on Windows 32 bit machines elsewhere -
All I do is to use the 32 bit version of python to do it.  The only
major issue I have is that some of the machines still run XP and the
last version of python to support XP is 3.4 but hopefully we will
eventually replace the XP machines.

--
Steve (Gadget) Barnes
Any opinions in this message are my personal opinions and do not reflect
those of my employer.

--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Cross compiling 32 bit application from a 64 bit Windows

davecortesi
In reply to this post by ragini dahihande

 For several years now I have been using a Windows 7 64 bit machine to
build python based code that runs on Windows 32 bit machines elsewhere -
All I do is to use the 32 bit version of python to do it.

It's good that works but you really should not count on it. The manual is specific about not being a "cross-compiler" and says if you want to bundle for a specific OS you need to run on that OS. My point being, if it ever breaks, you won't get a fix.

--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Cross compiling 32 bit application from a 64 bit Windows

Steve Barnes


On 29/12/2016 15:52, davecortesi wrote:

>
>      For several years now I have been using a Windows 7 64 bit machine to
>     build python based code that runs on Windows 32 bit machines
>     elsewhere -
>     All I do is to use the 32 bit version of python to do it.
>
>
> It's good that works but you really should not count on it. The manual
> is specific about not being a "cross-compiler" and says if you want to
> bundle for a specific OS you need to run on that OS. My point being, if
> it ever breaks, you won't get a fix.

Building 32 bit Windows Python Applications on a 64 bit platform is not
cross compiling when you are running 32 bit python on that platform - 32
bit Python under Windows runs with exactly the same instruction set and
memory model regardless of running on Windows 64 bit or 32 bit.

pyInstaller, (or py2exe or cxFreeze), embed the local copy of python,
and the required libraries, into the created package and the 32 bit
windows python installation is the same regardless of being installed on
a 32 bit or 64 bit machine.  What you cannot do is deploy applications
built with 64 bit Windows python, (and it's libraries), on 32 bit
Windows machines. Needless say 32 bit deployments can also run on 64 bit
machines but it is a very good idea to run your tests using the exact
same version(s) of python that you are going to deploy with.

If you are even slightly worried you can build & test in a virtual
machine under vagrant or virtualbox, test VMs can be found at
https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/ you just
have to install python and the libraries that you need before your test
& build.

--
Steve (Gadget) Barnes
Any opinions in this message are my personal opinions and do not reflect
those of my employer.

--
You received this message because you are subscribed to the Google Groups "PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/pyinstaller.
For more options, visit https://groups.google.com/d/optout.
Loading...