Skip to contentSkip to conversation

scripts/namespace.pl is not CROSS_COMPILE happy

PATCH Applied Aaron D. Brooks 2 participants 4 messages Feb 8, 2006 – Feb 27, 2006

lore
Share & tools
lore
#0 lore raw

All,

I see that this has come up before:

http://lkml.org/lkml/2005/9/20/68

but I don't see the inclusion of these changes in the current Linus linux-2.6 git tree. Are the changes hanging out somewhere or were they shot down for some reason?

I've attached an alternate patch which is a ever so slightly more
clean (for some definitions of "clean").

-Aaron

P.S. Please CC me, I'm not on the list.

scripts/namespace.pl (working copy) renamed from scripts/namespace.pl (revision 13486) +2 -2
Index: scripts/namespace.pl
===================================================================
@@ -66,8 +66,8 @@
 use strict;
 use File::Find;
 
-my $nm = "/usr/bin/nm -p";
-my $objdump = "/usr/bin/objdump -s -j .comment";
+my $nm = ($ENV{'NM'} || "nm") . " -p";
+my $objdump = ($ENV{'OBJDUMP'} || "objdump") . " -s -j .comment";
 my $srctree = "";
 my $objtree = "";
 $srctree = "$ENV{'srctree'}/" if (exists($ENV{'srctree'}));
#1 lore raw
Quoted 4 lines · Aaron D. Brooks

All,

I see that this has come up before:

Quoted 8 lines

http://lkml.org/lkml/2005/9/20/68

but I don't see the inclusion of these changes in the current Linus linux-2.6 git tree. Are the changes hanging out somewhere or were they shot down for some reason?

I've attached an alternate patch which is a ever so slightly more
clean (for some definitions of "clean").

Looks good and with same functionality as Keiths - which I lost somehow. Will take care when I'm back from holiday end of next week.

Sam

#2 lore raw

PATCH 1/1 scripts: namespace.pl is not CROSS_COMPILE happy

Using the fixed path to /usr/bin/{nm,objdump} does not allow CROSS_COMPILE environments to use namespace.pl. This patch causes namespace.pl to use $NM and $OBJDUMP if defined or fall back to the nm and objdump found in the path.

---

Patch applies to current torvalds/linux-2.6.git head.

 namespace.pl |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/namespace.pl (working copy) renamed from scripts/namespace.pl (revision 14607) +2 -2
Index: linux/scripts/namespace.pl
===================================================================
@@ -66,8 +66,8 @@
 use strict;
 use File::Find;
 
-my $nm = "/usr/bin/nm -p";
-my $objdump = "/usr/bin/objdump -s -j .comment";
+my $nm = ($ENV{'NM'} || "nm") . " -p";
+my $objdump = ($ENV{'OBJDUMP'} || "objdump") . " -s -j .comment";
 my $srctree = "";
 my $objtree = "";
 $srctree = "$ENV{'srctree'}/" if (exists($ENV{'srctree'}));
Applied
#3 lore raw

Re: [PATCH] scripts: namespace.pl is not CROSS_COMPILE happy

Quoted 6 lines · Aaron Brooks

Using the fixed path to /usr/bin/{nm,objdump} does not allow CROSS_COMPILE environments to use namespace.pl. This patch causes namespace.pl to use $NM and $OBJDUMP if defined or fall back to the nm and objdump found in the path.

Applied.

Sam