scripts/makelst: replace gawk with shell, update
Signed-off-by: Oleg Verych <[email protected]>
---
-o--=O`C
#oo'L O
<___=E M
--- linux~2.6.20-rc5/scripts/makelst~ 2007-01-12 19:54:26.000000000 +0100
+++ linux~2.6.20-rc5/scripts/makelst 2007-01-24 23:21:33.273657000 +0100
@@ -1,19 +1,22 @@
-#!/bin/bash
+#!/bin/sh
# A script to dump mixed source code & assembly
# with correct relocations from System.map
-# Requires the following lines in Rules.make.
-# Author(s): DJ Barrow ([email protected],[email protected])
-# William Stearns <[email protected]>
+# Requires the following lines in makefile:
#%.lst: %.c
# $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -g -c -o $*.o $<
-# $(TOPDIR)/scripts/makelst $*.o $(TOPDIR)/System.map $(OBJDUMP)
+# $(srctree)/scripts/makelst $*.o $(srctree)/System.map $(OBJDUMP)
#
-# Copyright (C) 2000 IBM Corporation
-# Author(s): DJ Barrow ([email protected],[email protected])
+# Copyright (C) 2000 IBM Corporation
+# Author(s): DJ Barrow ([email protected],[email protected])
+# William Stearns <[email protected]>
#
+pos_param() {
+ shift $1 ; echo $1
+}
+
t1=`$3 --syms $1 | grep .text | grep " F " | head -n 1`
if [ -n "$t1" ]; then
- t2=`echo $t1 | gawk '{ print $6 }'`
+ t2=`pos_param 6 $t1`
if [ ! -r $2 ]; then
echo "No System.map" >&2
@@ -21,6 +24,6 @@
else
t3=`grep $t2 $2`
- t4=`echo $t3 | gawk '{ print $1 }'`
- t5=`echo $t1 | gawk '{ print $1 }'`
+ t4=`pos_param 1 $t3`
+ t5=`pos_param 1 $t1`
t6=`echo $t4 - $t5 | tr a-f A-F`
t7=`( echo ibase=16 ; echo $t6 ) | bc`
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]