kit.sh revision 0c27b3fe77ac1d5094ba3521e8142d9e7973133f
#
# Copyright (C) 2000-2004, 2007-2010, 2012-2016 Internet Systems Consortium, Inc. ("ISC")
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
# $Id$
# Make a release kit
#
# Usage: sh kit.sh tag tmpdir
#
#
# To build a snapshot release, use the pseudo-tag "snapshot".
#
#
case "${1:-}" in
--remote=*)
remote="${1}"
shift
;;
esac
case $# in
3)
case "$1" in
snapshot) ;;
*) echo "usage: sh kit.sh [snapshot] gittag tmpdir" >&2
exit 1
;;
esac
snapshot=true;
releasetag=$2
tag=$2
tmpdir=$3
;;
2)
tag=$1
tmpdir=$2
*) snapshot=false ;;
esac
;;
*) echo "usage: sh kit.sh [snapshot] gittag tmpdir" >&2
exit 1
;;
esac
# create tmpdir
test -d $tmpdir ||
exit 1
}
cd $tmpdir || {
echo "$0: cd $tmpdir failed"
exit 1
}
if [ -z "$hash" ]; then
fi
if [ -z "$hash" ]; then
echo "Unable to determine hash for $tag, aborting."
exit 1
fi
exit 1
}
echo "$0: could not get 'version' file" >&2
exit 1
}
if $snapshot
then
fi
echo "building release kit for BIND version $version, hold on..."
test ! -d $topdir || {
exit 1
}
cd $topdir || exit 1
if $snapshot
then
cat <<EOF >version
MAJORVER=$MAJORVER
MINORVER=$MINORVER
PATCHVER=$PATCHVER
RELEASETYPE=$RELEASETYPE
RELEASEVER=$RELEASEVER
EXTENSIONS=$EXTENSIONS
EOF
fi
# Omit some files and directories from the kit.
#
# contain any files and should therefore be absent in the
# checked-out tree, but they did exist at some point and
# we still delete them from releases just in case something
# gets accidentally resurrected.
# Remove everything but mksymtbl.pl and bindkeys.pl from util
# Remove all .gitignore files
# Remove branchsync.dat, if present
rm -f branchsync.dat
# populate srcid file
echo "SRCID=$shorthash" > srcid
# The following files should be executable.
# Fix up releases with libbind.
then
fi
# Fix files which should be using DOS style newlines
winnames="-name *.mak -or -name *.dsp -or -name *.dsw -or -name *.txt -or -name *.bat"
do
done
# check that documentation has been updated properly; issue a warning
# if it hasn't
ok=
do
then
fi
done
then
echo "WARNING: ARM source is newer than the html version."
fi
then
echo "WARNING: ARM source is newer than the PDF version."
fi
do
docbookfile=$f
then
echo "WARNING: $docbookfile is newer than the html version."
fi
done
# build the tarball
cd .. || exit 1