简体   繁体   中英

Create an exe with Python 3.4 using cx_Freeze

I have found two other articles about this problem on Stack Exchange but none of them has a clear answer: is it possible to create a .exe of a Python 3.4 script? The only solution I found was to use cx_Freeze. I used it, and it indeed created an executable with the dll and everything. However, if I click on it, I get:

name 'raw_input' is not defined

Of course, I used Python 3.4, not 2.7. In my code, I used "input()" but it seems that the executable changed input() to raw_input(). Therefore, I would like to know a way to compile my code into an .exe compatible with Python 3.4.

Thanks

由于您要将python脚本转换为exe,因此请查看py2exe

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM