2008-05-24 18:24:25 -04:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
# Basic sanity check for tiffcp + tiffsplit
|
|
|
|
#
|
|
|
|
# First we use tiffcp to join our test files into a multi-frame TIFF
|
|
|
|
# and then we use tiffsplit to split them out again.
|
|
|
|
#
|
|
|
|
. ${srcdir}/common.sh
|
|
|
|
conjoined=deleteme-conjoined-$$.tif
|
|
|
|
splitfile=deleteme-split-$$
|
|
|
|
|
|
|
|
operation=tiffcp
|
|
|
|
${TIFFCP} ${IMG_UNCOMPRESSED} ${conjoined}
|
|
|
|
status=$?
|
|
|
|
|
|
|
|
if test $status -eq 0
|
|
|
|
then
|
|
|
|
operation=tiffsplit
|
|
|
|
${TIFFSPLIT} ${conjoined} ${splitfile}
|
|
|
|
status=$?
|
|
|
|
fi
|
|
|
|
|
|
|
|
if test $status -eq 0
|
|
|
|
then
|
2008-12-31 18:48:01 -05:00
|
|
|
:
|
2008-05-24 18:24:25 -04:00
|
|
|
rm -f ${conjoined} ${splitfile}*
|
|
|
|
else
|
|
|
|
echo "Test failed (${operation} returned ${status}). Please inspect these output files:"
|
|
|
|
echo " " ${conjoined} ${splitfile}* ${reconjoined}
|
|
|
|
fi
|
|
|
|
|
|
|
|
exit $status
|