help using py2app

Discussion in 'Python' started by Joe Strout, Oct 3, 2008.

  1. Joe Strout

    Joe Strout Guest

    I'm trying to use py2app to convert the pySketch wxPython example into
    a stand-alone OS X app. I've found the documentation at <http://undefined.org/python/py2app.html
    >, but it wasn't terribly enlightening for me. My setup.py looks

    like this:

    #!/usr/bin/env python
    """
    setup.py - script for building a bundled OS X application

    Usage:
    % python setup.py py2app
    """
    from distutils.core import setup
    import py2app

    setup(
    app=['pySketch.py'],
    )


    When I run this, it chugs along for a while and spews out lots of
    output, and finally leaves me a bundle in the "dist" folder as it
    should... but that app exits immediately. The only thing the console
    log shows is:

    Oct 2 16:59:21 IA-J1 kernel[0]: CODE SIGNING: cs_invalid_page:
    p=12336[pySketch] clearing CS_VALID

    A similar setup.py worked fine on on the "simple.py" example, but
    clearly something more is needed here. Any clues? Or, is there a
    better list/forum for asking about Mac-specific Python development?
    (I've subscribed to the PyObjC mailing list, and sent a message to the
    list, but it hasn't shown up yet... perhaps the SourceForge lists are
    running slow today.)

    Thanks,
    - Joe
    Joe Strout, Oct 3, 2008
    #1
    1. Advertising

  2. Joe Strout

    Carl Guest

    Joe Strout wrote:
    > I'm trying to use py2app to convert the pySketch wxPython example into a
    > stand-alone OS X app. I've found the documentation at
    > <http://undefined.org/python/py2app.html>, but it wasn't terribly
    > enlightening for me. My setup.py looks like this:
    >
    > #!/usr/bin/env python
    > """
    > setup.py - script for building a bundled OS X application
    >
    > Usage:
    > % python setup.py py2app
    > """
    > from distutils.core import setup
    > import py2app
    >
    > setup(
    > app=['pySketch.py'],
    > )
    >
    >
    > When I run this, it chugs along for a while and spews out lots of
    > output, and finally leaves me a bundle in the "dist" folder as it
    > should... but that app exits immediately. The only thing the console
    > log shows is:
    >
    > Oct 2 16:59:21 IA-J1 kernel[0]: CODE SIGNING: cs_invalid_page:
    > p=12336[pySketch] clearing CS_VALID
    >
    > A similar setup.py worked fine on on the "simple.py" example, but
    > clearly something more is needed here. Any clues? Or, is there a
    > better list/forum for asking about Mac-specific Python development?
    > (I've subscribed to the PyObjC mailing list, and sent a message to the
    > list, but it hasn't shown up yet... perhaps the SourceForge lists are
    > running slow today.)
    >
    > Thanks,
    > - Joe
    >

    If py2app is anything like py2exe, there is always a lot more to do. if
    you are importing modules, you need to explicitly include them into your
    build folder.
    Carl, Oct 3, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Austin

    py2app on Mac OS X 10.3

    Austin, Dec 31, 2004, in forum: Python
    Replies:
    1
    Views:
    368
    Ronald Oussoren
    Dec 31, 2004
  2. Bob Swerdlow

    py2app can't find boot_app.py

    Bob Swerdlow, Mar 14, 2005, in forum: Python
    Replies:
    0
    Views:
    297
    Bob Swerdlow
    Mar 14, 2005
  3. bex

    OS X py2app confusion

    bex, Jul 25, 2005, in forum: Python
    Replies:
    1
    Views:
    440
  4. Richard Taylor

    problems using py2app

    Richard Taylor, Oct 10, 2005, in forum: Python
    Replies:
    0
    Views:
    361
    Richard Taylor
    Oct 10, 2005
  5. Massimo Di Pierro

    py2app help

    Massimo Di Pierro, Oct 15, 2007, in forum: Python
    Replies:
    1
    Views:
    437
Loading...

Share This Page