DEB build scripts:

1. drop unsupported distros
2. minor improvements

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
pull/19/head
Michele Calgaro 6 years ago
parent 3998e3cd86
commit 932b8df2bd
Signed by: MicheleC
GPG Key ID: 2A75B7CA8ADED5CF

@ -52,7 +52,7 @@ case "$DISTRIBUTION" in
fi fi
;; ;;
sid|buster|stretch|wheezy|squeeze) sid|buster|stretch|wheezy)
COMPONENTS="main contrib non-free" COMPONENTS="main contrib non-free"
;; ;;
@ -62,12 +62,12 @@ case "$DISTRIBUTION" in
EXTRAPACKAGES="$EXTRAPACKAGES devuan-keyring" EXTRAPACKAGES="$EXTRAPACKAGES devuan-keyring"
;; ;;
bionic|artful|zesty|yakkety|xenial|wily|vivid|utopic|trusty|saucy|raring|quantal|precise|oneiric|natty|maverick) cosmic|bionic|artful|xenial|trusty|precise)
COMPONENTS="main restricted universe multiverse" COMPONENTS="main restricted universe multiverse"
DEBOOTSTRAPOPTS=(--variant=buildd) DEBOOTSTRAPOPTS=(--variant=buildd)
;; ;;
raspbian-jessie|raspbian-wheezy) raspbian-stretch|raspbian-jessie|raspbian-wheezy)
COMPONENTS="main contrib non-free" COMPONENTS="main contrib non-free"
DEBOOTSTRAPOPTS=(--variant=buildd --no-check-gpg) DEBOOTSTRAPOPTS=(--variant=buildd --no-check-gpg)
;; ;;
@ -88,36 +88,19 @@ case "$DISTRIBUTION" in
MIRRORSITE=http://deb.debian.org/debian MIRRORSITE=http://deb.debian.org/debian
;; ;;
squeeze)
MIRRORSITE=http://archive.debian.org/debian
;;
ceres|beowulf|ascii) ceres|beowulf|ascii)
MIRRORSITE=http://auto.mirror.devuan.org/merged MIRRORSITE=http://auto.mirror.devuan.org/merged
;; ;;
bionic|artful|zesty|yakkety|wily|vivid|trusty|precise) cosmic|bionic|artful|xenial|trusty|precise)
if [ "$ARCHITECTURE" = "amd64" ] || [ "$ARCHITECTURE" = "i386" ]; then
MIRRORSITE=http://archive.ubuntu.com/ubuntu
else
MIRRORSITE=http://ports.ubuntu.com
fi
;;
xenial)
if [ "$ARCHITECTURE" = "amd64" ] || [ "$ARCHITECTURE" = "i386" ]; then if [ "$ARCHITECTURE" = "amd64" ] || [ "$ARCHITECTURE" = "i386" ]; then
MIRRORSITE=http://archive.ubuntu.com/ubuntu MIRRORSITE=http://archive.ubuntu.com/ubuntu
else else
MIRRORSITE=http://ports.ubuntu.com MIRRORSITE=http://ports.ubuntu.com
fi fi
OTHERMIRROR="deb $MIRRORSITE $DISTRIBUTION-updates $COMPONENTS"
;;
utopic|saucy|raring|quantal|oneiric|natty|maverick)
MIRRORSITE=http://old-releases.ubuntu.com/ubuntu
;; ;;
raspbian-jessie|raspbian-wheezy) raspbian-stretch|raspbian-jessie|raspbian-wheezy)
MIRRORSITE=http://ftp.fi.muni.cz/pub/linux/raspbian/raspbian MIRRORSITE=http://ftp.fi.muni.cz/pub/linux/raspbian/raspbian
;; ;;
esac esac
@ -159,12 +142,14 @@ fi
case "$DISTRIBUTION" in case "$DISTRIBUTION" in
sid|buster|stretch|\ sid|buster|stretch|\
ceres|beowulf|ascii|\ ceres|beowulf|ascii|\
bionic|artful|zesty) raspbian-stretch|\
cosmic|bionic|artful)
PBUILDERSATISFYDEPENDSCMD="/usr/lib/pbuilder/pbuilder-satisfydepends-apt" PBUILDERSATISFYDEPENDSCMD="/usr/lib/pbuilder/pbuilder-satisfydepends-apt"
;; ;;
jessie|wheezy|squeeze|raspbian-jessie|raspbian-wheezy|\ jessie|wheezy|\
yakkety|xenial|wily|vivid|utopic|trusty|saucy|raring|quantal|precise|oneiric|natty|maverick) raspbian-jessie|raspbian-wheezy|\
xenial|trusty|precise)
PBUILDERSATISFYDEPENDSCMD="/usr/lib/pbuilder/pbuilder-satisfydepends-aptitude" PBUILDERSATISFYDEPENDSCMD="/usr/lib/pbuilder/pbuilder-satisfydepends-aptitude"
;; ;;
esac esac

