diff options
author | P. J. McDermott <pj@pehjota.net> | 2018-05-05 23:41:52 (EDT) |
---|---|---|
committer | P. J. McDermott <pj@pehjota.net> | 2018-05-16 16:53:18 (EDT) |
commit | bda7d16961a3f1e54ca707dafdeb21da3ec273a0 (patch) | |
tree | b448683b935bb33c4d8f712973876f85454578e1 /gnuzilla | |
parent | c75ed9c4003b292d0cb226106e526901a21c5fe2 (diff) | |
download | icecat-bda7d16961a3f1e54ca707dafdeb21da3ec273a0.zip icecat-bda7d16961a3f1e54ca707dafdeb21da3ec273a0.tar.gz icecat-bda7d16961a3f1e54ca707dafdeb21da3ec273a0.tar.bz2 |
gnuzilla/build: Add headers and fix paths in uscan command
Diffstat (limited to 'gnuzilla')
-rwxr-xr-x | gnuzilla/build | 31 |
1 files changed, 29 insertions, 2 deletions
diff --git a/gnuzilla/build b/gnuzilla/build index 372b339..a81d85a 100755 --- a/gnuzilla/build +++ b/gnuzilla/build @@ -5,6 +5,17 @@ set -eu MKBUILDDEPS_TOOL='/usr/bin/apt-get -o Debug::pkgProblemResolver=yes' MKBUILDDEPS_TOOL="${MKBUILDDEPS_TOOL} --no-install-recommends -y" +header() +{ + local fmt="${1}" + shift 1 + + printf "\n${fmt}\n" "${@}" + printf "${fmt}\n\n" "${@}" | tr -C '\n' '-' + + return 0 +} + # 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;' @@ -12,9 +23,19 @@ version="$(uscan --package 'icecat' --upstream-version '0' \ --watchfile "${0%/*}/watch" 2>&1 | sed -n "${sed_s}")" upstream_version="${version%-*}" +printf '%-47s %31s\n' "icecat (${version})" \ + "$(LC_ALL='POSIX' date '+%a, %d %b %Y %H:%M:%S %z')" +cat <<EOF +================================================================================ +EOF + +header 'Download Upstream Sources' + # Download. -uscan --package icecat --upstream-version 0 --watchfile ../watch --download \ - --download-version "${version}" +uscan --package icecat --upstream-version 0 --watchfile "${0%/*}/watch" \ + --download --download-version "${version}" --destdir '.' + +header 'Unpack Package' # Create package directory and mount a temporary file system on it. mkdir "icecat-${upstream_version}/" @@ -23,16 +44,22 @@ sudo mount -t tmpfs tmpfs "icecat-${upstream_version}/" # Unpack package. tar -xjf "icecat-${version}.tar.bz2" +header 'Install Build Dependencies' + # Make sure build dependencies are installed. #mk-build-deps -i -t "${MKBUILDDEPS_TOOL}" -r -s sudo \ # "icecat-${upstream_version}/debian/control" +header 'Build Package' + # Build source and binary packages. cd "icecat-${upstream_version}/" #dpkg-buildpackage -us -uc bash cd ../ +header 'Clean Up' + # Unmount and remove package directory. sudo umount "icecat-${upstream_version}/" rmdir "icecat-${upstream_version}/" |