[Midnightbsd-cvs] mports: Tools/scripts: Update for mports

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Wed Nov 14 16:08:36 EST 2007


Log Message:
-----------
Update for mports

Modified Files:
--------------
    mports/Tools/scripts:
        bump_revision.pl (r1.1.1.1 -> r1.2)
        checksize.sh (r1.1.1.1 -> r1.2)
        checksum.sh (r1.1.1.1 -> r1.2)
        modulesupdate (r1.1.1.1 -> r1.2)
        tindex (r1.1.1.1 -> r1.2)

Removed Files:
-------------
    mports/Tools/scripts:
        close-pr
        getpr
        prdone
        prpatch

-------------- next part --------------
--- Tools/scripts/prpatch
+++ /dev/null
@@ -1,10 +0,0 @@
-#!/bin/sh
-#
-# MAINTAINER= mharo at FreeBSD.org
-#
-# $FreeBSD: ports/Tools/scripts/prpatch,v 1.1 2000/05/01 19:53:53 mharo Exp $
-#
-
-patch $@ < pr-patch
-find . -name '*.orig' -print -delete
-find . -name '*.rej'  -print
Index: checksize.sh
===================================================================
RCS file: /home/cvs/mports/Tools/scripts/checksize.sh,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L Tools/scripts/checksize.sh -L Tools/scripts/checksize.sh -u -r1.1.1.1 -r1.2
--- Tools/scripts/checksize.sh
+++ Tools/scripts/checksize.sh
@@ -1,16 +1,16 @@
 #!/bin/sh
-# checksize.sh:  scan the ports collection for "size mismatch" and
+# checksize.sh:  scan the mports collection for "size mismatch" and
 # "size unknown" errors by attempting to fetch onto a full filesystem
 #
 # When called with a parameter that is the name of a category of
-# ports, the script checks that category, then checks the whole
+# mports, the script checks that category, then checks the whole
 # ports collection, redoing the named category.  When called with
 # no parameter, it checks the whole collection.
 #
 # First do something like:
 #
-#	dd if=/dev/zero of=/usr/ports/mfs.img bs=1k count=512
-#	mdconfig -a -t vnode -f /usr/ports/mfs.img -u 1
+#	dd if=/dev/zero of=/usr/mports/mfs.img bs=1k count=512
+#	mdconfig -a -t vnode -f /usr/mports/mfs.img -u 1
 #	newfs /dev/md1
 #	mount /dev/md1 /mnt
 #
@@ -30,7 +30,7 @@
 # which are intact on the main site (or vice versa).
 #
 # bugs:
-# - assumes ports tree is in /usr/ports/
+# - assumes mports tree is in /usr/mports/
 # - doesn't provide for checking only particular categories or ports
 # - support for multiple architectures is inefficient
 # - output is messy
@@ -43,11 +43,11 @@
 #
 # placed in the public domain by Trevor Johnson
 
-for category in $1 `grep ^SUBDIR /usr/ports/Makefile | cut -f3 -d\ `; do
-	cd /usr/ports/$category
+for category in $1 `grep ^SUBDIR /usr/mports/Makefile | cut -f3 -d\ `; do
+	cd /usr/mports/$category
 	for port in \
 		`grep -wc SIZE */distinfo* | grep -v :0 | cut -f1 -d\/`; do
-		cd /usr/ports/$category/$port
+		cd /usr/mports/$category/$port
 		for arc in i386; do
 			dd if=/dev/zero of=/mnt/zero
 			echo checking $arc size data for $category/$port