@ -343,12 +343,6 @@ fi
grep -q "^include.*/usr/share/cdbs/1/rules/patchsys-quilt\.mk" "$MOD_BUILD_PKGING_PATH/rules" && \ grep -q "^include.*/usr/share/cdbs/1/rules/patchsys-quilt\.mk" "$MOD_BUILD_PKGING_PATH/rules" && \
sed -i "s/^\(include.*\/usr\/share\/cdbs\/1\/rules\/patchsys-quilt\.mk\)/#\1/" "$MOD_BUILD_PKGING_PATH/rules" sed -i "s/^\(include.*\/usr\/share\/cdbs\/1\/rules\/patchsys-quilt\.mk\)/#\1/" "$MOD_BUILD_PKGING_PATH/rules"
if [ "$bool_PREPARE_ONLY" = "y" ]; then
echo -e "${CBrown}Source code prepared for building${CNone}"
do_exit 0
fi
#---------------------------- #----------------------------
# Enable debug mode if required # Enable debug mode if required
#---------------------------- #----------------------------
@ -358,6 +352,15 @@ if [ "$bool_DEBUG_MODE" = "y" ]; then
fi fi
#----------------------------
# Exit if only preparation was required
#----------------------------
if [ "$bool_PREPARE_ONLY" = "y" ]; then
echo -e "${CBrown}Source code prepared for building${CNone}"
do_exit 0
fi
#---------------------------- #----------------------------
# Build # Build
#---------------------------- #----------------------------

@ -11,7 +11,6 @@
# #
DISTROS=" DISTROS="
# -- debian -- # -- debian --
debian 6.0 squeeze '' ''
debian 7.0 wheezy '' '' debian 7.0 wheezy '' ''
debian 8.0 jessie '' '' debian 8.0 jessie '' ''
debian 9.0 stretch '' '' debian 9.0 stretch '' ''
@ -27,20 +26,9 @@ DISTROS="
raspbian 8.0 raspbian-jessie '' '' raspbian 8.0 raspbian-jessie '' ''
raspbian 9.0 raspbian-stretch '' '' raspbian 9.0 raspbian-stretch '' ''
# -- ubuntu -- # -- ubuntu --
ubuntu 10.10 maverick '' ''
ubuntu 11.04 natty '' ''
ubuntu 11.10 oneiric '' ''
ubuntu 12.04 precise '' '' ubuntu 12.04 precise '' ''
ubuntu 12.10 quantal '' ''
ubuntu 13.04 raring '' ''
ubuntu 13.10 saucy '' ''
ubuntu 14.04 trusty '' '' ubuntu 14.04 trusty '' ''
ubuntu 14.10 utopic '' ''
ubuntu 15.04 vivid '' ''
ubuntu 15.10 wily '' ''
ubuntu 16.04 xenial '' '' ubuntu 16.04 xenial '' ''
ubuntu 16.10 yakkety '' ''
ubuntu 17.04 zesty '' ''
ubuntu 17.10 artful '' '' ubuntu 17.10 artful '' ''
ubuntu 18.04 bionic '' '' ubuntu 18.04 bionic '' ''
ubuntu 18.10 cosmic '' '' ubuntu 18.10 cosmic '' ''

@ -68,7 +68,7 @@ function _do_update()
"fetch") "fetch")
if [[ -z `grep "^$BRANCH - $MOD_PATH$" "$UPDATE_LOCK_FILENAME"` ]]; then if [[ -z `grep "^$BRANCH - $MOD_PATH$" "$UPDATE_LOCK_FILENAME"` ]]; then
cd "$MOD_PATH" &>/dev/null cd "$MOD_PATH" &>/dev/null
eval git fetch --all --prune $OPT_VERBOSE_LOG eval git fetch --all --prune $GIT_NO_RECURSE_SUBMODULES $OPT_VERBOSE_LOG
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
RESULT="OK" RESULT="OK"
else else
@ -104,7 +104,7 @@ function _do_update()
eval git reset --hard HEAD $OPT_VERBOSE_LOG eval git reset --hard HEAD $OPT_VERBOSE_LOG
eval git clean -dxff $OPT_VERBOSE_LOG eval git clean -dxff $OPT_VERBOSE_LOG
if [[ $(git rev-parse HEAD) != $(git rev-parse "origin/$BRANCH") ]]; then if [[ $(git rev-parse HEAD) != $(git rev-parse "origin/$BRANCH") ]]; then
eval git pull --rebase $GIT_NO_RECURSE_SUBMODULES $OPT_VERBOSE_LOG eval git rebase $OPT_VERBOSE_LOG
if [[ `git rev-parse HEAD` == `git rev-parse "origin/$BRANCH"` ]]; then if [[ `git rev-parse HEAD` == `git rev-parse "origin/$BRANCH"` ]]; then
RESULT="UPDATE" RESULT="UPDATE"
else else

Loading…
Cancel
Save