markreidvfx / pyaaf

Python Bindings for the Advanced Authoring Format (AAF)
http://markreidvfx.github.io/pyaaf
MIT License
49 stars 9 forks source link

py2app #30

Open rolodub opened 7 years ago

rolodub commented 7 years ago

Hi,

I'm trying to make a .app of my script with py2app. I managed making .app with scripts which not refer to pyaaf lib. My script works well on terminal... When I try to run my new application (.app), it doesn't start an console says:

14/11/2016 13:07:23,285 Mn_Confo[27844]: from . import core 14/11/2016 13:07:23,285 Mn_Confo[27844]: File "aaf/util.pxd", line 20, in init aaf.core (aaf/core.cpp:1340) 14/11/2016 13:07:23,285 Mn_Confo[27844]: File "aaf/util.pyx", line 12, in init aaf.util (aaf/util.cpp:15827) 14/11/2016 13:07:23,285 Mn_Confo[27844]: ImportError: No module named uuid 14/11/2016 13:07:23,350 Mn_Confo[27844]: Mn_Confo Error

Is it the same on your computers? Have you any idea? Thanks

rolodub commented 7 years ago

I solve the missing uuid module problem: As i didn't use uuid in my script, it wasn't copied in the app archive. I have imported it in my script and instantiate a uuid for nothing -> solved. But i have now a new problem which seems refers to aaf lib ...

16/11/2016 22:03:42,970 wxUploadRider[4940]: from aafrider.aafrider import AafReader 16/11/2016 22:03:42,971 wxUploadRider[4940]: File "aafrider/aafrider.pyc", line 8, in 16/11/2016 22:03:42,971 wxUploadRider[4940]: File "/Users/rolandduboue/dist/wxUploadRider.app/Contents/Resources/lib/python2.7/aaf/init.py", line 8, in 16/11/2016 22:03:42,971 wxUploadRider[4940]: core.register_all(path) 16/11/2016 22:03:42,971 wxUploadRider[4940]: File "aaf/core.pyx", line 19, in aaf.core.register_all (aaf/core.cpp:1034) 16/11/2016 22:03:42,971 wxUploadRider[4940]: File "aaf/util.pyx", line 23, in aaf.util.error_check (aaf/util.cpp:1595) 16/11/2016 22:03:42,971 wxUploadRider[4940]: RuntimeError: failed with [-2146302976]: Unknown Error 16/11/2016 22:03:43,036 wxUploadRider[4940]: wxUploadRider Error 16/11/2016 22:03:43,036 wxUploadRider[4940]: 2016-11-16 22:03:43.035 wxUploadRider[4940:707] wxUploadRider Error

markreidvfx commented 7 years ago

It looks like it can find aaf sdk libs, you probable need to pack them as well. libcom-api.dylib aafext/libaafintp.dylib aafext/libaafpgapi.dylib

rolodub commented 7 years ago

Thanks,

As i mentioned it in my setup.py, aaf lib was already copied in the aaf folder. I've add the frameworks key which copy all libs in archive Framework folder. ... Still the same error message on console...

lib frameworks

`Usage: python setup.py py2app """ from setuptools import setup

APP = ['/Users/rolandduboue/PycharmProjects/appliCliente/Vue/wxUploadRider.py'] DATA_FILES = [] OPTIONS = {'argv_emulation': True,'packages':['aaf'],'frameworks':['/Users/rolandduboue/Documents/AAF/bin/aafext/libaafintp.dylib','/Users/rolandduboue/Documents/AAF/bin/aafext/libaafpgapi.dylib','/Users/rolandduboue/Documents/AAF/bin/libcom-api.dylib']}

setup( app=APP, data_files=DATA_FILES, options={'py2app': OPTIONS}, setup_requires=['py2app'], )`