Revision: 41906
http://brlcad.svn.sourceforge.net/brlcad/?rev=41906&view=rev
Author: starseeker
Date: 2011-01-04 01:07:18 +0000 (Tue, 04 Jan 2011)
Log Message:
-----------
Try to structure the regress scripts so they will work both with CMake and
autotools
Modified Paths:
--------------
brlcad/trunk/regress/bots.sh
brlcad/trunk/regress/fastgen.sh
brlcad/trunk/regress/gqa.sh
brlcad/trunk/regress/iges.sh
brlcad/trunk/regress/library.sh
brlcad/trunk/regress/lights.sh
brlcad/trunk/regress/mged.sh
brlcad/trunk/regress/mged_test.sh
brlcad/trunk/regress/moss.sh
brlcad/trunk/regress/shaders.sh
brlcad/trunk/regress/solids.sh
brlcad/trunk/regress/spdi.sh
brlcad/trunk/regress/weight.sh
Modified: brlcad/trunk/regress/bots.sh
===================================================================
--- brlcad/trunk/regress/bots.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/bots.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -45,17 +45,17 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find MGED, aborting"
exit 1
fi
-RT="`ensearch rt/rt`"
+RT="`ensearch rt`"
if test ! -f "$RT" ; then
echo "Unable to find RT, aborting"
exit 1
fi
-PIXDIFF="`ensearch util/pixdiff`"
+PIXDIFF="`ensearch pixdiff`"
if test ! -f "$PIXDIFF" ; then
echo "Unable to find pixdiff, aborting"
exit 1
Modified: brlcad/trunk/regress/fastgen.sh
===================================================================
--- brlcad/trunk/regress/fastgen.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/fastgen.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -45,12 +45,12 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-F4G="`ensearch conv/fast4-g`"
+F4G="`ensearch fast4-g`"
if test ! -f "$F4G" ; then
echo "Unable to find fast4-g, aborting"
exit 1
fi
-G_DIFF="`ensearch gtools/g_diff`"
+G_DIFF="`ensearch g_diff`"
if test ! -f "$G_DIFF" ; then
echo "Unable to find g_diff, aborting"
exit 1
Modified: brlcad/trunk/regress/gqa.sh
===================================================================
--- brlcad/trunk/regress/gqa.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/gqa.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,12 +42,17 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
+GQABIN="`ensearch g_qa`"
+if test ! -f "$GQABIN" ; then
+ echo "Unable to find g_qa, aborting"
+ exit 1
+fi
rm -f gqa.g density_table.txt gqa.log gqa_mged.log gqa.mged
@@ -121,7 +126,7 @@
# open_box.r = 1000-576 = 424 m^3
-GQA="../src/gtools/g_qa -u m,m^3,kg -g 250mm-50mm -p"
+GQA="$GQABIN -u m,m^3,kg -g 250mm-50mm -p"
export GQA
STATUS=0
Modified: brlcad/trunk/regress/iges.sh
===================================================================
--- brlcad/trunk/regress/iges.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/iges.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,13 +42,24 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
+GIGES="`ensearch g-iges`"
+if test ! -f "$MGED" ; then
+ echo "Unable to find g-iges, aborting"
+ exit 1
+fi
+IGESG="`ensearch iges-g`"
+if test ! -f "$MGED" ; then
+ echo "Unable to find iges-g, aborting"
+ exit 1
+fi
+
rm -f iges.log iges.g iges_file.iges iges_stdout_new.g iges_new.g
iges_stdout.iges iges_file.iges
STATUS=0
@@ -64,10 +75,10 @@
q
EOF
-../src/conv/iges/g-iges -o iges_file.iges iges.g box.nmg 2>> iges.log>
/dev/null
-../src/conv/iges/g-iges iges.g box.nmg > iges_stdout.iges 2>> iges.log
+$GIGES -o iges_file.iges iges.g box.nmg 2>> iges.log> /dev/null
+$GIGES iges.g box.nmg > iges_stdout.iges 2>> iges.log
-../src/conv/iges/iges-g -o iges_new.g -p iges_file.iges 2>> iges.log
+$IGESG -o iges_new.g -p iges_file.iges 2>> iges.log
if [ $? != 0 ] ; then
echo g-iges/iges-g FAILED
@@ -77,7 +88,7 @@
fi
-../src/conv/iges/iges-g -o iges_stdout_new.g -p iges_stdout.iges 2>> iges.log
+$IGESG -o iges_stdout_new.g -p iges_stdout.iges 2>> iges.log
if [ $? != 0 ] ; then
echo g-iges/iges-g FAILED
Modified: brlcad/trunk/regress/library.sh
===================================================================
--- brlcad/trunk/regress/library.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/library.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -50,7 +50,7 @@
ensearch ( ) {
ensearch_file="$1"
- ensearch_dirs="../src $ARG1/src $PATH_TO_THIS/../src"
+ ensearch_dirs="$ARG1/src $PATH_TO_THIS/../src ../src/$1 $ARG1/src/$1
$PATH_TO_THIS/../src/$1 ../bin ../src ../src/util ../src/conv ../src/conv/iges
../src/gtools ../src/rt ../bench"
if test "x$ensearch_file" = "x" ; then
# nothing to do
Modified: brlcad/trunk/regress/lights.sh
===================================================================
--- brlcad/trunk/regress/lights.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/lights.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,22 +42,22 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-RT="`ensearch rt/rt`"
+RT="`ensearch rt`"
if test ! -f "$RT" ; then
echo "Unable to find rt, aborting"
exit 1
fi
-A2G="`ensearch conv/asc2g`"
+A2G="`ensearch asc2g`"
if test ! -f "$A2G" ; then
echo "Unable to find asc2g, aborting"
exit 1
fi
-A2P="`ensearch conv/asc2pix`"
+A2P="`ensearch asc2pix`"
if test ! -f "$A2P" ; then
echo "Unable to find asc2pix, aborting"
exit 1
fi
-PIXDIFF="`ensearch util/pixdiff`"
+PIXDIFF="`ensearch pixdiff`"
if test ! -f "$PIXDIFF" ; then
echo "Unable to find pixdiff, aborting"
exit 1
Modified: brlcad/trunk/regress/mged.sh
===================================================================
--- brlcad/trunk/regress/mged.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/mged.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -45,7 +45,7 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
Modified: brlcad/trunk/regress/mged_test.sh
===================================================================
--- brlcad/trunk/regress/mged_test.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/mged_test.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,7 +42,7 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
Modified: brlcad/trunk/regress/moss.sh
===================================================================
--- brlcad/trunk/regress/moss.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/moss.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,32 +42,32 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-RT="`ensearch rt/rt`"
+RT="`ensearch rt`"
if test ! -f "$RT" ; then
echo "Unable to find rt, aborting"
exit 1
fi
-A2G="`ensearch conv/asc2g`"
+A2G="`ensearch asc2g`"
if test ! -f "$A2G" ; then
echo "Unable to find asc2g, aborting"
exit 1
fi
-A2P="`ensearch conv/asc2pix`"
+A2P="`ensearch asc2pix`"
if test ! -f "$A2P" ; then
echo "Unable to find asc2pix, aborting"
exit 1
fi
-PIXDIFF="`ensearch util/pixdiff`"
+PIXDIFF="`ensearch pixdiff`"
if test ! -f "$PIXDIFF" ; then
echo "Unable to find pixdiff, aborting"
exit 1
fi
-PIX2PNG="`ensearch util/pix-png`"
+PIX2PNG="`ensearch pix-png`"
if test ! -f "$PIX2PNG" ; then
echo "Unable to find pix-png, aborting"
exit 1
fi
-PNG2PIX="`ensearch util/png-pix`"
+PNG2PIX="`ensearch png-pix`"
if test ! -f "$PNG2PIX" ; then
echo "Unable to find png-pix, aborting"
exit 1
Modified: brlcad/trunk/regress/shaders.sh
===================================================================
--- brlcad/trunk/regress/shaders.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/shaders.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,13 +42,30 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
+RT="`ensearch rt`"
+if test ! -f "$RT" ; then
+ echo "Unable to find rt, aborting"
+ exit 1
+fi
+PIXDIFF="`ensearch pixdiff`"
+if test ! -f "$PIXDIFF" ; then
+ echo "Unable to find pixdiff, aborting"
+ exit 1
+fi
+
+ASC2PIX="`ensearch asc2pix`"
+if test ! -f "$ASC2PIX" ; then
+ echo "Unable to find asc2pix, aborting"
+ exit 1
+fi
+
EAGLECAD=eagleCAD-512x438.pix
rm -f shaders.rt shaders.g shaders.rt.pix shaders.pixdiff.log shaders.rt.log
shaders.log shaders.txt shaders.dat $EAGLECAD shaders.mged
@@ -59,7 +76,7 @@
fi
-../src/conv/asc2pix > $EAGLECAD << EOF
+$ASC2PIX > $EAGLECAD << EOF
FFFFFD
FEFEFD
FFFFFD
@@ -224465,7 +224482,7 @@
exit 1
fi
mv shaders.rt shaders.rt.orig
-sed "s,^rt,../src/rt/rt -P 1 -B -U 1," < shaders.rt.orig > shaders.rt
+sed "s,^rt,$RT -P 1 -B -U 1," < shaders.rt.orig > shaders.rt
rm shaders.rt.orig
chmod 775 shaders.rt
echo 'rendering shaders...'
@@ -224487,8 +224504,8 @@
if [ ! -f $TOP_SRCDIR/regress/shaderspix.asc ] ; then
echo No reference file for $TOP_SRCDIR/regress/shaders.rt.pix
else
- ../src/conv/asc2pix < $TOP_SRCDIR/regress/shaderspix.asc >
shaders_ref.pix
- ../src/util/pixdiff shaders.rt.pix shaders_ref.pix >
shaders.rt.diff.pix 2> shaders.rt.pixdiff.log
+ $ASC2PIX < $TOP_SRCDIR/regress/shaderspix.asc > shaders_ref.pix
+ $PIXDIFF shaders.rt.pix shaders_ref.pix > shaders.rt.diff.pix
2> shaders.rt.pixdiff.log
NUMBER_WRONG=`tr , '\012' < shaders.rt.pixdiff.log | awk
'/many/ {print $1}' | tail -${TAIL_N}1`
export NUMBER_WRONG
Modified: brlcad/trunk/regress/solids.sh
===================================================================
--- brlcad/trunk/regress/solids.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/solids.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,27 +42,27 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-RT="`ensearch rt/rt`"
+RT="`ensearch rt`"
if test ! -f "$RT" ; then
echo "Unable to find rt, aborting"
exit 1
fi
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
-A2P="`ensearch conv/asc2pix`"
+A2P="`ensearch asc2pix`"
if test ! -f "$A2P" ; then
echo "Unable to find asc2pix, aborting"
exit 1
fi
-GENCOLOR="`ensearch util/gencolor`"
+GENCOLOR="`ensearch gencolor`"
if test ! -f "$GENCOLOR" ; then
echo "Unable to find gencolor, aborting"
exit 1
fi
-PIXDIFF="`ensearch util/pixdiff`"
+PIXDIFF="`ensearch pixdiff`"
if test ! -f "$PIXDIFF" ; then
echo "Unable to find pixdiff, aborting"
exit 1
Modified: brlcad/trunk/regress/spdi.sh
===================================================================
--- brlcad/trunk/regress/spdi.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/spdi.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,13 +42,31 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
+RT="`ensearch rt`"
+if test ! -f "$RT" ; then
+ echo "Unable to find rt, aborting"
+ exit 1
+fi
+PIXDIFF="`ensearch pixdiff`"
+if test ! -f "$PIXDIFF" ; then
+ echo "Unable to find pixdiff, aborting"
+ exit 1
+fi
+
+ASC2PIX="`ensearch asc2pix`"
+if test ! -f "$ASC2PIX" ; then
+ echo "Unable to find asc2pix, aborting"
+ exit 1
+fi
+
+
rm -f spdi.g spdi.log spdi spdi.pix spdi_mged.log spdi.mged
cat > spdi.mged <<EOF
@@ -95,7 +113,7 @@
echo "rendering..."
-../src/rt/rt -M -B -o spdi.pix spdi.g 'all.g' 2>> spdi.log <<EOF
+$RT -M -B -o spdi.pix spdi.g 'all.g' 2>> spdi.log <<EOF
viewsize 3.200000000000000e+03;
orientation 0.000000000000000e+00 0.000000000000000e+00 0.000000000000000e+00
1.000000000000000e+00;
eye_pt 0.000000000000000e+00 0.000000000000000e+00 2.413000000000000e+03;
@@ -103,8 +121,8 @@
end;
EOF
-../src/conv/asc2pix < $1/regress/spdipix.asc > spdi_ref.pix
-../src/util/pixdiff spdi.pix spdi_ref.pix > spdi_diff.pix 2>> spdi.log
+$ASC2PIX < $1/regress/spdipix.asc > spdi_ref.pix
+$PIXDIFF spdi.pix spdi_ref.pix > spdi_diff.pix 2>> spdi.log
NUMBER_WRONG=`tr , '\012' < spdi.log | awk '/many/ {print $1}'`
echo "spdi.pix $NUMBER_WRONG off by many"
Modified: brlcad/trunk/regress/weight.sh
===================================================================
--- brlcad/trunk/regress/weight.sh 2011-01-03 23:40:37 UTC (rev 41905)
+++ brlcad/trunk/regress/weight.sh 2011-01-04 01:07:18 UTC (rev 41906)
@@ -42,12 +42,12 @@
# PATH_TO_THIS, and THIS.
. $1/regress/library.sh
-MGED="`ensearch mged/mged`"
+MGED="`ensearch mged`"
if test ! -f "$MGED" ; then
echo "Unable to find mged, aborting"
exit 1
fi
-RTWEIGHT="`ensearch rt/rtweight`"
+RTWEIGHT="`ensearch rtweight`"
if test ! -f "$RTWEIGHT" ; then
echo "Unable to find rtweight, aborting"
exit 1
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and,
should the need arise, upgrade to a full multi-node Oracle RAC database
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits