From: Aaron Brooks Date: Mon, 27 Feb 2006 03:25:46 +0000 (-0500) Subject: kbuild: make namespace.pl CROSS_COMPILE happy X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3a25f0b19f2eefd158955ab809c8947ed8feadf1;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git kbuild: make namespace.pl 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. Signed-off-by: Aaron Brooks Signed-off-by: Sam Ravnborg --- diff --git a/scripts/namespace.pl b/scripts/namespace.pl index 88e30e82f1ca..f34373853ef8 100644 --- a/scripts/namespace.pl +++ b/scripts/namespace.pl @@ -66,8 +66,8 @@ require 5; # at least perl 5 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'}));