1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
$NetBSD: patch-af,v 1.2 1998/09/24 08:45:00 agc Exp $
--- scripts/config-run.orig Fri Jul 31 12:55:19 1998
+++ scripts/config-run Sun Aug 30 08:08:52 1998
@@ -3,7 +3,7 @@
# Configure parameters for lmbench.
# 1.23 98/07/31 lm@lm.bitmover.com
-OS=`../scripts/os`
+OS=`@PREFIX@/bin/lmbench/os`
L='====================================================================='
echo $L;
cat<<EOF;
@@ -36,20 +36,20 @@
############################################################################
echo $L; echo "";
echo "Hang on, we are calculating your timing granularity."
-../bin/$OS/msleep 250
-ENOUGH=`../bin/$OS/enough`
+@PREFIX@/bin/lmbench/msleep 250
+ENOUGH=`@PREFIX@/bin/lmbench/enough`
export ENOUGH
echo "OK, it looks like you can time stuff down to $ENOUGH usec resolution."
echo ""
echo "Hang on, we are calculating your timing overhead."
-../bin/$OS/msleep 250
-TIMING_O=`../bin/$OS/timing_o`
+@PREFIX@/bin/lmbench/msleep 250
+TIMING_O=`@PREFIX@/bin/lmbench/timing_o`
export TIMING_O
echo "OK, it looks like your gettimeofday() costs $TIMING_O usecs."
echo ""
echo "Hang on, we are calculating your loop overhead."
-../bin/$OS/msleep 250
-LOOP_O=`../bin/$OS/loop_o`
+@PREFIX@/bin/lmbench/msleep 250
+LOOP_O=`@PREFIX@/bin/lmbench/loop_o`
export LOOP_O
echo "OK, it looks like your benchmark loop costs $LOOP_O usecs."
echo ""
@@ -89,9 +89,9 @@
# Certain machines tend to barf when you try and bcopy 8MB.
# Figure out how much we can use.
echo "Checking to see if you have $MB MB; please wait for a moment..."
-AVAILMEM=`../bin/$OS/memsize $MB`
-AVAILMEM=`../bin/$OS/memsize $MB`
-AVAILMEM=`../bin/$OS/memsize $MB`
+AVAILMEM=`@PREFIX@/bin/lmbench/memsize $MB`
+AVAILMEM=`@PREFIX@/bin/lmbench/memsize $MB`
+AVAILMEM=`@PREFIX@/bin/lmbench/memsize $MB`
if [ $AVAILMEM -lt 8 ]
then echo $0 aborted: Not enough memory, only ${AVAILMEM}MB available.
exit 1
@@ -185,7 +185,7 @@
then
for i in $disks
do if [ -r $i ]
- then ../bin/$OS/flushdisk $i
+ then @PREFIX@/bin/lmbench/flushdisk $i
if [ $? -eq 1 ]
then echo "Must be root to run disk benchmarks."
echo "Root is needed to flush the buffer cache"
@@ -206,7 +206,7 @@
echo $L
echo ""
echo "Calculating mhz, please wait for a moment..."
-MHZ=`../bin/$OS/mhz`
+MHZ=`@PREFIX@/bin/lmbench/mhz`
cat > /dev/tty <<EOF
I think your CPU mhz is
@@ -363,11 +363,11 @@
;;
esac
-INFO=`../scripts/info`
+INFO=`@PREFIX@/bin/lmbench/info`
if [ $MAIL = yes ]
-then if [ ! -f ../bin/$OS/$INFO ]
- then cp ../scripts/info-template ../bin/$OS/$INFO
- chmod +w ../bin/$OS/$INFO
+then if [ ! -f $INFO ]
+ then cp @PREFIX@/bin/lmbench/info-template @PREFIX@/share/lmbench/$INFO
+ chmod +w @PREFIX@/share/lmbench/$INFO
REUSE=no
else
REUSE=view
@@ -381,7 +381,7 @@
;;
[Vv]*) REUSE=view
echo $L
- more ../bin/$OS/$INFO
+ more @PREFIX@/share/lmbench/$INFO
echo $L
;;
*) REUSE=yes
@@ -409,7 +409,7 @@
then EDITOR=$TMP
fi
if [ X$EDITOR != "none" ]
- then $EDITOR ../bin/$OS/`../scripts/info`
+ then $EDITOR @PREFIX@/share/lmbench/`@PREFIX@/share/lmbench/info`
fi
fi
fi
@@ -424,9 +424,10 @@
EOF
-VERSION=`../scripts/version`
+VERSION=`@PREFIX@/bin/lmbench/version`
+CONFIG=@PREFIX@/share/lmbench/`@PREFIX@/bin/lmbench/config`
-cat<<EOF > ../bin/$OS/`../scripts/config`
+cat <<EOF >$CONFIG
DISKS="$DISKS"
DISK_DESC="$DISK_DESC"
ENOUGH=$ENOUGH
|