1 #! /bin/sh -- 2 # 3 # $NetBSD: checkflist,v 1.11 1999/11/27 13:10:45 mrg Exp $ 4 # 5 # Verify output of makeflist against contents of $DESTDIR. 6 7 [ "$DESTDIR" ] || { 8 echo DESTDIR must be set 9 exit 1 10 } 11 12 origin=. 13 tmpname=/tmp/_CHECK.$$ 14 15 xargs="" 16 dargs="" 17 18 # handle args 19 while : ; do 20 case $1 in 21 -x11) 22 xargs="-x" 23 origin=./usr/X11R6 24 ;; 25 -both) 26 xargs="-b" 27 ;; 28 -secr) 29 dargs="-d" 30 ;; 31 -cryptint) 32 dargs="-i" 33 ;; 34 -*) 35 cat 1>&2 <<USAGE 36 Usage: $0 [-x11|-both] [-secr] 37 -x11 check only x11 lists 38 -both check netbsd + x11 lists 39 -secr check domestic ("secr") lists 40 -cryptint check international crypto ("cryptint") lists 41 USAGE 42 exit 1 43 ;; 44 *) 45 break 46 ;; 47 esac 48 shift 49 done 50 51 sh makeflist $xargs $dargs > $tmpname 52 53 ( cd $DESTDIR ; find $origin \( -type d -o -type f -o -type l \) ) | sort | \ 54 diff $tmpname - 55 /bin/rm -f $tmpname 56