From: Michał Kępień Date: Tue, 18 Mar 2025 05:19:01 +0000 (+0100) Subject: Fix PYTHONPATH set for ans.py servers by start.pl X-Git-Tag: v9.21.7~47^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a799dd04adc08a062ec9961a026573abcc7c9181;p=thirdparty%2Fbind9.git Fix PYTHONPATH set for ans.py servers by start.pl Commit 6c010a5644324947c8c13b5600cd8d988ae7684f caused the PYTHONPATH environment variable to be set for ans.py servers started using start.pl. However, no system test has actually used the new isctest.asyncserver module since that change was applied, so it has not been noticed until now that including the source directory in PYTHONPATH is only sufficient for in-tree builds. Include the build directory instead of the source directory in the PYTHONPATH environment variable set for ans.py servers started by start.pl so that they work correctly for both in-tree and out-of-tree builds. --- diff --git a/bin/tests/system/start.pl b/bin/tests/system/start.pl index 20e8bdc82ba..35a7efe6906 100755 --- a/bin/tests/system/start.pl +++ b/bin/tests/system/start.pl @@ -324,7 +324,7 @@ sub construct_ans_command { } if (-e "$testdir/$server/ans.py") { - $ENV{'PYTHONPATH'} = $testdir . ":" . $ENV{'srcdir'}; + $ENV{'PYTHONPATH'} = $testdir . ":" . $builddir; $command = "$PYTHON -u ans.py 10.53.0.$n $queryport"; } elsif (-e "$testdir/$server/ans.pl") { $command = "$PERL ans.pl";