Permalink
Browse files

Update build scripts from master

  • Loading branch information...
The-Compiler committed Jul 26, 2016
1 parent 614794a commit 2795ae947817f494c58b49959346b48779bb077c
Showing with 17 additions and 8 deletions.
  1. +2 −7 scripts/dev/Makefile-dmg
  2. +15 −1 scripts/dev/build_release.py
View
@@ -24,7 +24,7 @@ SOURCE_DIR ?= .
SOURCE_FILES ?= dist/qutebrowser.app COPYING
TEMPLATE_DMG ?= template.dmg
TEMPLATE_SIZE ?= 120m
TEMPLATE_SIZE ?= 300m
################################################################################
# DMG building. No editing should be needed beyond this point.
@@ -37,17 +37,12 @@ WC_DIR=wc
.PHONY: all
all: $(MASTER_DMG)
$(TEMPLATE_DMG): $(TEMPLATE_DMG).bz2
bunzip2 -k $<
$(TEMPLATE_DMG).bz2:
$(TEMPLATE_DMG):
@echo
@echo --------------------- Generating empty template --------------------
mkdir template
hdiutil create -fs HFSX -layout SPUD -size $(TEMPLATE_SIZE) "$(TEMPLATE_DMG)" -srcfolder template -format UDRW -volname "$(NAME)" -quiet
rmdir template
bzip2 "$(TEMPLATE_DMG)"
@echo
$(WC_DMG): $(TEMPLATE_DMG)
cp $< $@
@@ -28,6 +28,7 @@
import subprocess
import argparse
import tarfile
import tempfile
import collections
sys.path.insert(0, os.path.join(os.path.dirname(__file__), os.pardir,
@@ -94,7 +95,7 @@ def build_osx():
utils.print_title("Updating 3rdparty content")
update_3rdparty.update_pdfjs()
utils.print_title("Building .app via pyinstaller")
call_tox('pyinstaller')
call_tox('pyinstaller', '-r')
utils.print_title("Building .dmg")
subprocess.check_call(['make', '-f', 'scripts/dev/Makefile-dmg'])
utils.print_title("Cleaning up...")
@@ -103,6 +104,17 @@ def build_osx():
for d in ['dist', 'build']:
shutil.rmtree(d)
utils.print_title("Running smoke test")
with tempfile.TemporaryDirectory() as tmpdir:
subprocess.check_call(['hdiutil', 'attach', 'qutebrowser.dmg',
'-mountpoint', tmpdir])
try:
binary = os.path.join(tmpdir, 'qutebrowser.app', 'Contents',
'MacOS', 'qutebrowser')
smoke_test(binary)
finally:
subprocess.check_call(['hdiutil', 'detach', tmpdir])
def build_windows():
"""Build windows executables/setups."""
@@ -116,6 +128,8 @@ def build_windows():
python_x86 = r'C:\Python{}_x32'.format(ver)
python_x64 = r'C:\Python{}'.format(ver)
utils.print_title("Rebuilding tox environment")
call_tox('cxfreeze-windows', '-r', '--notest')
utils.print_title("Running 32bit freeze.py build_exe")
call_tox('cxfreeze-windows', 'build_exe', python=python_x86)
utils.print_title("Running 32bit freeze.py bdist_msi")

0 comments on commit 2795ae9

Please sign in to comment.