Distribution Issues

Need help distributing for Windows & Macs

Page 1 of 1

6 Replies - 805 Views - Last Post: 06 January 2011 - 03:42 PM Rate Topic: -----

#1 LinuxFan  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 26
  • View blog
  • Posts: 82
  • Joined: 19-December 10

Distribution Issues

Posted 05 January 2011 - 05:23 PM

Hey everyone, I'm back to bug you again :)

I run linux, (switching distributions often) and am stuck with a distribution problem: How do I distribute python apps for windows, from a linux box.

Right now I'm stuck with these options:
  • Distribute something like PortablePython that is 45mb.
  • Remove linux off my pc and install windows. (Yeah, right.)
  • Have the user(s) download and install Python, wxPython, and PyGame.
  • Have someone else with a windows pc package my scripts for me. (I'd add you in the credits, should you help)


I can't find any other ways of distributing my scripts from a linux box to Windows. (and maybe Macs, I don't know... Macs usually have Python preinstalled, right?)

It's not really a pressing issue, but I'm launching my own blog and I want anyone who reads my blog to be able to run my utilities/apps without *needing* to download a bunch of junk.

Of course, I'm going to state that downloading Python/wxPython/PyGame is the recommended way to run it, but if they're just running one or two of my apps, I'd like to be able to provide a standalone app.

Any ideas? Or possibly would someone give me a hand and use something like py2exe on my scripts for me? (I tried WINE, but it failed horribly) I'd only update the standalone on major version updates, e.g. if I update from 2.2 to 2.3, I wouldn't rebuild the standalone, but if I update from 2.2 to 3.0 (or probably 3.1, to catch bugs from 3.0), I'd want to rebuild.

Many thanks!

This post has been edited by LinuxFan: 05 January 2011 - 05:28 PM


Is This A Good Question/Topic? 0
  • +

Replies To: Distribution Issues

#2 atraub  Icon User is offline

  • Pythoneer
  • member icon

Reputation: 756
  • View blog
  • Posts: 1,990
  • Joined: 23-December 08

Re: Distribution Issues

Posted 05 January 2011 - 07:23 PM

Assuming it's a python programming blog, your readers should have Python installed. You shouldn't need to package anything additional for them to use it... buuut providing links to python.org and pygame.org would be a nice gesture.
Was This Post Helpful? 0
  • +
  • -

#3 LinuxFan  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 26
  • View blog
  • Posts: 82
  • Joined: 19-December 10

Re: Distribution Issues

Posted 05 January 2011 - 07:43 PM

So sorry. my blog is at http://furryhead.co.cc (for lack of a better name) - it's a general application development blog, but I'm going to be using it primarily for Python apps.

What I meant by packaging python with the utilities is something like py2exe so that the average desktop user can download a file, possibly have that file download python & install it for them, then they be able to run it as if it's an ordinary desktop program. Of course, this won't happen unless I write a C++ or Java app to do this, but hey, I can dream, eh? :)

EDIT: I almost forgot, most of my scripts will have >3 files, what's the best way to distribute the source, apart from just zipping it?

This post has been edited by LinuxFan: 05 January 2011 - 07:49 PM

Was This Post Helpful? 0
  • +
  • -

#4 atraub  Icon User is offline

  • Pythoneer
  • member icon

Reputation: 756
  • View blog
  • Posts: 1,990
  • Joined: 23-December 08

Re: Distribution Issues

Posted 05 January 2011 - 07:57 PM

Have you considered Jython? Jython code gets compiled down to Java bytecodes which run on a Java Virtual Machine. Most people have Java on their machines anyways, which means that they should be able to run your programs. I don't know about pygame and that sort of thing though. Admittedly, I haven't used Jython myself, so I'd recommend studying it before you consider it a viable alternative.

This post has been edited by atraub: 05 January 2011 - 08:00 PM

Was This Post Helpful? 0
  • +
  • -

#5 LinuxFan  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 26
  • View blog
  • Posts: 82
  • Joined: 19-December 10

Re: Distribution Issues

Posted 05 January 2011 - 08:02 PM

View Postatraub, on 05 January 2011 - 08:57 PM, said:

Have you considered Jython? Jython code gets compiled down to Java byte code and most people have Java on their machines anyways, which means that they should be able to run your programs. Admittedly, I haven't used Jython myself, so I'd recommend studying it before you consider it a viable alternative.


Indeed, I have considered Jython many times. However, I decided against it because:
  • It no longer supports compiling to Java bytecode.
  • It doesn't support wxPython OR PyGame (as far as I can tell), so I'd have to use Java libraries instead.


However, I may write a application in Java (or Jython, maybe ;)) to download & install Python + deps for my scripts for them, should they not be computer-savvy.

Thanks, and if you have any other ideas on distribution (even just source distribution, aside from just zipping) I'd love to know. Thanks again!

This post has been edited by LinuxFan: 05 January 2011 - 08:05 PM

Was This Post Helpful? 0
  • +
  • -

#6 Dogstopper  Icon User is offline

  • The Ninjaducky
  • member icon



Reputation: 2857
  • View blog
  • Posts: 10,960
  • Joined: 15-July 08

Re: Distribution Issues

Posted 05 January 2011 - 09:22 PM

Or you could just do that in a script. Most Linux Distributions that I run across are partially written in Python, so they usually have it installed. You'd just need to write a Batch file and a mac script to do that if you know those.
Was This Post Helpful? 0
  • +
  • -

#7 LinuxFan  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 26
  • View blog
  • Posts: 82
  • Joined: 19-December 10

Re: Distribution Issues

Posted 06 January 2011 - 03:42 PM

View PostDogstopper, on 05 January 2011 - 10:22 PM, said:

Or you could just do that in a script. Most Linux Distributions that I run across are partially written in Python, so they usually have it installed. You'd just need to write a Batch file and a mac script to do that if you know those.

I could also use a shell script for linux, just in case ;) but the drawback to that is that I don't know how to do socket operations in a batch file OR on mac scripts, never had a mac and I don't have access to a Windows computer.

I'm thinking to just provide huge text at the top of my page stating make sure you have python :) and then write a python installer script to check if wxPython or PyGame is installed, and tell them where to download it if they don't have it.

Thanks anyway!

EDIT: If anyone happens to feel like compiling/running a C++ app, I might try making an autoinstaller with C++, but I'd need help (read: unpaid, but with credits on my blog) from a C++ developer on Mac and Windows separately... :\ PM me if you're interested.

This post has been edited by LinuxFan: 06 January 2011 - 03:46 PM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1