summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9
diff options
context:
space:
mode:
authorTudor Florea <tudor.florea@enea.com>2014-10-10 03:20:04 +0200
committerTudor Florea <tudor.florea@enea.com>2014-10-10 03:20:04 +0200
commit1b8dfe266937a37a4c642f96ceb2347bf4c00a17 (patch)
tree0c6aab146bb3c82efd9c7846a9a4e70dcb0ec84f /meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9
downloadmeta-openembedded-daisy-140929.tar.gz
initial commit for Enea Linux 4.0-140929daisy-140929
Migrated from the internal git server on the daisy-enea-point-release branch Signed-off-by: Tudor Florea <tudor.florea@enea.com>
Diffstat (limited to 'meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9')
-rw-r--r--meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/obey-ranlib.patch30
-rw-r--r--meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-config-script.patch12
-rw-r--r--meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-results-script.patch160
-rw-r--r--meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch32
4 files changed, 234 insertions, 0 deletions
diff --git a/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/obey-ranlib.patch b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/obey-ranlib.patch
new file mode 100644
index 0000000000..41a3b3205b
--- /dev/null
+++ b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/obey-ranlib.patch
@@ -0,0 +1,30 @@
1In some cases the host may have too old of a ranlib to work. Since it's
2not exactly a great idea to not be using the cross ranlib anyhow, fix the
3Makefile so we can override ranlib and then override it
4
5Upstream-Status: Inappropriate [build system specific change]
6---
7 src/Makefile | 3 ++-
8 1 file changed, 2 insertions(+), 1 deletion(-)
9
10Index: lmbench-3.0-a9/src/Makefile
11===================================================================
12--- lmbench-3.0-a9.orig/src/Makefile
13+++ lmbench-3.0-a9/src/Makefile
14@@ -38,6 +38,7 @@ CC=`../scripts/compiler`
15 MAKE=`../scripts/make`
16 AR=ar
17 ARCREATE=cr
18+RANLIB=ranlib
19
20 # base of installation location
21 BASE=/usr/local
22@@ -217,7 +218,7 @@ $O/lmbench : ../scripts/lmbench version.
23 $O/lmbench.a: $(LIBOBJS)
24 /bin/rm -f $O/lmbench.a
25 $(AR) $(ARCREATE) $O/lmbench.a $(LIBOBJS)
26- -ranlib $O/lmbench.a
27+ -$(RANLIB) $O/lmbench.a
28
29 $O/lib_timing.o : lib_timing.c $(INCS)
30 $(COMPILE) -c lib_timing.c -o $O/lib_timing.o
diff --git a/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-config-script.patch b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-config-script.patch
new file mode 100644
index 0000000000..b46e09ad15
--- /dev/null
+++ b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-config-script.patch
@@ -0,0 +1,12 @@
1Upstream-Status: Pending
2Index: lmbench-3.0-a9/scripts/config
3===================================================================
4--- lmbench-3.0-a9/scripts/config 2000-01-31 18:29:31.000000000 -0600
5+++ lmbench-3.0-a9/scripts/config 2013-03-01 00:19:41.032984315 -0600
6@@ -3,5 +3,5 @@
7 UNAME=`uname -n 2>/dev/null`
8 if [ X$UNAME = X ]
9 then echo CONFIG
10-else echo CONFIG.$UNAME
11+else echo ../scripts/CONFIG.$UNAME
12 fi
diff --git a/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-results-script.patch b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-results-script.patch
new file mode 100644
index 0000000000..894f146d42
--- /dev/null
+++ b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/update-results-script.patch
@@ -0,0 +1,160 @@
1Now that we have our binaries in /usr/bin rather than the normal
2lmbench hierarchy we need to update the scripts as well to behave well here.
3
4Upstream-Status: Inappropriate [This is related to the OE-specific behavior
5of installing into /usr/bin, etc, rather than dumping everything into
6/usr/share/lmbench or similar]
7
8Index: lmbench-3.0-a9/scripts/results
9===================================================================
10--- lmbench-3.0-a9.orig/scripts/results
11+++ lmbench-3.0-a9/scripts/results
12@@ -8,11 +8,11 @@ RESULTS=results/$OS
13 BASE=../$RESULTS/`uname -n`
14 EXT=0
15
16-if [ ! -f "../bin/$OS/$CONFIG" ]
17+if [ ! -f "$CONFIG" ]
18 then echo "No config file?"
19 exit 1
20 fi
21-. ../bin/$OS/$CONFIG
22+. $CONFIG
23
24 if [ ! -d ../$RESULTS ]
25 then mkdir -p ../$RESULTS
26@@ -23,11 +23,9 @@ do EXT=`expr $EXT + 1`
27 RESULTS=$BASE.$EXT
28 done
29
30-cd ../bin/$OS
31-PATH=.:${PATH}; export PATH
32 export SYNC_MAX
33 export OUTPUT
34-lmbench $CONFIG 2>../${RESULTS}
35+lmbench $CONFIG 2>${RESULTS}
36
37 if [ X$MAIL = Xyes ]
38 then echo Mailing results
39Index: lmbench-3.0-a9/scripts/config-run
40===================================================================
41--- lmbench-3.0-a9.orig/scripts/config-run
42+++ lmbench-3.0-a9/scripts/config-run
43@@ -132,20 +132,20 @@ export LMBENCH_SCHED
44 ############################################################################
45 echo $L; echo "";
46 echo "Hang on, we are calculating your timing granularity."
47-../bin/$OS/msleep 250
48-ENOUGH=`../bin/$OS/enough`
49+msleep 250
50+ENOUGH=`enough`
51 export ENOUGH
52 echo "OK, it looks like you can time stuff down to $ENOUGH usec resolution."
53 echo ""
54 echo "Hang on, we are calculating your timing overhead."
55-../bin/$OS/msleep 250
56-TIMING_O=`../bin/$OS/timing_o`
57+msleep 250
58+TIMING_O=`timing_o`
59 export TIMING_O
60 echo "OK, it looks like your gettimeofday() costs $TIMING_O usecs."
61 echo ""
62 echo "Hang on, we are calculating your loop overhead."
63-../bin/$OS/msleep 250
64-LOOP_O=`../bin/$OS/loop_o`
65+msleep 250
66+LOOP_O=`loop_o`
67 export LOOP_O
68 echo "OK, it looks like your benchmark loop costs $LOOP_O usecs."
69 echo ""
70@@ -177,7 +177,7 @@ then
71 fi
72 if [ X$MB = X ]
73 then $ECHON "Probing system for available memory: $ECHOC"
74- MB=`../bin/$OS/memsize 4096`
75+ MB=`memsize 4096`
76 fi
77 TOTAL_MEM=$MB
78 MB=`echo \( $MB \* 7 \) / 10 | bc 2>/dev/null`
79@@ -205,9 +205,9 @@ fi
80 # Certain machines tend to barf when you try and bcopy 8MB.
81 # Figure out how much we can use.
82 echo "Checking to see if you have $MB MB; please wait for a moment..."
83-MB=`../bin/$OS/memsize $MB`
84-MB=`../bin/$OS/memsize $MB`
85-MB=`../bin/$OS/memsize $MB`
86+MB=`memsize $MB`
87+MB=`memsize $MB`
88+MB=`memsize $MB`
89 if [ `expr $SYNC_MAX \* $MB` -gt `expr $TOTAL_MEM` ]
90 then
91 MB=`expr $TOTAL_MEM / $SYNC_MAX`
92@@ -223,8 +223,8 @@ then echo Warning: you have only ${MB}MB
93 fi
94
95 echo "Hang on, we are calculating your cache line size."
96-../bin/$OS/msleep 250
97-LINE_SIZE=`../bin/$OS/lm_line -M ${MB}M`
98+msleep 250
99+LINE_SIZE=`lm_line -M ${MB}M`
100 export LINE_SIZE
101 echo "OK, it looks like your cache line is $LINE_SIZE bytes."
102 echo ""
103@@ -479,7 +479,7 @@ EOF
104 then
105 for i in $disks
106 do if [ -r $i ]
107- then ../bin/$OS/flushdisk $i
108+ then flushdisk $i
109 if [ $? -eq 1 ]
110 then echo "Must be root to run disk benchmarks."
111 echo "Root is needed to flush the buffer cache"
112@@ -584,7 +584,7 @@ fi
113 echo $L
114 echo ""
115 echo "Calculating mhz, please wait for a moment..."
116-MHZ=`../bin/$OS/mhz`
117+MHZ=`mhz`
118 cat<<EOF
119 I think your CPU mhz is
120
121@@ -689,9 +689,9 @@ esac
122
123 INFO=`../scripts/info`
124 if [ $MAIL = yes ]
125-then if [ ! -f ../bin/$OS/$INFO ]
126- then cp ../scripts/info-template ../bin/$OS/$INFO
127- chmod +w ../bin/$OS/$INFO
128+then if [ ! -f $INFO ]
129+ then cp ../scripts/info-template $INFO
130+ chmod +w $INFO
131 REUSE=no
132 else
133 REUSE=view
134@@ -705,7 +705,7 @@ then if [ ! -f ../bin/$OS/$INFO ]
135 ;;
136 [Vv]*) REUSE=view
137 echo $L
138- more ../bin/$OS/$INFO
139+ more $INFO
140 echo $L
141 ;;
142 *) REUSE=yes
143@@ -733,7 +733,7 @@ EOF
144 then EDITOR=$TMP
145 fi
146 if [ X$EDITOR != "none" ]
147- then $EDITOR ../bin/$OS/`../scripts/info`
148+ then $EDITOR `../scripts/info`
149 fi
150 fi
151 fi
152@@ -750,7 +750,7 @@ EOF
153
154 VERSION=`../scripts/version`
155
156-C=../bin/$OS/`../scripts/config`
157+C=`../scripts/config`
158 echo DISKS=\"$DISKS\" > $C
159 echo DISK_DESC=\"$DISK_DESC\" >> $C
160 echo OUTPUT=$OUTPUT >> $C
diff --git a/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch
new file mode 100644
index 0000000000..3351ce8875
--- /dev/null
+++ b/meta-oe/recipes-benchmark/lmbench/lmbench-3.0-a9/use-base_libdir-instead-of-hardcoded-lib.patch
@@ -0,0 +1,32 @@
1From 0d09e31970616e09beb7f238c2b59bfc541148fb Mon Sep 17 00:00:00 2001
2From: Ting Liu <b28495@freescale.com>
3Date: Fri, 22 Nov 2013 15:20:08 +0800
4Subject: [PATCH] use base_libdir instead of hardcoded /lib
5
6Upsteam Status: Inappropriate [configuration]
7
8Signed-off-by: Ting Liu <b28495@freescale.com>
9---
10 src/Makefile | 4 ++--
11 1 files changed, 2 insertions(+), 2 deletions(-)
12
13diff --git a/src/Makefile b/src/Makefile
14index c7a8c79..c7e4e3c 100644
15--- a/src/Makefile
16+++ b/src/Makefile
17@@ -143,10 +143,10 @@ install-target:
18 if [ ! -d $(BASE) ]; then mkdir $(BASE); fi
19 if [ ! -d $(BASE)/bin ]; then mkdir $(BASE)/bin; fi
20 if [ ! -d $(BASE)/include ]; then mkdir $(BASE)/include; fi
21- if [ ! -d $(BASE)/lib ]; then mkdir $(BASE)/lib; fi
22+ if [ ! -d $(BASE)$(base_libdir) ]; then mkdir $(BASE)$(base_libdir); fi
23 cp $(EXES) $(BASE)/bin
24 cp $(INCS) $(BASE)/include
25- cp $O/lmbench.a $(BASE)/lib/libmbench.a
26+ cp $O/lmbench.a $(BASE)$(base_libdir)
27 cd ../doc; env MAKEFLAGS="$(MAKEFLAGS)" make CC="${CC}" OS="${OS}" BASE="$(BASE)" install
28
29
30--
311.7.5.4
32