From 4b6aec6dbae1b89485788a31112bf3ee4911b666 Mon Sep 17 00:00:00 2001 From: Nicolas Sauzede Date: Tue, 17 Oct 2023 00:38:25 +0200 Subject: [PATCH] Check if valgrind is operational --- .github/workflows/vade.yml | 2 +- Makefile | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/vade.yml b/.github/workflows/vade.yml index 4dbe781..944ac60 100644 --- a/.github/workflows/vade.yml +++ b/.github/workflows/vade.yml @@ -14,6 +14,6 @@ jobs: steps: - uses: actions/checkout@v3 - name: Install dependencies - run: sudo apt install --quiet -y make gcc python3 bash valgrind nasm + run: sudo apt update && sudo apt install --quiet -y make gcc python3 bash valgrind nasm - name: Build and test run: bin/vade clean test diff --git a/Makefile b/Makefile index e99475e..bb4c77b 100644 --- a/Makefile +++ b/Makefile @@ -62,7 +62,8 @@ ifeq ($(CC),$(CLANG)) VALGRIND:= endif -ifeq (, $(shell which $(VALGRIND) 2>/dev/null)) +# Check if valgrind is operational (eg: not missing debuginfo etc..) +ifneq (0, $(shell $(VALGRIND) /bin/false 2>/dev/null ; echo $?)) #$(error "NOT HAVE VALGRIND ($(VALGRIND))") RUN:= RUNTEST:=RUN