commit 4f498a90ad9f907eb9be6a09f79bdca9b3b14bce
parent 64f3c7719d5c78a2fb962d66ec7d04f7bb15db8f
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date: Wed, 16 Oct 2024 22:02:01 +0200
tests: Use command -v to find the assembler
Some shells are generating an error in stderr when
the assembler is not found, and it is better to use
command instead of trying to execute the assembler
with an empty file.
Diffstat:
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/tests/ld/execute/Makefile b/tests/ld/execute/Makefile
@@ -10,7 +10,7 @@ OBJLIB = f3.o
all: a.out
tests:
- @if $(AS) /dev/null 2>/dev/null;\
+ @if command -v $(AS) >/dev/null;\
then\
$(MAKE) |\
grep -v TODO |\
diff --git a/tests/nm/execute/Makefile b/tests/nm/execute/Makefile
@@ -9,7 +9,7 @@ all: $(OUT)
@PATH=$(ROOT)/bin:$$PATH:. chktest.sh
tests:
- @if $(AS) /dev/null 2>/dev/null;\
+ @if command -v $(AS) >/dev/null;\
then\
$(MAKE) |\
grep -v TODO |\
diff --git a/tests/size/execute/Makefile b/tests/size/execute/Makefile
@@ -9,7 +9,7 @@ all: $(OUT)
@PATH=$(ROOT)/bin:$$PATH:. chktest.sh
tests:
- @if $(AS) /dev/null 2>/dev/null;\
+ @if command -v $(AS) >/dev/null;\
then\
$(MAKE) | \
grep -v TODO |\
diff --git a/tests/strip/execute/Makefile b/tests/strip/execute/Makefile
@@ -9,7 +9,7 @@ all: $(OUT)
@PATH=$(ROOT)/bin:$$PATH:. chktest.sh
tests:
- @if $(AS) /dev/null 2>/dev/null;\
+ @if command -v $(AS) >/dev/null;\
then\
$(MAKE) |\
grep -v TODO |\