As a preamble to the impending next attempt at 64-bit changes, below find a script (given the name "zgress" here at elsie) to check on differences between two time zone implementations. --ado #!/bin/sh # Accept the names of two time zone package source directories (A and B). # Do a "make install" from each directory to temporary directories. # Apply the created "zdump" programs to all the created binary data files: # the A zdump to the A data (yielding AA results) # the A zdump to the B data (yielding AB results) # the B zdump to the A data (yielding BA results) # the B zdump to the B data (yielding BB results) # Report on differences. O=`basename "$0"` case $# in 2) ;; *) echo "$O: usage is $O atzsourcedir btzsourcedir" 1>&2 exit 1 ;; esac T=/tmp/,zgress$$ trap 'rm -f -r $T*' 0 1 2 3 15 # Step 1: do "make"s for both the A and B versions for pass in a b do ( cd "$1"; make clean; make install TOPDIR=$T$pass ) || exit 1 shift done # Step 2: apply both the A and B zdumps to both the A and B data for prog in a b do for data in a b do zdump=$T$prog/etc/zdump zoneinfo=$T$data/etc/zoneinfo $zdump -v `find $zoneinfo ! -type d -print | sort` 2>&- | sed "s@$zoneinfo/@@" > $T$prog$data done done # Step 3: do comparisons ls -l $T[ab][ab] left=aa for right in ab ba bb do diff $T$left $T$right | sed "s/^/$left vs. $right:/" done
participants (1)
-
Arthur David Olson