]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Adjust .gitlab-ci env var detection with sed
authorTom Krizek <tkrizek@isc.org>
Wed, 3 Jan 2024 13:08:58 +0000 (14:08 +0100)
committerNicki Křížek <nicki@isc.org>
Thu, 9 May 2024 15:08:09 +0000 (17:08 +0200)
The environment variables set by autoconf were moved to autoconf.py.

.gitlab-ci.yml

index 058b94f1b148b9785ec1550cb51d8b38b14a8480..3cb73e0d2e897628fa0ee3d34df2311cf9c8e20b 100644 (file)
@@ -271,11 +271,11 @@ stages:
 
 # change directory to the workspace before including this
 .find_python: &find_python
-  - PYTHON="$(source bin/tests/system/conf.sh; echo $PYTHON)"
+  - PYTHON="$(sed -n -E 's|^[[:space:]]*"PYTHON":[[:space:]]*"([^"]*)",[[:space:]]*$|\1|p' bin/tests/system/isctest/vars/autoconf.py)"
   - test -x "$PYTHON"
 
 .find_pytest: &find_pytest
-  - PYTEST="$(source bin/tests/system/conf.sh; echo $PYTEST)"
+  - PYTEST="$(sed -n -E 's|^[[:space:]]*"PYTEST":[[:space:]]*"([^"]*)",[[:space:]]*$|\1|p' bin/tests/system/isctest/vars/autoconf.py)"
   - test -x "$PYTEST"
 
 .parse_tsan: &parse_tsan
@@ -702,7 +702,8 @@ cross-version-config-tests:
     # Run the setup phase of all system tests in the most recently tagged BIND 9
     # release using the binaries built for the current BIND 9 version.  This
     # intends to detect obvious backward compatibility issues with the latter.
-    - sed -i -E "s|(export TOP_BUILDDIR)=.*|\1=${CI_PROJECT_DIR}|" conf.sh
+    - >
+      sed -i -E "s|(\s* \"TOP_BUILDDIR\"):.*|\1: \"${CI_PROJECT_DIR}\",|" isctest/vars/autoconf.py
     - >
       "$PYTEST" --setup-only --junit-xml="$CI_PROJECT_DIR"/junit.xml -n "${TEST_PARALLEL_JOBS:-1}"
   needs: