[vala/0.40] testrunner: Filter external -0X flags to preserve current default -O0
- From: Rico Tzschichholz <ricotz src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/0.40] testrunner: Filter external -0X flags to preserve current default -O0
- Date: Tue, 29 Sep 2020 10:45:38 +0000 (UTC)
commit 5daa31130f6fecb0871fa3e7a0051ce2478a8f16
Author: Rico Tzschichholz <ricotz ubuntu com>
Date: Sun Sep 27 23:45:27 2020 +0200
testrunner: Filter external -0X flags to preserve current default -O0
tests/testrunner.sh | 4 +++-
valadoc/tests/testrunner.sh | 4 +++-
2 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/tests/testrunner.sh b/tests/testrunner.sh
index 10caefe96..1c76487de 100755
--- a/tests/testrunner.sh
+++ b/tests/testrunner.sh
@@ -60,7 +60,9 @@ VAPIGENFLAGS="--vapidir $vapidir"
# Incorporate the user's CFLAGS. Matters if the user decided to insert
# -m32 in CFLAGS, for example.
for cflag in ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
- VALAFLAGS="${VALAFLAGS} -X ${cflag}"
+ if [[ ! $cflag =~ ^\-O[0-9]$ ]]; then
+ VALAFLAGS="${VALAFLAGS} -X ${cflag}"
+ fi
done
function testheader() {
diff --git a/valadoc/tests/testrunner.sh b/valadoc/tests/testrunner.sh
index 5ec5d1cba..fa4852257 100755
--- a/valadoc/tests/testrunner.sh
+++ b/valadoc/tests/testrunner.sh
@@ -68,7 +68,9 @@ VALAFLAGS="$VALAFLAGS \
# Incorporate the user's CFLAGS. Matters if the user decided to insert
# -m32 in CFLAGS, for example.
for cflag in ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
- VALAFLAGS="${VALAFLAGS} -X ${cflag}"
+ if [[ ! $cflag =~ ^\-O[0-9]$ ]]; then
+ VALAFLAGS="${VALAFLAGS} -X ${cflag}"
+ fi
done
testdir=_test
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]