--- Tools/scripts/close-pr
+++ /dev/null
@@ -1,363 +0,0 @@
-#!/bin/sh
-# Program to edit problem reports for GNATS.
-# Copyright (C) 1993, 1994, 1995, 1996, 1998 Free Software Foundation, Inc.
-# Contributed by Jeffrey Osier (jeffrey at cygnus.com).
-# Networking portion written by Alec Peterson (chuckie at panix.com).
-# Local and networked versions combined by Rick Macdonald (rickm at vsl.com)
-#
-# This file is part of GNU GNATS.
-#
-# GNU GNATS is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2, or (at your option)
-# any later version.
-#
-# GNU GNATS is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU GNATS; see the file COPYING.  If not, write to
-# the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
-
-#
-# This script handles both local and network GNATS editing.
-# Execute with --mode=local or --mode=network
-#
-
-debug_print=false # or echo to get output.
-DATE=`LC_TIME=C date`
-GNATS_ROOT=${GNATS_ROOT:-/usr/local/share/gnats/gnats-db}; export GNATS_ROOT
-LIBEXECDIR=/usr/local/libexec
-GNATS_PORT=1529
-EDIT_USER=anonymous
-EDIT_PASSWD=guest
-locked=
-version=3.112
-mode=local
-
-usage="
-  local Usage:  edit-pr [-V|--version] [-h|--help] PR
-
-network Usage: nedit-pr [-V|--version] [-h|--help] [-d|--directory gnats_db_alias]
-                        [-H|--host hostname] [-P|--port port_number]
-                        [-v|--user userid]   [-w|--passwd password]  PR
-"
-
-# get current host name
-if [ -z "$HOSTNAME" ]; then
-  if [ -f /bin/hostname ] ; then HOSTNAME=`/bin/hostname`
-  elif [ -f /usr/bin/hostname ] ; then HOSTNAME=`/usr/bin/hostname`
-  # Solaris et al.
-  elif [ -f /usr/ucb/hostname ] ; then HOSTNAME=`/usr/ucb/hostname`
-  # Irix
-  elif [ -f /usr/bsd/hostname ] ; then HOSTNAME=`/usr/bsd/hostname`
-  fi
-fi
-
-# GNATS_HOST defaults to current host if GNATS_SERVER is not set.
-GNATS_HOST="gnats"
-[ -z "$GNATS_HOST" ] && GNATS_HOST="$HOSTNAME"
-
-# Newer config information? (Should the network version get this from gnatsd?)
-[ -f ${GNATS_ROOT}/gnats-adm/config ] && . ${GNATS_ROOT}/gnats-adm/config
-
-# Host-specific; must come after config file.
-MAIL_AGENT="/usr/sbin/sendmail -oi -t"
-
-# check to see if there is a $EDITOR; if not, use vi
-[ -z "$VISUAL" ] &&
-  if [ -z "$EDITOR" ]; then
-    VISUAL=vi
-  else
-    VISUAL="$EDITOR"
-  fi
-
-# Parse command line. For the non-flag argument, assume it's pr PR id.
-
-if [ $# -eq 0 ]; then
-  echo "$usage" ; exit 1
-fi
-
-while [ $# -gt 0 ]; do
-   case "$1" in
-     -V|--version|--ve*)
-       echo "$version"; exit 0
-       ;;
-     -m | --mode)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; mode="$1" ;;
-     -m=* | --mode=*) mode="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -d | --directory)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; GNATS_DB="$1" ;;
-     -d=* | --directory=*) GNATS_DB="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -H | --host)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; GNATS_HOST="$1" ;;
-     -H=* | --host=*) GNATS_HOST="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -P | --port)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; GNATS_PORT="$1" ;;
-     -P=* | --port=*) GNATS_PORT="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -v | --user)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; EDIT_USER="$1" ;;
-     -v=* | --user=*) EDIT_USER="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -w | --passwd)
-       if [ $# -eq 1 ]; then echo "$usage"; exit 1; fi
-       shift ; EDIT_PASSWD="$1" ;;
-     -w=* | --passwd=*) EDIT_PASSWD="`echo $1 | sed 's/^[-a-z]*=//'`" ;;
-
-     -h|--help*)
-       echo "$usage"; exit 0
-       ;;
-     -*)
-       echo "$usage"; exit 1
-       ;;
-
-     *)
-       if [ "`echo $1 | grep /`" != "" ]; then
-         pr=`echo $1 | awk -F"/" '{print $2}' -`
-       else
-         pr=$1
-       fi
-       prs="$prs $pr"
-       ;;
-   esac
-   shift
-done
-
-for pr_id in $prs ; do
-
-# set command here to always pass host and port, and directory if supplied
-if [ "$mode" = "network" ]; then
-    prog="nedit-pr"
-    PR_ADDR="$LIBEXECDIR/gnats/npr-addr --host=$GNATS_HOST --port=$GNATS_PORT --user=$EDIT_USER --passwd=$EDIT_PASSWD"
-    PR_EDIT="$LIBEXECDIR/gnats/npr-edit --host=$GNATS_HOST --port=$GNATS_PORT --user=$EDIT_USER --passwd=$EDIT_PASSWD"
-else
-    prog="edit-pr"
-    PR_ADDR="$LIBEXECDIR/gnats/pr-addr"
-    PR_EDIT="$LIBEXECDIR/gnats/pr-edit"
-fi
-if [ "$GNATS_DB" != "" ]; then
-    PR_ADDR="$PR_ADDR --directory=$GNATS_DB"
-    PR_EDIT="$PR_EDIT --directory=$GNATS_DB"
-fi
-
-# These traps take care of deleting all the /tmp files
-trap 'rm -f $new $new.old $change_msg ; exit 0' 0
-trap 'if [ "$locked" != "" ]; then \
-        $PR_EDIT --unlock $pr_id ; \
-	locked= ; \
-      fi ; \
-      rm -f $new $new.old $change_msg ; exit 1' 1 2 3 13 15
-
-# find a user name
-if [ "$USER" != "" ]; then
-  me=$USER
-else
-  if [ "$LOGNAME" != "" ]; then
-    me=$LOGNAME
-  else
-    echo "$prog: no user name found---set LOGNAME." ; exit 1
-  fi
-fi
-
-if [ -n "$HOSTNAME" ]; then
-  full_me="$me@$HOSTNAME"
-else
-  full_me="$me"
-fi
-
-# new = temp file to use for editing
-new="/tmp/ep$$"
-
-# lock the pr
-$debug_print "Locking $pr_id."
-lock=`$PR_EDIT --lock=$full_me $pr_id 2>&1 > $new`
-locked=t
-
-if [ "$lock" != "" ] ; then
-  echo $lock
-  exit 0
-fi
-
-# here's where we actually call the editor.
-cp $new $new.old
-/usr/bin/perl -pi -e "s|>State:.*|>State:          closed|" $new
-if cmp -s $new.old $new ; then
-  echo "$prog: PR not changed"
-  $PR_EDIT --unlock $pr_id
-  continue
-fi
-
-# error-check output by calling pr-edit --check; if mistakes exist,
-# call $VISUAL or exit
-checking=t
-while [ "$checking" != "" ]; do
-  errors="`$PR_EDIT --check < $new 2>&1`"
-  if [ "$errors" != "" ]; then
-    echo "Hit \`return\` to fix the following errors, or type \'quit\' to quit:"
-    echo "$errors"
-    read fixme
-    case "$fixme" in
-      q* | Q*)
-        echo "PR $pr_id not updated: changed file is in $new.changed"
-        mv $new $new.changed
-	$PR_EDIT --unlock $pr_id
-        exit 0
-        ;;
-    esac
-    $VISUAL $new
-  else
-    checking=
-  fi
-done
-
-# now that we have a clean new PR:
-#   - check for changes in Responsible or State
-#   - add audit trail
-#   - mail changes to relevant parties
-
-old_state="`sed -n '/^>State:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new.old`"
-new_state="`sed -n '/^>State:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new`"
-old_resp="`sed -n '/^>Responsible:/{s,^>[-a-zA-Z]*: *,,;s, *(.*,,g;p;q;}' $new.old`"
-new_resp="`sed -n '/^>Responsible:/{s,^>[-a-zA-Z]*: *,,;s, *(.*,,g;p;q;}' $new`"
-old_synopsis="`sed -n '/^>Synopsis:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new.old`"
-new_synopsis="`sed -n '/^>Synopsis:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new`"
-old_class="`sed -n '/^>Class:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new.old`"
-new_class="`sed -n '/^>Class:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new`"
-full_id="`sed -n '/^>Category:/{s,^>[-a-zA-Z]*: *,,;p;q;}' $new`/$pr_id"
-
-# If you can read this, you may have a future in sed(1) programming.
-reply_to="`sed -n \
--e '/^$/{g;s/	/ /g;s/\n/ /g;s/^.*: *//;s/ *(.*) *//;s/.*<//;s/>.*//;p;q;}' \
--e '/^Reply-To:/h' \
--e '/^Reply-To:/,/^[^ 	]/{s/^[^ 	].*//;H;}' \
--e '/^Reply-To:/,$b' \
--e '/^From:/h' \
--e '/^From:/,/^[^ 	]/{s/^[^ 	].*//;H;}' \
-$new.old`"
-x_gnats_notify="`sed -n \
--e '/^$/{g;s/	/ /g;s/\n/ /g;s/^.*: *//;s/ *(.*) *//;s/.*<//;s/>.*//;p;q;}' \
--e '/^X-GNATS-Notify:/h' \
--e '/^X-GNATS-Notify:/,/^[^ 	]/{s/^[^ 	].*//;H;}' \
--e '/^X-GNATS-Notify:/,$b' \
-$new.old`"
-
-change_msg=/tmp/ed_pr_ch$$
-
-# the following could stand to be cleaned up...
-if [ "$old_state" != "$new_state" ]; then
-  state_change=yes
-fi
-if [ "$old_resp" != "$new_resp" ]; then
-  resp_change=yes
-fi
-if [ "$old_class" != "$new_class" ]; then
-  class_change=yes
-fi
-
-if [ ! -z "$state_change" ] || [ ! -z "$resp_change" ] || \
-   [ ! -z "$class_change" ]; then
-  # we've got a change
-  mail_to="$me"
-  if [ ! -z "$state_change" ]; then
-    $debug_print "Doing state change."
-    echo State-Changed-From-To: "$old_state"'->'"$new_state" >> $change_msg
-    echo State-Changed-By: $me >> $change_msg
-    echo State-Changed-When: $DATE >> $change_msg
-    echo "State-Changed-Why: " >> $change_msg
-    if [ -e /tmp/chng.$$ ]; then
-	echo "Re-use last message (y/n)?"
-	read yesno
-	if [ "$yesno" != "y" ]; then
-	    cat /home/gnats/gnats-adm/edit-pr-msg > /tmp/chng.$$
-	fi
-    else
-	cat /home/gnats/gnats-adm/edit-pr-msg > /tmp/chng.$$
-    fi
-    $VISUAL /tmp/chng.$$
-    sed '/^GNATS:/d' /tmp/chng.$$ >> $change_msg
-    to_old=1
-    to_subm=1
-    if [ ! -z "$class_change" ] || [ ! -z "$resp_change" ]; then
-        echo "" >> $change_msg
-        echo "" >> $change_msg
-    fi
-  fi
-  if [ ! -z "$class_change" ]; then
-    $debug_print "Doing class change."
-    echo Class-Changed-From-To: "$old_class"'->'"$new_class" >> $change_msg
-    echo Class-Changed-By: $me >> $change_msg
-    echo Class-Changed-When: $DATE >> $change_msg
-    echo "Class-Changed-Why: " >> $change_msg
-    echo 'Why did the class change? (Ctrl-D to end)'
-    cat >> $change_msg
-    to_old=1
-    to_new=1
-    if [ ! -z "$resp_change" ]; then
-      echo "" >> $change_msg
-      echo "" >> $change_msg
-    fi
-  fi
-  if [ ! -z "$resp_change" ]; then
-    $debug_print "Doing responsible change."
-    echo Responsible-Changed-From-To: "$old_resp"'->'"$new_resp" >> $change_msg
-    echo Responsible-Changed-By: $me >> $change_msg
-    echo Responsible-Changed-When: $DATE >> $change_msg
-    echo "Responsible-Changed-Why: " >> $change_msg
-    echo 'Why did the responsible person change? (Ctrl-D to end)'
-    cat >> $change_msg
-    to_old=1
-    to_new=1
-  fi
-
-  echo "" >> $change_msg
-  echo "http://www.freebsd.org/cgi/query-pr.cgi?pr=$pr_id" >> $change_msg
-
-  if [ -n "$to_subm" ]; then mail_to="${reply_to}, ${mail_to}" ; fi
-  if [ -n "$x_gnats_notify" ]; then mail_to="${x_gnats_notify}, ${mail_to}" ; fi
-  if [ -n "$to_old" ] ; then mail_to="${mail_to}, `$PR_ADDR ${old_resp}`" ; fi
-  if [ -n "$to_new" ] ; then mail_to="${mail_to}, `$PR_ADDR ${new_resp}`" ; fi
-
-  # We have to quote the end of each line in the change_msg, so that sed
-  # won't try to use it as a new command.
-  $debug_print "Quoting lines in $change_msg."
-  sed -e "/^>Unformatted:/i\\
-`sed -e 's/$/ \\\\/g' $change_msg`
-" $new > $new.tmp
-  mv -f $new.tmp $new
-
-  $MAIL_AGENT << __EOF__
-To: $mail_to
-From: $me
-Subject: Re: $full_id: $new_synopsis
-
-`if [ "$old_synopsis" != "$new_synopsis" ]; then
-	echo Old Synopsis: "$old_synopsis"
-	echo New Synopsis: "$new_synopsis"
-else
-	echo Synopsis: "$old_synopsis"
-fi`
-
-`cat $change_msg`
-__EOF__
-fi
-
-echo "$prog: filing PR $full_id back into the database..."
-
-# call PR_EDIT on the new file and clean up
-$PR_EDIT < $new
-$PR_EDIT --unlock $pr_id
-
-done
-
-exit 0
Index: modulesupdate
===================================================================
RCS file: /home/cvs/mports/Tools/scripts/modulesupdate,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L Tools/scripts/modulesupdate -L Tools/scripts/modulesupdate -u -r1.1.1.1 -r1.2
--- Tools/scripts/modulesupdate
+++ Tools/scripts/modulesupdate
@@ -4,13 +4,14 @@
 #
 # $Id: modulesupdate,v 1.8 2000/04/02 05:42:12 mharo Exp $
 # $FreeBSD: ports/Tools/scripts/modulesupdate,v 1.4 2006/05/16 15:44:29 garga Exp $
