[Pythonmac-SIG] py2app 0.3 stable?

Bob Ippolito bob at redivi.com
Tue Jan 31 22:26:53 CET 2006

On Jan 31, 2006, at 12:48 PM, Justin Mitchell wrote:

> On 1/31/06, Justin Mitchell <pythonmac at justinmitchell.net> wrote:
>> On 1/31/06, Ronald Oussoren <ronaldoussoren at mac.com> wrote:
>>> On 31-jan-2006, at 11:27, Justin Mitchell wrote:
>>>> On 1/31/06, Ronald Oussoren <ronaldoussoren at mac.com> wrote:
>>>>> On 31-jan-2006, at 5:49, Justin Mitchell wrote:
>>>>>> Anyways, I'm running into this error when trying to run the
>>>>>> application (which was packaged with py2app 0.2). The script
>>>>>> works if
>>>>>> I don't package it. No changes were made from the ppc version.
>>>>>>     import pcapy
>>>>>> ImportError: dlopen(/path/to/myapplication.app/Contents/ 
>>>>>> Resources/
>>>>>> Python/lib-dynload/pcapy.so,
>>>>>> 2): no suitable image found.  Did find:
>>>>>>       /path/to/myapplication.app/Contents/Resources/Python/lib-
>>>>>> dynload/
>>>>>> pcapy.so:
>>>>>> mach-o, but wrong architecture
>>>>> What is the output of "file /path/to/myapplication.app/Contents/
>>>>> Resources/Python/lib-dynload/pcapy.so"? And
>>>>> what is the output of "file /path/to/myapplication.app/Contents/
>>>>> MacOS/
>>>>> myapplication"?
>>>> file pcapy.so:
>>>> pcapy.so: Mach-O bundle i386
>>>> file myapplication.so:
>>>> myapplication: setuid Mach-O executable ppc
>>> Note that the application is a ppc executable and the extensions is
>>> for i386. That won't work :-)
>>>>> Did you package the application on PPC or did you rebuild the
>>>>> application bundle on Intel? If the latter,
>>>>> did you rebuild the py2app application stub binary?
>>>> I packaged the application on the Intel iMac. I installed py2app  
>>>> from
>>>> scratch, using the 0.2 source.
>>> That's the problem. Go to py2app/src/py2app/apptemplate and remove
>>> prebuild/main. Then reinstall
>>> py2app from source. There's also a bundletemplate, remove the files
>>> in its prebuild directory as
>>> well if you want to build plugin bundles.
>> OK, that makes sense, I didn't realize it was prebuilt. I just tried
>> this, but got the same error. I suspect that I am building it
>> incorrectly. The instructions say to use "python setup.py bdist_mpkg
>> --open", but that as always gotten lots of errors for me (doc folder
>> missing, /usr/bin/mkbom failed). So, I tried "python setup.py  
>> build &&
>> python setup.py install". That installed, but I'm not sure if it's
>> actually doing it's job....
>> Justin
> Well, I went ahead and checked out 0.2.1 (r502) from the SVN
> repository. The "proper" installation method works with that version,
> and it also solved the problem with executables being the wrong arch
> (I still removed the prebuilt files).
> Was I doing something wrong before, or is this just something with  
> 0.2?

The zip source release was busted (the docs were missing)... the  
installer pkg and the 0.2 tag in the subversion repository are  
correct.  I didn't update the MANIFEST.in file correctly, that's all.

py2app 0.3 is going to be setuptools based, so I won't ever have to  
touch a MANIFEST.in file again :)


More information about the Pythonmac-SIG mailing list