Distribution

Started by Ryex, April 05, 2011, 11:29:54 pm

Previous topic - Next topic

Ryex

April 05, 2011, 11:29:54 pm Last Edit: April 05, 2011, 11:40:56 pm by Ryex
The distribution of a Python program is actually fairly simple. there are several freezing utilities out there to do the job.
based on my research we need to use a different one for each platform as while a cross platform solution exists the ones designed specifically for a platform work best on those platforms

py2exe  -  for creating widows executables

py2app  -  for creating mac app bundles

cx-freaze  -  for linux binaries

there is also http://www.pyinstaller.org

but I'm not so sure about it, preliminary research suggests that it may be better for linux distros but I'm not sure.


there are several nuances to each system so when it comes time to build the editor we should be familial with each utility and how to best set it up. exspecialy if we are going to include something like an auto updater
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

ForeverZer0

April 05, 2011, 11:37:22 pm #1 Last Edit: April 05, 2011, 11:41:13 pm by Ryex
* Fixes spelling in title *

I still need to familiarize myself with some of these other platforms, namely Mac. I've been messing around with Linux platforms, but when it comes to Mac, I have 0 experience.

Are the differences large enough that we will need to write the code differently for the actual updates?
I am done scripting for RMXP. I will likely not offer support for even my own scripts anymore, but feel free to ask on the forum, there are plenty of other talented scripters that can help you.

Ryex

no you don't have to write the code differently but the utility that builds the executable is different

ps. sorry for the edit to your post, some how I managed to edit your post instead of replying
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

G_G

I need to learn some python again @__@

Ryex

python is freakishly easy to learn. don't worry about it. when we get to work on the editor it will come naturally after all your work with ruby.
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

Blizzard

Python is quite similar to Ruby so you shouldn't have any problems.

We use py2exe at Cateia so it's definitely the way to go on Windows platforms.
Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.

Ryex

ok, I couldn't sleep so I've been trying to get a working test of py2exe so I can test a few specific things, and i'm failing horrdily. I CAN'T get it to create a working single exe that doesn't crash with a missing dll error or an error about loading one incorrectly.

py2exe has been out of development for 4 years or close to it but pyinstaller is actively developed i'm going to give it a try and see if I can get it to work.
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

Blizzard

I think you need to add python25.dll if you use py2exe. o.o;
Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.

Ryex

no, I'm using python 2.6 and it just doesn't work. python 2.5 would work but 2.6 doesn't despite their claim that it does
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

Blizzard

Alright. Good luck with pyinstaller then.
Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.

Ryex

Ok then Pyinstaller it is. the SVN now contained the pyinstaller version I used and a bat file to build the main exe. it works perfectly as far as I can tell. the themeing on the exe is a messed up untill you enable compatibility mode on the exe.

also pyinstaller builds exe's that we can sign using SIGNTOOL.EXE and it has an option to include a version resource file as a resource in the exe if we make one at some point.
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />

Ryex

ALL RIGHT BOOYA! I did some more research and managed to get py2exe working. I have to list the dll as a dependent in the manifest. I'll commit the work later. py2exe is safer because Pyinstaller actually unpacks everything to a temp dir.
I no longer keep up with posts in the forum very well. If you have a question or comment, about my work, or in general I welcome PM's. if you make a post in one of my threads and I don't reply with in a day or two feel free to PM me and point it out to me.<br /><br />DropBox, the best free file syncing service there is.<br />