#!/bin/bash
# A script for building of LibUCW packages
-# (c) 2013 Pavel Charvat <pchar@ucw.cz>
+# (c) 2013--2014 Pavel Charvat <pchar@ucw.cz>
set -e
. debian/pkg-lib
--cleanup Cleanup temporary files when finished
--version=<ver> Custom version number of resulting packages (default: autodetect from git-describe)
--abi-version=<ver> Custom version number of the LibUCW's ABI (default: defined in ucw/default.cfg)
+--gen-script=<script> Custom script to postprocess
EOF
exit 1
}
echo "Creating debian/control"
build/genconf debian/control.in debian/control obj/config.mk
+ if [ -n "$GEN_SCRIPT" ] ; then
+ echo "Executing $GEN_SCRIPT"
+ $GEN_SCRIPT
+ fi
+
echo "Creating debian/changelog"
export EDITOR=true
CL=debian/changelog
ARCHONLY=
CLEANUP=
CONF=
+GEN_SCRIPT=
while [ -n "$1" ] ; do
case "$1" in
--archonly) ARCHONLY=1
;;
--abi-version=*)CONF="$CONF UCW_ABI_SUFFIX=-${1:14}"
;;
+ --gen-script=*) GEN_SCRIPT="${1:13}"
+ ;;
*) usage
;;
esac