+# $MidnightBSD$
 
 use strict;
 
 my $tmpdir;
 
 if ($ENV{CVSROOT} eq "") {
-	$ENV{CVSROOT}="pcvs.freebsd.org:/home/pcvs";
+	$ENV{CVSROOT}="stargazer.midnightbsd.org:/home/cvs";
 }
 
 sub goodbye
--- Tools/scripts/prdone
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/bin/sh
-#
-# MAINTAINER= mharo at FreeBSD.org
-#
-# $FreeBSD: ports/Tools/scripts/prdone,v 1.1 2000/05/01 19:53:54 mharo Exp $
-#
-
-# $Id: prdone,v 1.4 2000/04/22 21:48:53 mharo Exp $
-
-if [ $# -lt 1 ] ; then
-	echo "prdone prnumber [ci]"
-	exit 1
-fi
-
-file=$1; shift
-action=$1;
-
-if [ "X$file" = "Xci" ] ; then
-	echo "hey, dumbass, the PR number is not 'ci'"
-	exit 1
-fi
-
-rm -f pr-patch
-rm -f MAINTAINER_WAIT
-
-if [ "X$action" = "Xci" ] ; then
-	echo "preparing commit"
-cvsmsg=cvsmsg
-	cp /home/ncvs/CVSROOT/rcstemplate CVS/Template
-
-	from=`grep From: $file | sed -e 's/From: //' -e 's/\@/\\\@/g'`
-	name=`grep Originator: $file | sed -e 's/>Originator: //'`
-	synopsis=`grep Synopsis: $file | sed -e 's/>Synopsis: //'`
-	cp /home/ncvs/CVSROOT/rcstemplate $cvsmsg
-	chmod +w $cvsmsg
-	/usr/bin/perl -pi -e "s,^PR:,PR:\t\t$file," $cvsmsg
-	/usr/bin/perl -pi -e "s,^Submitted by:,Submitted by:\t$name <$from>," $cvsmsg
-	echo "$synopsis" > $cvsmsg.tmp
-	cat $cvsmsg >> $cvsmsg.tmp
-	mv $cvsmsg.tmp $cvsmsg
-	vi $cvsmsg
-
-	cvs -d mharo at freefall.freebsd.org:/home/ncvs ci -F $cvsmsg
-	rm -f $cvsmsg
-	echo "done"
-else
-	echo "PR: $file" > MAINTAINER_WAIT
-	echo ""
-	echo "Don't forget to email" `grep MAINTAINER Makefile`
-	echo ""
-fi
-
-# remove pr number after we commit as I always forget to track PR number
-rm -f $file
-
-ssh freefall.freebsd.org -t edit-pr $file
--- Tools/scripts/getpr
+++ /dev/null
@@ -1,93 +0,0 @@
-#!/usr/bin/perl
-#
-# MAINTAINER= mharo at FreeBSD.org
-#
-# $FreeBSD: ports/Tools/scripts/getpr,v 1.5 2005/01/09 10:21:17 krion Exp $
-#
-
-use strict;
-
-my $pr = shift;
-my $user = shift;
-my $ssh;
-
-if ($pr eq "") {
-	print STDERR "getpr prnum [username]\n";
-	exit 1
-}
-
-if( !defined $ENV{"CVS_RSH"} ) {
-        $ssh = "ssh";
-} else {
-	$ssh = $ENV{"CVS_RSH"};
-}
-
-if ($user ne "") {
-	$user = "$user@";
-}
-
-# get the PR off of freefall
-
-open(D, "> $pr") or die "$pr: $!";
-open(PATCH, "> pr-patch") or die "pr-patch: $!";
-open(PR, " ${ssh} ${user}freefall.freebsd.org query-pr.real -F $pr | ") or die $!;
-
-my $fix = "";
-my $infix = 0;
-
-while(<PR>) {
-	print D;
-
-	if (m/^>Release-Note:/) {
-		$infix = 0;
-	}
-	if ($infix == 1) {
-		print PATCH;
-	}
-	if (m/^>Fix:/) {
-		$infix = 1;
-	}
-}
-close(D);
-close(PR);
-close(PATCH);
-
-# decode the submission attempting to find a file attachment by extension
-# .tar.gz, .shar or just .gz, if not found, display what we think of as
-# the file submission (probably just a patch)
-
-open(PATCH, "pr-patch");
-while(<PATCH>) {
-	if (m/^# This is a shell archive.  Save it in a file, remove anything before/) {
-		&shar;
-		exit;
-	}
-	if (m/^begin (\d+)? (.*)/) {
-		&uudecode($2);
-		close(PATCH);
-		exit;
-	}
-}
-
-close(PATCH);
-system("more pr-patch");
-
-exit;
-
-sub uudecode {
-	my ($fname) = @_;
-
-	$fname =~ s/\s+$//g;
-	print "$fname\n";
-
-	print `uudecode pr-patch`;
-	if (($fname =~ m/.tar.gz$/) || ($fname =~ m/.tgz$/)) {
-		print "you may extract this tarball by typing tar xvzf $fname\n";
-	} elsif ($fname =~ m/.gz$/) {
-		print `gunzip $fname`;
-	}
-}
-
-sub shar {
-	print "you may extract this shar archive by typing sh pr-patch\n";
-}
Index: tindex
===================================================================
RCS file: /home/cvs/mports/Tools/scripts/tindex,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L Tools/scripts/tindex -L Tools/scripts/tindex -u -r1.1.1.1 -r1.2
--- Tools/scripts/tindex
+++ Tools/scripts/tindex
@@ -1,9 +1,9 @@
 #!/bin/sh
 #
-# INDEX build tinderbox script.  Build an INDEX for all supported FreeBSD branches
+# INDEX build tinderbox script.  Build an INDEX for all supported BSD branches
 # using the latest value of OSVERSION according to the src trees.  If the build
-# fails, yowl about it on ${REPORT_ADDRESS}  If not, copy the index to www.freebsd.org so
-# that 'make fetchindex' sees it.
+# fails, yowl about it on ${REPORT_ADDRESS}  If not, copy the index to 
+# www.midnightbsd.org so that 'make fetchindex' sees it.
 #
 # When INDEX is broken, assemble the list of committers who touched files
 # on the most recent 'cvs update', and put those committers "on the hook".
@@ -21,15 +21,13 @@
 # Where to scp the resulting indexes after build
 SCP_DEST_HOST=root at localhost
 SCP_DEST_TMP=/tmp
-SCP_DEST_DIR=/usr/local/www/ports
+SCP_DEST_DIR=/home/mbsd/docs/ports
 
 # Location of ports tree and source trees
-export BASEDIR=/local0/tmp/kris/tindex
-export PORTSDIR=${BASEDIR}/ports
-export SRCDIR4=${BASEDIR}/src.4
-export SRCDIR5=${BASEDIR}/src.5
-export SRCDIR6=${BASEDIR}/src.6
-export SRCDIR7=${BASEDIR}/src.7
+export BASEDIR=/home/tindex
+export PORTSDIR=${BASEDIR}/mports
+export SRCDIR01=${BASEDIR}/src.01
+export SRCDIR02=${BASEDIR}/src.02
 
 # SSH key to use for copying INDEXes to www host (if non-default)
 export SSHKEY="-i /home/kris/.ssh/id_dsa-index"
@@ -39,12 +37,12 @@
 blame() {
   # Find out who is responsible for current version of file $1
 
-  # Fastest way to extract is from the CVS "FreeBSD" tag
-  ident=$(ident $1 2>/dev/null | grep '$FreeBSD')
-  who=$(echo $ident | awk '{print $6}')
+  # Fastest way to extract is from the CVS "MidnightBSD" tag
+  ident=$(ident $1 2>/dev/null | grep '$MidnightBSD')
+  who=$(echo $ident | awk '{print $11}')
 
   if [ -z "$ident" ]; then
-    # No FreeBSD tag, fall back to slower method of parsing cvs logs.
+    # No MidnightBSD tag, fall back to slower method of parsing cvs logs.
     rev=$(cvs status $1 2>/dev/null | grep 'Working revision:' | awk '{print $3}')
     if [ "$rev" != "No" ]; then    # "No" means not under CVS control
       ident=$(cvs -Rq log -r$rev $1 | grep "^date:" | head -1 | sed 's,;,,g')
@@ -130,24 +128,16 @@
 export INDEX_QUIET=1
 
 # First update the source trees to get current OSVERSION
-cd ${SRCDIR4}/sys/sys
-cvs -Rq update -PdA -r RELENG_4 param.h
-OSVERSION4=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR4}/sys/sys/param.h)
-
-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)
-
-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)
+cd ${SRCDIR01}/sys/sys
+cvs -Rq update -PdA -r RELENG_0_1 param.h
+OSVERSION01=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR01}/sys/sys/param.h)
 
