public inbox for elfutils@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] tests: check gcc
@ 2019-05-21  7:01 mingli.yu
  2019-05-21  7:25 ` Dmitry V. Levin
  0 siblings, 1 reply; 7+ messages in thread
From: mingli.yu @ 2019-05-21  7:01 UTC (permalink / raw)
  To: elfutils-devel

From: Mingli Yu <Mingli.Yu@windriver.com>

Both run-disasm-x86-64.sh and run-disasm-x86.sh
need gcc, so check gcc before run the test.

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
---
 tests/run-disasm-x86-64.sh | 2 ++
 tests/run-disasm-x86.sh    | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/tests/run-disasm-x86-64.sh b/tests/run-disasm-x86-64.sh
index a6be62b..c3ef238 100755
--- a/tests/run-disasm-x86-64.sh
+++ b/tests/run-disasm-x86-64.sh
@@ -22,6 +22,8 @@ case "`uname -m`" in
   x86_64)
     tempfiles testfile45.o
     testfiles testfile45.S testfile45.expect
+    # skip the case if no gcc deployed
+    which gcc || exit 77
     gcc -m64 -c -o testfile45.o testfile45.S
     testrun_compare ${abs_top_builddir}/src/objdump -d testfile45.o < testfile45.expect
     ;;
diff --git a/tests/run-disasm-x86.sh b/tests/run-disasm-x86.sh
index 28a3df7..544fc28 100755
--- a/tests/run-disasm-x86.sh
+++ b/tests/run-disasm-x86.sh
@@ -22,6 +22,8 @@ case "`uname -m`" in
   x86_64 | i?86 )
     tempfiles testfile44.o
     testfiles testfile44.S testfile44.expect
+    # skip the case if no gcc deployed
+    which gcc || exit 77
     gcc -m32 -c -o testfile44.o testfile44.S
     testrun_compare ${abs_top_builddir}/src/objdump -d testfile44.o < testfile44.expect
     ;;
-- 
2.7.4

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-05-24  7:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-21  7:01 [PATCH] tests: check gcc mingli.yu
2019-05-21  7:25 ` Dmitry V. Levin
2019-05-21  7:34   ` [PATCH v2] skip the test when gcc not deployed mingli.yu
2019-05-23 11:28     ` Mark Wielaard
2019-05-24  6:41       ` Yu, Mingli
2019-05-24  7:03         ` Mark Wielaard
2019-05-24  7:12           ` Yu, Mingli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).