File tree Expand file tree Collapse file tree 2 files changed +52
-2
lines changed
Expand file tree Collapse file tree 2 files changed +52
-2
lines changed Original file line number Diff line number Diff line change 11* .pyc
2+ dist /
23build /
3- buildexe.bat
4+ * egg-info /
45exedist /
6+ buildexe.bat
57innosetup.iss
68run.bat
79msvcx90 /
Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ def iter_static():
3232 pass
3333else :
3434 extra_options .update (dict (
35+ name = 'LDOCE5 Viewer' ,
3536 windows = [{
3637 'script' : 'ldoce5viewer.py' ,
3738 'icon_resources' : [(1 , 'ldoce5viewer/resources/ldoce5viewer.ico' )],
@@ -51,11 +52,58 @@ def iter_static():
5152 ))
5253
5354
55+ #--------
56+ # py2app
57+ #--------
58+ try :
59+ import py2app
60+ except ImportError :
61+ pass
62+ else :
63+ extra_options .update (dict (
64+ name = 'LDOCE5 Viewer' ,
65+ app = ['ldoce5viewer.py' ],
66+ options = {'py2app' : {
67+ 'iconfile' : './ldoce5viewer/qtgui/resources/ldoce5viewer.icns' ,
68+ 'argv_emulation' : False ,
69+ 'optimize' : 0 ,
70+ 'includes' : ['sip' , 'lxml._elementpath' ],
71+ 'packages' : [],
72+ 'excludes' : [
73+ 'email' , 'sqlite3' ,
74+ 'PyQt4.QtCLucene' ,
75+ 'PyQt4.QtHtml' ,
76+ 'PyQt4.QtHelp' ,
77+ 'PyQt4.QtTest' ,
78+ 'PyQt4.QtOpenGL' ,
79+ 'PyQt4.QtScript' ,
80+ 'PyQt4.QtScriptTools' ,
81+ 'PyQt4.QtSql' ,
82+ 'PyQt4.QtDeclarative' ,
83+ 'PyQt4.QtMultimedia' ,
84+ 'PyQt4.QtDesigner' ,
85+ 'PyQt4.QtXml' ,
86+ 'PyQt4.QtXmlPatterns' ,
87+ ],
88+ #'qt_plugins': [
89+ # 'imageformats/libqjpeg.dylib',
90+ #]
91+ }},
92+ data_files = [
93+ ('qt_plugins/imageformats' , ['/opt/local/share/qt4/plugins/imageformats/libqjpeg.dylib' ]),
94+ ('' , ['ldoce5viewer/static' ]),
95+ ],
96+ ))
97+
98+
5499#------------
55100# setup(...)
56101#------------
102+
103+ if 'name' not in extra_options :
104+ extra_options ['name' ] = 'ldoce5viewer'
105+
57106setup (
58- name = 'ldoce5viewer' ,
59107 version = __version__ ,
60108 description = 'LDOCE5 Viewer' ,
61109 url = 'http://hakidame.net/ldoce5viewer/' ,
You can’t perform that action at this time.
0 commit comments