-cd ${SRCDIR7}/sys/sys
+cd ${SRCDIR02}/sys/sys
 cvs -Rq update -PdA param.h
-OSVERSION7=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR7}/sys/sys/param.h)
+OSVERSION02=$(awk '/^#define __FreeBSD_version/ {print $3}' < ${SRCDIR02}/sys/sys/param.h)
 
 cd ${PORTSDIR}
-rm -f INDEX INDEX.bz2 INDEX-5 INDEX-5.bz2 INDEX-6 INDEX-6.bz2 INDEX-7 INDEX-7.bz2
+rm -f INDEX INDEX.bz2 INDEX-6 INDEX-6.bz2
 (cvs -Rq update -PdA 2>1 ) > cvs.log
 if grep -q ^C cvs.log ; then
   (echo "cvs update failed with conflicts:";
@@ -155,8 +145,8 @@
     exit 1
 fi
   
-export OSVERSION=${OSVERSION4}
-BRANCH=4.x
+export OSVERSION=${OSVERSION01}
+BRANCH=0.1
 echo "Building INDEX for ${BRANCH} with OSVERSION=${OSVERSION}"
 cd ${PORTSDIR}
 ((make index 2> index.err) > index.out) || indexfail ${BRANCH}
Index: bump_revision.pl
===================================================================
RCS file: /home/cvs/mports/Tools/scripts/bump_revision.pl,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L Tools/scripts/bump_revision.pl -L Tools/scripts/bump_revision.pl -u -r1.1.1.1 -r1.2
--- Tools/scripts/bump_revision.pl
+++ Tools/scripts/bump_revision.pl
@@ -25,7 +25,7 @@
 	exit 1;
 }
 
