diff options
Diffstat (limited to 'gnuzilla/build')
-rwxr-xr-x | gnuzilla/build | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/gnuzilla/build b/gnuzilla/build new file mode 100755 index 0000000..372b339 --- /dev/null +++ b/gnuzilla/build @@ -0,0 +1,38 @@ +#!/bin/sh + +set -eu + +MKBUILDDEPS_TOOL='/usr/bin/apt-get -o Debug::pkgProblemResolver=yes' +MKBUILDDEPS_TOOL="${MKBUILDDEPS_TOOL} --no-install-recommends -y" + +# Get the newest version. +sed_s='s/uscan: Newest version of icecat on remote site is \([^,][^,]*\),' +sed_s="${sed_s}"' local version is 0$/\1/p;' +version="$(uscan --package 'icecat' --upstream-version '0' \ + --watchfile "${0%/*}/watch" 2>&1 | sed -n "${sed_s}")" +upstream_version="${version%-*}" + +# Download. +uscan --package icecat --upstream-version 0 --watchfile ../watch --download \ + --download-version "${version}" + +# Create package directory and mount a temporary file system on it. +mkdir "icecat-${upstream_version}/" +sudo mount -t tmpfs tmpfs "icecat-${upstream_version}/" + +# Unpack package. +tar -xjf "icecat-${version}.tar.bz2" + +# Make sure build dependencies are installed. +#mk-build-deps -i -t "${MKBUILDDEPS_TOOL}" -r -s sudo \ +# "icecat-${upstream_version}/debian/control" + +# Build source and binary packages. +cd "icecat-${upstream_version}/" +#dpkg-buildpackage -us -uc +bash +cd ../ + +# Unmount and remove package directory. +sudo umount "icecat-${upstream_version}/" +rmdir "icecat-${upstream_version}/" |