about summary refs log tree commit diff
path: root/setup.py
diff options
context:
space:
mode:
authorCiro Mattia Gonano <ciromattia@gmail.com>2013-11-08 15:32:22 +0100
committerCiro Mattia Gonano <ciromattia@gmail.com>2013-11-08 15:32:22 +0100
commit3e11a88a7c775946aa17e1b518898f70793dbe74 (patch)
tree124ff3010ab1c2fe560d535f8c54d1eeeccffc19 /setup.py
parentAdded Linux build script (diff)
downloadkcc-3e11a88a7c775946aa17e1b518898f70793dbe74.tar.gz
kcc-3e11a88a7c775946aa17e1b518898f70793dbe74.tar.bz2
kcc-3e11a88a7c775946aa17e1b518898f70793dbe74.zip
Bundle 7za and unrar for OSX too.
Diffstat (limited to 'setup.py')
-rw-r--r--setup.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index 4bee918..4e0eadc 100644
--- a/setup.py
+++ b/setup.py
@@ -24,10 +24,11 @@ if platform == "darwin":
                 argv_emulation=True,
                 iconfile='icons/comic2ebook.icns',
                 includes=['PIL', 'sip', 'PyQt4', 'PyQt4.QtCore', 'PyQt4.QtGui', 'PyQt4.QtNetwork'],
+                qt_plugins=[],
                 excludes=['PyQt4.QtDeclarative', 'PyQt4.QtDesigner', 'PyQt4.QtHelp', 'PyQt4.QtMultimedia',
                           'PyQt4.QtOpenGL', 'PyQt4.QtScript', 'PyQt4.QtScriptTools', 'PyQt4.QtSql', 'PyQt4.QtSvg',
                           'PyQt4.QtXmlPatterns', 'PyQt4.QtXml', 'PyQt4.QtWebKit', 'PyQt4.QtTest', 'Tkinter'],
-                resources=['LICENSE.txt', 'other/Additional-LICENSE.txt', 'other/unrar'],
+                resources=['LICENSE.txt', 'other/Additional-LICENSE.txt', 'other/unrar', 'other/7za'],
                 plist=dict(
                     CFBundleName=NAME,
                     CFBundleShortVersionString=VERSION,
@@ -44,6 +45,9 @@ if platform == "darwin":
                         )
                     ],
                     LSMinimumSystemVersion='10.6.0',
+                    LSEnvironment=dict(
+                        PATH='/usr/local/bin:/usr/bin:/bin'
+                    ),
                     NSHumanReadableCopyright='ISC License (ISCL)'
                 )
             )
@@ -84,3 +88,8 @@ setup(
     packages=['kcc'], requires=['Pillow'],
     **extra_options
 )
+
+if platform == "darwin":
+    from os import chmod
+    chmod('dist/' + NAME + '.app/Contents/Resources/unrar', 0777)
+    chmod('dist/' + NAME + '.app/Contents/Resources/7za', 0777)
\ No newline at end of file