I used easy_install to install py2app 0.6 and tried it out on one of 
several applications I distribute. Unfortunately the build failed with;

*** using recipe: virtualenv ***
*** using recipe: PIL ***
*** using recipe: matplotlib ***
*** using recipe: pydoc ***
*** using recipe: scipy ***
*** using recipe: pygame ***
*** using recipe: numpy ***
*** filtering dependencies ***
1156 total
82 filtered
11 orphaned
1074 remaining
*** create binaries ***
*** byte compile python files ***
XXX byte-compiling 
fn=/Users/rowen/TUI_1.8.6_Source/BuildForMac/build/bdist.macosx-10.4-fat/
python2.6-standalone/app/collect/ConfigParser.pyc.py 
cfile=/Users/rowen/TUI_1.8.6_Source/BuildForMac/build/bdist.macosx-10.4-f
at/python2.6-standalone/app/collect/ConfigParser.pyc 
dfile=ConfigParser.pyc
...
XXX byte-compiling 
fn=/Users/rowen/TUI_1.8.6_Source/BuildForMac/build/bdist.macosx-10.4-fat/
python2.6-standalone/app/collect/pygame/transform.pyc.py 
cfile=/Users/rowen/TUI_1.8.6_Source/BuildForMac/build/bdist.macosx-10.4-f
at/python2.6-standalone/app/collect/pygame/transform.pyc 
dfile=pygame/transform.pyc
error: cannot copy tree 
'/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/test/zip
dir.zip': not a directory

I've never heard of the file in the error message (.../test/zipdir.zip) 
but it does in fact exist.

I have appended my setup.py in case it is of any help.

-- Russell

My setup.py:

import os
import platform
from plistlib import Plist
import shutil
import subprocess
import sys
from setuptools import setup

# If True a universal binary is built; if False a PPC-only version is 
built
# Only set true if all extensions are universal binaries and Aqua Tcl/Tk 
is sufficiently reliable
UniversalBinaryOK = True

# add tuiRoot to sys.path before importing RO or TUI
tuiRoot = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
roRoot = os.path.join(tuiRoot, "ROPackage")
sys.path = [roRoot, tuiRoot] + sys.path
import TUI.Version

appName = TUI.Version.ApplicationName
mainProg = os.path.join(tuiRoot, "runtuiWithLog.py")
iconFile = "%s.icns" % appName
appPath = os.path.join("dist", "%s.app" % (appName,))
contentsDir = os.path.join(appPath, "Contents")
fullVersStr = TUI.Version.VersionStr
shortVersStr = fullVersStr.split(None, 1)[0]

inclModules = (
    "FileDialog",
)
# packages to include recursively
inclPackages = (
    "TUI",
    "RO",
    "matplotlib", # py2app already does this, but it doesn't hurt to 
insist
)

plist = Plist(
    CFBundleName                = appName,
    CFBundleShortVersionString  = shortVersStr,
    CFBundleGetInfoString       = "%s %s" % (appName, fullVersStr),
    CFBundleExecutable          = appName,
    LSPrefersPPC                = not UniversalBinaryOK,
)

setup(
    app = [mainProg],
    setup_requires = ["py2app"],
    options = dict(
        py2app = dict (
            plist = plist,
            iconfile = iconFile,
            includes = inclModules,
            packages = inclPackages,
        )
    ),
)

_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig
unsubscribe: http://mail.python.org/mailman/options/Pythonmac-SIG

Reply via email to