from distutils.core import setup import py2app # Retrospect wants the event handler called "Retrospect Event Handler" without # the .app suffix; py2app doesn't want to create apps with no suffix class TrueEmpty(object): def __str__(self): return '' def __add__(self, other): return other def __radd__(self, other): return other setup(name='Retrospect Event Handler', version='1.0a1', app=['RetroStatus.py'], options=dict(py2app= dict(extension=TrueEmpty(), iconfile='RetroClient.icns', plist=dict(NSAppleScriptEnabled=True, CFBundleIdentifier='net.sabi.RetroStatus')))) # don't forget to set the bundle bit: # % SetFile -a B "dist/Retrospect Event Handler" # XXX can't do this from Python: # # >>> f.FSGetCatalogInfo(kFSCatInfoFinderInfo)[2] # Carbon.File.FSSpec((-100, 118904, 'Retrospect Event Handler')) # >>> f.FSGetCatalogInfo(kFSCatInfoFinderInfo)[2].FSpGetFInfo() # Traceback (most recent call last): # File "", line 1, in ? # MacOS.Error: (-43, 'File not found')