diff options
author | Micah Lee <micah@micahflee.com> | 2015-05-15 13:03:04 -0700 |
---|---|---|
committer | Micah Lee <micah@micahflee.com> | 2015-05-15 13:03:04 -0700 |
commit | 245ddd03006b976d5a93322539d25c30784b095f (patch) | |
tree | 99de9337772a3275e4b522d1ec9aca35c8daffd6 | |
parent | 669750be37a71cf2ebbf779b4dcf2aaab71d04cb (diff) | |
download | onionshare-245ddd03006b976d5a93322539d25c30784b095f.tar.gz onionshare-245ddd03006b976d5a93322539d25c30784b095f.zip |
moved build scripts into install folder (#181)
-rw-r--r-- | BUILD.md | 14 | ||||
-rwxr-xr-x | install/build_deb.sh (renamed from build_deb.sh) | 5 | ||||
-rwxr-xr-x | install/build_dmg.sh (renamed from build_dmg.sh) | 4 | ||||
-rw-r--r-- | install/build_exe.bat (renamed from build_exe.bat) | 4 | ||||
-rwxr-xr-x | install/build_rpm.sh (renamed from build_rpm.sh) | 5 | ||||
-rw-r--r-- | install/check_lacked_trans.py (renamed from check_lacked_trans.py) | 0 | ||||
-rw-r--r-- | install/dmg_background.png (renamed from setup/dmg_background.png) | bin | 160976 -> 160976 bytes | |||
-rw-r--r-- | install/license.txt (renamed from setup/license.txt) | 0 | ||||
-rw-r--r-- | install/onionshare-launcher.py (renamed from setup/onionshare-launcher.py) | 0 | ||||
-rw-r--r-- | install/onionshare-osx.spec (renamed from setup/onionshare-osx.spec) | 4 | ||||
-rw-r--r-- | install/onionshare-win.spec (renamed from setup/onionshare-win.spec) | 4 | ||||
-rw-r--r-- | install/onionshare.desktop (renamed from setup/onionshare.desktop) | 0 | ||||
-rw-r--r-- | install/onionshare.icns (renamed from setup/onionshare.icns) | bin | 34168 -> 34168 bytes | |||
-rw-r--r-- | install/onionshare.ico (renamed from setup/onionshare.ico) | bin | 16958 -> 16958 bytes | |||
-rw-r--r-- | install/onionshare.nsi (renamed from setup/onionshare.nsi) | 0 | ||||
-rw-r--r-- | install/onionshare80.xpm (renamed from setup/onionshare80.xpm) | 0 | ||||
-rwxr-xr-x | install/ppa_release.sh (renamed from ppa_release.sh) | 5 | ||||
-rw-r--r-- | setup.py | 5 |
18 files changed, 29 insertions, 21 deletions
@@ -15,7 +15,7 @@ Note that python-stem appears in Debian wheezy and newer (so by extension Tails ```sh sudo apt-get install -y build-essential fakeroot python-all python-stdeb python-flask python-stem python-qt4 -./build_deb.sh +./install/build_deb.sh sudo dpkg -i deb_dist/onionshare_*.deb ``` @@ -23,7 +23,7 @@ sudo dpkg -i deb_dist/onionshare_*.deb ```sh sudo yum install -y rpm-build python-flask python-stem pyqt4 -./build_rpm.sh +./install/build_rpm.sh sudo yum install -y dist/onionshare-*.rpm ``` @@ -54,7 +54,7 @@ Each time you start work: To build the .app: ```sh -pyinstaller -w -y setup/onionshare-osx.spec +pyinstaller -w -y install/onionshare-osx.spec ``` Now you should have `dist/OnionShare.app`. @@ -62,7 +62,7 @@ Now you should have `dist/OnionShare.app`. To build a .dmg (this script builds the .app for you): ```sh -./build_dmg.sh +./install/build_dmg.sh ``` Now you should have `dist/OnionShare.dmg`. @@ -95,13 +95,13 @@ If you want to sign binaries with Authenticode: ### To make a .exe: -* Open a command prompt, cd into the onionshare directory, and type: `pyinstaller -y setup\onionshare-win.spec`. Inside the `dist` folder there will be a folder called `onionshare` with `onionshare.exe` in it. +* Open a command prompt, cd into the onionshare directory, and type: `pyinstaller -y install\onionshare-win.spec`. Inside the `dist` folder there will be a folder called `onionshare` with `onionshare.exe` in it. ### To build the installer: -Note that you must have a code signing certificate installed in order to use the `build_exe.bat` script, because it tries code signing both `onionshare.exe` and `OnionShare_Setup.exe`. +Note that you must have a code signing certificate installed in order to use the `install\build_exe.bat` script, because it tries code signing both `onionshare.exe` and `OnionShare_Setup.exe`. -Open a command prompt, cd to the onionshare directory, and type: `build_exe.bat` +Open a command prompt, cd to the onionshare directory, and type: `install\build_exe.bat` A NSIS window will pop up, and once it's done you will have `dist\OnionShare_Setup.exe`. diff --git a/build_deb.sh b/install/build_deb.sh index 5461283d..6201cb8c 100755 --- a/build_deb.sh +++ b/install/build_deb.sh @@ -1,9 +1,12 @@ #!/bin/sh +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" +cd $DIR + VERSION=`cat version` # clean up from last build -rm -r deb_dist +rm -r deb_dist >/dev/null 2>&1 # build binary package python setup.py --command-packages=stdeb.command bdist_deb diff --git a/build_dmg.sh b/install/build_dmg.sh index 9b451bb5..987ccb3b 100755 --- a/build_dmg.sh +++ b/install/build_dmg.sh @@ -1,6 +1,6 @@ #!/bin/bash -ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +ROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" DMG_DIR=$ROOT/dist/dmg DMG_TMP_NAME=$ROOT/dist/tmp.dmg DMG_NAME=$ROOT/dist/OnionShare.dmg @@ -14,7 +14,7 @@ echo Deleting dist folder rm -rf $ROOT/dist &>/dev/null 2>&1 # build the .app -echo Building OnionShare.app +echo Building OnionShare.app pyinstaller -w -y $ROOT/setup/onionshare-osx.spec # create the .dmg diff --git a/build_exe.bat b/install/build_exe.bat index 04a3b2ff..b8cfc51d 100644 --- a/build_exe.bat +++ b/install/build_exe.bat @@ -1,5 +1,5 @@ REM use pyinstaller to builder a folder with onionshare.exe
-pyinstaller -y setup\onionshare-win.spec
+pyinstaller -y install\onionshare-win.spec
REM sign onionshare.exe
signtool.exe sign /v /d "OnionShare" /a /tr "http://www.startssl.com/timestamp" dist\onionshare\onionshare.exe
@@ -8,7 +8,7 @@ REM run onionshare once, to compile the .py files into .pyc dist\onionshare\onionshare.exe --help
REM build an installer, dist\OnionShare_Setup.exe
-makensisw setup\onionshare.nsi
+makensisw install\onionshare.nsi
REM sign OnionShare_Setup.exe
signtool.exe sign /v /d "OnionShare" /a /tr "http://www.startssl.com/timestamp" dist\OnionShare_Setup.exe
diff --git a/build_rpm.sh b/install/build_rpm.sh index 45fbe178..7f9d260a 100755 --- a/build_rpm.sh +++ b/install/build_rpm.sh @@ -1,9 +1,12 @@ #!/bin/sh +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" +cd $DIR + VERSION=`cat version` # clean up from last build -rm -r build dist +rm -r build dist >/dev/null 2>&1 # build binary package python setup.py bdist_rpm --requires="python-flask, python-stem, pyqt4" diff --git a/check_lacked_trans.py b/install/check_lacked_trans.py index 6dc145a7..6dc145a7 100644 --- a/check_lacked_trans.py +++ b/install/check_lacked_trans.py diff --git a/setup/dmg_background.png b/install/dmg_background.png Binary files differindex c3a02fcb..c3a02fcb 100644 --- a/setup/dmg_background.png +++ b/install/dmg_background.png diff --git a/setup/license.txt b/install/license.txt index 24243478..24243478 100644 --- a/setup/license.txt +++ b/install/license.txt diff --git a/setup/onionshare-launcher.py b/install/onionshare-launcher.py index 6a6a1627..6a6a1627 100644 --- a/setup/onionshare-launcher.py +++ b/install/onionshare-launcher.py diff --git a/setup/onionshare-osx.spec b/install/onionshare-osx.spec index dc72000e..ddc87c07 100644 --- a/setup/onionshare-osx.spec +++ b/install/onionshare-osx.spec @@ -1,5 +1,5 @@ # -*- mode: python -*-
-a = Analysis(['setup/onionshare-launcher.py'],
+a = Analysis(['install/onionshare-launcher.py'],
pathex=['.'],
hiddenimports=['onionshare', 'onionshare_gui'],
hookspath=None,
@@ -48,5 +48,5 @@ app = BUNDLE(exe, upx=True,
name='OnionShare.app',
appname='OnionShare',
- icon='setup/onionshare.icns',
+ icon='install/onionshare.icns',
version=open('version').read().strip())
diff --git a/setup/onionshare-win.spec b/install/onionshare-win.spec index 1a6f3d77..74ae03c1 100644 --- a/setup/onionshare-win.spec +++ b/install/onionshare-win.spec @@ -1,5 +1,5 @@ # -*- mode: python -*-
-a = Analysis(['setup/onionshare-launcher.py'],
+a = Analysis(['install/onionshare-launcher.py'],
hiddenimports=['onionshare', 'onionshare_gui'],
hookspath=None,
runtime_hooks=None)
@@ -29,7 +29,7 @@ exe = EXE(pyz, debug=False,
strip=False,
upx=True,
- icon='setup/onionshare.ico',
+ icon='install/onionshare.ico',
console=False )
coll = COLLECT(exe,
a.binaries,
diff --git a/setup/onionshare.desktop b/install/onionshare.desktop index 57dca00b..57dca00b 100644 --- a/setup/onionshare.desktop +++ b/install/onionshare.desktop diff --git a/setup/onionshare.icns b/install/onionshare.icns Binary files differindex f65ad12d..f65ad12d 100644 --- a/setup/onionshare.icns +++ b/install/onionshare.icns diff --git a/setup/onionshare.ico b/install/onionshare.ico Binary files differindex 8df130ef..8df130ef 100644 --- a/setup/onionshare.ico +++ b/install/onionshare.ico diff --git a/setup/onionshare.nsi b/install/onionshare.nsi index f46edbb5..f46edbb5 100644 --- a/setup/onionshare.nsi +++ b/install/onionshare.nsi diff --git a/setup/onionshare80.xpm b/install/onionshare80.xpm index a3d0f6dc..a3d0f6dc 100644 --- a/setup/onionshare80.xpm +++ b/install/onionshare80.xpm diff --git a/ppa_release.sh b/install/ppa_release.sh index 2fe74d2b..ff369a95 100755 --- a/ppa_release.sh +++ b/install/ppa_release.sh @@ -4,9 +4,12 @@ # If you want to use it, you'll need your own ~/.dput.cf and ssh key. # More info: https://help.launchpad.net/Packaging/PPA/Uploading +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && cd .. && pwd )" +cd $DIR + VERSION=`cat version` -rm -rf deb_dist +rm -rf deb_dist >/dev/null 2>&1 python setup.py --command-packages=stdeb.command sdist_dsc cd deb_dist/onionshare-$VERSION dpkg-buildpackage -S @@ -64,8 +64,8 @@ setup( include_package_data=True, scripts=['bin/onionshare', 'bin/onionshare-gui'], data_files=[ - (os.path.join(sys.prefix, 'share/applications'), ['setup/onionshare.desktop']), - (os.path.join(sys.prefix, 'share/pixmaps'), ['setup/onionshare80.xpm']), + (os.path.join(sys.prefix, 'share/applications'), ['install/onionshare.desktop']), + (os.path.join(sys.prefix, 'share/pixmaps'), ['install/onionshare80.xpm']), (os.path.join(sys.prefix, 'share/onionshare/images'), [ 'images/logo.png', 'images/drop_files.png', @@ -88,4 +88,3 @@ setup( ]) ] ) - |