#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2004
    Posts
    44
    Rep Power
    11

    Distributing application


    How can I distribute application written in Python, so it'll run on machine that doesn't have Python installed, I believe it called 'Freezing' , but I don't have any idea on how to do that.

    I used Boa to design GUI and write code and I will ended up with 2 type of file of my script, one with .py and .pyc, what the different? Can I distribute my app. with just includes .pyc file?
  2. #2
  3. Hello World :)
    Devshed Frequenter (2500 - 2999 posts)

    Join Date
    Mar 2003
    Location
    Hull, UK
    Posts
    2,537
    Rep Power
    69
    You should check out Py2exe. Yes, there are a few other apps that do this kind of thing though they seem to have been abandond over the years

    http://starship.python.net/crew/theller/py2exe/

    let me know how it goes!

    Mark.
    programming language development: www.netytan.com Hula

  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2004
    Posts
    44
    Rep Power
    11
    Originally Posted by netytan
    You should check out Py2exe. Yes, there are a few other apps that do this kind of thing though they seem to have been abandond over the years

    http://starship.python.net/crew/theller/py2exe/

    let me know how it goes!

    Mark.
    I'm thinking about py2exe also but what about if I'm distributing thge program to non-Windows environment?
  6. #4
  7. Hello World :)
    Devshed Frequenter (2500 - 2999 posts)

    Join Date
    Mar 2003
    Location
    Hull, UK
    Posts
    2,537
    Rep Power
    69
    Sorry i missed the last bit of your question there. Anyway the difference between .py .pyc and .pyw files..

    When ever you write a program or module in Python you'll usually save it with a .py extension. This simply tells the interpreter (and the OS in some cases) that the file contains a Python program.

    Compiled Python files (.pyc) on the other hand are usually created when one Python program imports another. The resulting .pyc version will contain the program in an intermediate form called bytecode. The why - It's a preformance thing

    The last file type mentioned; .pyw is the most unusual. All this actually does is tells the interpreter not to open the console when running our program. This is very useful if you're writing a GUI app (as your are) and really dont want to see that old black window.

    have fun,

    Mark.
    programming language development: www.netytan.com Hula

  8. #5
  9. Hello World :)
    Devshed Frequenter (2500 - 2999 posts)

    Join Date
    Mar 2003
    Location
    Hull, UK
    Posts
    2,537
    Rep Power
    69
    There was a program hanging around a while ago called 'installer' which claimed to do cross platform execuatables (to a degree) though i never tested it that far.

    Im assuming you will need to compile it on your target platform though but if it works then got for it!

    In any case this programs been well and truly abandond now though you can still find it attached to one of the threads in this forum if you really want it. Just do a search

    Mark.
    programming language development: www.netytan.com Hula

  10. #6
  11. Mini me.
    Devshed Novice (500 - 999 posts)

    Join Date
    Nov 2003
    Location
    Cambridge, UK
    Posts
    783
    Rep Power
    14
  12. #7
  13. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2004
    Posts
    44
    Rep Power
    11
    Finally i got the Mc Millan's installer, it tooks me hours before it finally works, I hate command line

IMN logo majestic logo threadwatch logo seochat tools logo