-my $INDEX="/usr/ports/INDEX";
+my $INDEX="/usr/mports/INDEX";
 my $USER=$ENV{USER};
 {
     $opt_i="";
Index: checksum.sh
===================================================================
RCS file: /home/cvs/mports/Tools/scripts/checksum.sh,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L Tools/scripts/checksum.sh -L Tools/scripts/checksum.sh -u -r1.1.1.1 -r1.2
--- Tools/scripts/checksum.sh
+++ Tools/scripts/checksum.sh
@@ -2,7 +2,7 @@
 #
 # Created by:	Alexander Langer <alex at big.endian.de>
 # Created on:	May 22, 2000
-# MAINTAINER=	alex at FreeBSD.org
+# MAINTAINER=	ports at MidnightBSD.org
 
 if [ -z $1 ]; then
 	echo "Usage: $0 <portname> ..."
@@ -13,7 +13,7 @@
 	TMPDIR=/tmp
 fi
 if [ -z $PORTSDIR ]; then
-	PORTSDIR=/usr/ports
+	PORTSDIR=/usr/mports
 fi
 
 while [ ! -z $1 ]; do
@@ -40,7 +40,7 @@
 	mkdir $TMPDIR/checksum/new
 
 	echo Fetching $broken
-	fetch ftp://ftp.FreeBSD.ORG/pub/FreeBSD/distfiles/$broken
+	fetch ftp://ftp.MidnightBSD.ORG/pub/MidnightBSD/distfiles/$broken
 
 	if [ ! -r $broken ]; then
 		echo "File $broken not found, fetch error?"
@@ -51,30 +51,30 @@
 		cd orig
 		tar -zxf ../$broken || gunzip -c ../$broken > ${broken%.gz}
 		cd ../new
-		tar -zxf $PORTSDIR/distfiles/$broken || \
-			gunzip -c $PORTSDIR/distfiles/$broken > ${broken%.gz}
+		tar -zxf $PORTSDIR/Distfiles/$broken || \
+			gunzip -c $PORTSDIR/Distfiles/$broken > ${broken%.gz}
 		cd ..
 	elif file $broken | grep "compress'd data 16 bits" >/dev/null; then
 		cd orig
 		tar -zxf ../$broken
 		cd ../new
-		tar -zxf $PORTSDIR/distfiles/$broken
+		tar -zxf $PORTSDIR/Distfiles/$broken
 		cd ..
 	elif file $broken | grep "zip archive file" >/dev/null; then
 		cd orig
 		unzip ../$broken
 		cd ../new
-		unzip $PORTSDIR/distfiles/$broken
+		unzip $PORTSDIR/Distfiles/$broken
 		cd ..
 	elif file $broken | grep "bzip compressed data" >/dev/null; then
 		cd orig
 		tar -yxf ../$broken
 		cd ../new
-		tar -yxf $PORTSDIR/distfiles/$broken
+		tar -yxf $PORTSDIR/Distfiles/$broken
 		cd ..
 	else
 		cp $broken orig/
-		cp $PORTSDIR/distfiles/$broken new/
+		cp $PORTSDIR/Distfiles/$broken new/
 	fi
 
 	echo Diff follows:


More information about the Midnightbsd-cvs mailing list