aboutsummaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
Diffstat (limited to 'Tools')
-rwxr-xr-xTools/scripts/tindex29
1 files changed, 25 insertions, 4 deletions
diff --git a/Tools/scripts/tindex b/Tools/scripts/tindex
index c55bad1d8d0f..b55e079739b6 100755
--- a/Tools/scripts/tindex
+++ b/Tools/scripts/tindex
@@ -32,6 +32,7 @@ export PORTSDIR=${BASEDIR}/ports
export SRCDIR5=${BASEDIR}/src.5
export SRCDIR6=${BASEDIR}/src.6
export SRCDIR7=${BASEDIR}/src.7
+export SRCDIR8=${BASEDIR}/src.8
# Target architecture if not set in the environment
if [ "${ARCH}" = "" ]; then
@@ -139,18 +140,23 @@ export INDEX_QUIET=1
# First update the source trees to get current OSVERSION
cd ${SRCDIR5}/sys/sys
cvs -Rq update -PdA -r RELENG_5 param.h
-OSVERSION5=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR5}/sys/sys/param.h)
+OSVERSION5=$(awk '/^#define[[:blank:]]__FreeBSD_version/ {print $3}' < ${SRCDIR5}/sys/sys/param.h)
cd ${SRCDIR6}/sys/sys
cvs -Rq update -PdA -r RELENG_6 param.h
-OSVERSION6=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR6}/sys/sys/param.h)
+OSVERSION6=$(awk '/^#define[[:blank:]]__FreeBSD_version/ {print $3}' < ${SRCDIR6}/sys/sys/param.h)
cd ${SRCDIR7}/sys/sys
+cvs -Rq update -PdA -r RELENG_7 param.h
+OSVERSION7=$(awk '/^#define[[:blank:]]__FreeBSD_version/ {print $3}' < ${SRCDIR7}/sys/sys/param.h)
+
+cd ${SRCDIR8}/sys/sys
cvs -Rq update -PdA param.h
-OSVERSION7=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR7}/sys/sys/param.h)
+OSVERSION8=$(awk '/^#define[[:blank:]]__FreeBSD_version/ {print $3}' < ${SRCDIR8}/sys/sys/param.h)
+
cd ${PORTSDIR}
-rm -f INDEX-5 INDEX-5.bz2 INDEX-6 INDEX-6.bz2 INDEX-7 INDEX-7.bz2
+rm -f INDEX-5 INDEX-5.bz2 INDEX-6 INDEX-6.bz2 INDEX-7 INDEX-7.bz2 INDEX-8 INDEX-8.bz2
(cvs -Rq update -PdA 2>1 ) > cvs.log
if grep -q ^C cvs.log ; then
(echo "cvs update failed with conflicts:";
@@ -203,5 +209,20 @@ bzip2 -kf ${PORTSDIR}/INDEX-7
scp -q ${SSHKEY} ${PORTSDIR}/INDEX-7 ${PORTSDIR}/INDEX-7.bz2 ${SCP_DEST_HOST}:${TMPDIR} || mail -s "Cannot copy INDEX-7 to temp dir" ${ERROR_ADDRESS}
ssh ${SCP_DEST_HOST} "/bin/mv ${TMPDIR}/INDEX-7 ${SCP_DEST_DIR}; /bin/mv ${TMPDIR}/INDEX-7.bz2 ${SCP_DEST_DIR}; rmdir ${TMPDIR}" || mail -s "Cannot move INDEX-7 to final dir" ${ERROR_ADDRESS}
+BRANCH=8.x
+export OSVERSION=${OSVERSION8}
+echo "Building INDEX for ${BRANCH} with OSVERSION=${OSVERSION}"
+cd ${PORTSDIR}
+((make index 2> index.err) > index.out) || indexfail ${BRANCH}
+if [ -s index.err ]; then
+ indexfail ${BRANCH}
+fi
+checkfixed ${BRANCH}
+
+createtmpdir
+bzip2 -kf ${PORTSDIR}/INDEX-8
+scp -q ${SSHKEY} ${PORTSDIR}/INDEX-8 ${PORTSDIR}/INDEX-8.bz2 ${SCP_DEST_HOST}:${TMPDIR} || mail -s "Cannot copy INDEX-8 to temp dir" ${ERROR_ADDRESS}
+ssh ${SCP_DEST_HOST} "/bin/mv ${TMPDIR}/INDEX-8 ${SCP_DEST_DIR}; /bin/mv ${TMPDIR}/INDEX-8.bz2 ${SCP_DEST_DIR}; rmdir ${TMPDIR}" || mail -s "Cannot move INDEX-8 to final dir" ${ERROR_ADDRESS}
+
# All indexes built successfully, clear the hook
rm -f ${PORTSDIR}/hook