Mac packaging

Roger Binns <[email protected]>
Newsgroups gmane.comp.mobile.bitpim.devel
Message-ID <[email protected]>
I have fixed various things in Mac packaging (and probably broken them  
for 10.2).

Firstly the helpers directory is now actually included :-)

The release number (if non-zero) also becomes part of the dmg filename  
automatically.

I don't have SDL installed.  If you do have SDL installed then wxPython  
references it (it is one way of playing sound) but it isn't needed for  
the packaging.

SQLite 3 is also a shared library in the packaging, whereas I build  
apsw with SQLIte statically linked in (less can go wrong ...)

I also got running py2app with optimize working (details below) which  
shrunk the size of the zip by over 3 megabytes.  It also means a whole  
bunch of developer only code won't run either (a good thing!)  The  
newly included helpers directory negates the 3 megabyte gain ...

I have uploaded a build I made of the current CVS to the miscellaneous  
section of the website for people to have a look.  It will also do the  
cool mp3 conversions etc

http://sourceforge.net/project/showfiles.php? 
group_id=75211&package_id=113804

I couldn't figure out why py2app fails when you tell it to optimize.   
It ends up not finding some of its own files, but doesn't have that  
problem when optimize isn't specified.  Anyway, add the lines between  
the pound signs at line 207 of  
/Library/Python/2.3/py2app/py2app/util.py

             if target_dir:
                 cfile = os.path.join(target_dir, dfile)

             ###
             ### Hack to work around bug in py2app with optimize
             ###
             if not os.path.exists(mod.filename):
                 import py2app
                  
bootstrapname=os.path.join(os.path.dirname(py2app.__file__),  
"bootstrap", mod.filename)
                 if os.path.exists(bootstrapname):
                     mod.filename=bootstrapname
             ###
             ###  End hack
             ###

             if force or newer(mod.filename, cfile):
                 if verbose:
                     print "byte-compiling %s to %s" % (mod.filename,  
dfile)

Roger



-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.