diff options
author | Liu, Changcheng <changcheng.liu@intel.com> | 2017-12-14 15:32:48 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-02-07 11:12:17 -0800 |
commit | 16d3d10d29f753d0247d94f5e889e93dd13f56bb (patch) | |
tree | ae878329b3b782722cd60b037227c690773d48bf /scripts/faddr2line | |
parent | 0146985addc322ca518d27fecfe98ae5acda7c1e (diff) | |
download | linux-rpi3-16d3d10d29f753d0247d94f5e889e93dd13f56bb.tar.gz linux-rpi3-16d3d10d29f753d0247d94f5e889e93dd13f56bb.tar.bz2 linux-rpi3-16d3d10d29f753d0247d94f5e889e93dd13f56bb.zip |
scripts/faddr2line: fix CROSS_COMPILE unset error
commit 4cc90b4cc3d4955f79eae4f7f9d64e67e17b468e upstream.
faddr2line hit var unbound error when CROSS_COMPILE isn't set since
nounset option is set in bash script.
Link: http://lkml.kernel.org/r/20171206013022.GA83929@sofia
Fixes: 95a879825419 ("scripts/faddr2line: extend usage on generic arch")
Signed-off-by: Liu Changcheng <changcheng.liu@intel.com>
Reported-by: Richard Weinberger <richard.weinberger@gmail.com>
Reviewed-by: Richard Weinberger <richard@nod.at>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Philippe Ombredanne <pombredanne@nexb.com>
Cc: NeilBrown <neilb@suse.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/faddr2line')
-rwxr-xr-x | scripts/faddr2line | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/faddr2line b/scripts/faddr2line index 39e07d8574dd..7721d5b2b0c0 100755 --- a/scripts/faddr2line +++ b/scripts/faddr2line @@ -44,10 +44,10 @@ set -o errexit set -o nounset -READELF="${CROSS_COMPILE}readelf" -ADDR2LINE="${CROSS_COMPILE}addr2line" -SIZE="${CROSS_COMPILE}size" -NM="${CROSS_COMPILE}nm" +READELF="${CROSS_COMPILE:-}readelf" +ADDR2LINE="${CROSS_COMPILE:-}addr2line" +SIZE="${CROSS_COMPILE:-}size" +NM="${CROSS_COMPILE:-}nm" command -v awk >/dev/null 2>&1 || die "awk isn't installed" command -v ${READELF} >/dev/null 2>&1 || die "readelf isn't installed" |