Trying to use py2exe, but python is not recognized

后端 未结 2 1802
难免孤独
难免孤独 2020-12-21 20:30

I am following the the tutorial at http://www.py2exe.org/index.cgi/Tutorial to figure out how to use py2exe. I get down to step 3 where you are supposed to run the command:<

2条回答
  •  伪装坚强ぢ
    2020-12-21 21:08

    Python just isn't on your path. If you indeed have Python 2.4, it should be C:\Python24\python.exe with the default installer.

    Wherever the file is located, if you don't set Python's folder in your path, you will write the command as

    C:\Python24\python.exe setup.py py2exe
    

    (or whatever the correct path is).

    Depending on how your installation was configured, you might be able to just do

    setup.py py2exe
    

    since Windows might automatically associate *.py files with Python.

    You might want to also read "Finding the Python Executable" from the Python documentation.

提交回复
热议问题