From c174e6478043fa1400cc8797f66ac211016f1a67 Mon Sep 17 00:00:00 2001 From: Robert Izzard <r.izzard@surrey.ac.uk> Date: Mon, 9 Dec 2019 15:44:25 +0000 Subject: [PATCH] another attempt to fix the sh/bash confusion --- meson.build | 2 +- meson/directory_exists.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index d7654aee5..0174dc8b5 100644 --- a/meson.build +++ b/meson.build @@ -508,7 +508,7 @@ _include_search_paths = [ '/usr/local/include', ] foreach idir : _include_search_paths - _ret = run_command('sh','-c','meson/directory_exists.sh',idir).returncode() + _ret = run_command('meson/directory_exists.sh',idir).returncode() if _ret == 0 inc_arg = idir _Inc_arg = '-I' + idir diff --git a/meson/directory_exists.sh b/meson/directory_exists.sh index 1e046fc79..43fe49a4c 100755 --- a/meson/directory_exists.sh +++ b/meson/directory_exists.sh @@ -1,7 +1,7 @@ -#!/bin/sh +#!/bin/bash # return 0 if directory exists, 1 otherwise -if [ -d "$1" ]; then +if [[ -d "$1" ]]; then exit 0; else exit 1; -- GitLab