parisc: fix the exit status of arch/parisc/nm
Subsystems (2)
PATCH 1/1 parisc: fix the exit status of arch/parisc/nm
Parisc overrides 'nm' with a shell script. I was hit by a false-positive error of $(NM) because this script returns the exit code of grep instead of ${CROSS_COMPILE}nm. (grep exits with 1 if no lines were selected)
I tried to fix it, but in the code review, Helge suggested to remove it entirely. [1]
This script was added in 2003. [2]
Presumably, it was a workaround for old toolchains (but even the parisc maintainer does not know the detail any more).
Hopefully recent tools should work fine.
[1]: https://lore.kernel.org/all/[email protected]/
[2]: https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/commit/?id=36eaa6e4c0e0b6950136b956b72fd08155b92ca3
---
I want to apply this to kbuild tree with Helge's Ack
arch/parisc/Makefile | 1 - arch/parisc/nm | 6 ------ 2 files changed, 7 deletions(-) delete mode 100644 arch/parisc/nm
arch/parisc/Makefile +0 -1
@@ -18,7 +18,6 @@ boot := arch/parisc/boot KBUILD_IMAGE := $(boot)/bzImage -NM = sh $(srctree)/arch/parisc/nm CHECKFLAGS += -D__hppa__=1 ifdef CONFIG_64BIT
arch/parisc/nm deleted +0 -6
@@ -1,6 +0,0 @@ -#!/bin/sh -## -# Hack to have an nm which removes the local symbols. We also rely -# on this nm being hidden out of the ordinarily executable path -## -${CROSS_COMPILE}nm $* | grep -v '.LC*[0-9]*$'
Signature · 1 line
2.32.0
Quoted 12 lines · Masahiro Yamada
Parisc overrides 'nm' with a shell script. I was hit by a false-positive error of $(NM) because this script returns the exit code of grep instead of ${CROSS_COMPILE}nm. (grep exits with 1 if no lines were selected)
I tried to fix it, but in the code review, Helge suggested to remove it entirely. [1]
This script was added in 2003. [2]
Presumably, it was a workaround for old toolchains (but even the parisc maintainer does not know the detail any more).
Quoted 7 lines
Hopefully recent tools should work fine.
[1]: https://lore.kernel.org/all/[email protected]/
[2]: https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/commit/?id=36eaa6e4c0e0b6950136b956b72fd08155b92ca3Suggested-by Helge Deller <[email protected]>Signed-off-by Masahiro Yamada <[email protected]>
Thank you!
Helge
Quoted 33 lines
---
I want to apply this to kbuild tree with Helge's Ack
arch/parisc/Makefile | 1 - arch/parisc/nm | 6 ------ 2 files changed, 7 deletions(-) delete mode 100644 arch/parisc/nmarch/parisc/Makefile +0
-1@@ -18,7 +18,6 @@ boot := arch/parisc/boot KBUILD_IMAGE := $(boot)/bzImage -NM = sh $(srctree)/arch/parisc/nm CHECKFLAGS += -D__hppa__=1 ifdef CONFIG_64BITarch/parisc/nm deleted +0
-6@@ -1,6 +0,0 @@ -#!/bin/sh -## -# Hack to have an nm which removes the local symbols. We also rely -# on this nm being hidden out of the ordinarily executable path -## -${CROSS_COMPILE}nm $* | grep -v '.LC*[0-9]*$'
Quoted 19 lines · Helge Deller
Quoted 17 lines · Masahiro Yamada
Parisc overrides 'nm' with a shell script. I was hit by a false-positive error of $(NM) because this script returns the exit code of grep instead of ${CROSS_COMPILE}nm. (grep exits with 1 if no lines were selected)
I tried to fix it, but in the code review, Helge suggested to remove it entirely. [1]
This script was added in 2003. [2]
Presumably, it was a workaround for old toolchains (but even the parisc maintainer does not know the detail any more).
Hopefully recent tools should work fine.
[1]: https://lore.kernel.org/all/[email protected]/
[2]: https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/commit/?id=36eaa6e4c0e0b6950136b956b72fd08155b92ca3
Quoted 8 lines
Quoted 2 lines
Suggested-by Helge Deller <[email protected]>Signed-off-by Masahiro Yamada <[email protected]>Acked-by Helge Deller <[email protected]>Thank you!
Helge
I just forgot to change the patch subject.
I changed it to
"parisc: remove arch/parisc/nm"
Applied to linux-kbuild.
Thanks for the ack.
Signature · 2 lines
Best Regards Masahiro Yamada