开发者

What technologies exist to create stand alone executables for Python 3?

开发者 https://www.devze.com 2023-01-11 02:05 出处:网络
Other开发者_开发百科 than cx_Freeze, are there any other current maintained tool suites to generate stand alone executables for Python 3k?

Other开发者_开发百科 than cx_Freeze, are there any other current maintained tool suites to generate stand alone executables for Python 3k?

Are there any other techniques for minimizing preinstallation requirements under Windows?


There doesn't seem to be another choice of tool at the moment.

There's nothing stopping you from including a prebuilt Python environment in your package/installer and either creating an appropriate shortcut to launch the Python app, or creating a separate executable that launches the Python app (or even linking the Python interpreter into the executable and using it like that...). It just takes some more effort making sure you've got all the right pieces (like .dlls) where they need to be.

Remember, Python doesn't have to be "installed" per se, you just need to make sure it knows where to find everything (e.g. set the appropriate environment variables like PYTHONPATH in whatever launcher you're using).


I know of only cx_Freeze to build Python 3 executables. I asked a similar question a few month ago (which can be found here).
Maybe that already helps?


No, not yet.

There is just cx_freeze which supports Python 2.3 or higher (including Python 3), since it makes use of the zip import facility which was introduced in 2.3.

For more information you can visit cx_freeze website here http://cx-freeze.sourceforge.net/


For Windows, I think py2exe is a good option. It's described as follows:

py2exe is a Python Distutils extension which converts Python scripts into executable Windows programs, able to run without requiring a Python installation.

And it works with Python 3.x.

(As a bonus, there's py2app that does the trick on Mac OS X.)

0

精彩评论

暂无评论...
验证码 换一张
取 消