mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-11-22 10:57:07 -08:00
dev-lang/php: Fix location of TEST_PHP_EXECUTABLE for FPM SAPI
The test suite for the FPM SAPI derives the location of the php-fpm binary from TEST_PHP_EXECUTABLE. Due to our build directory layout, the executable path can't be resolved properly. Worked around by providing a new TEST_PHP_FPM_EXECUTABLE variable we expose to the test suite. Signed-off-by: Lothar Serra Mari <mail@serra.me> Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
diff --git a/sapi/fpm/tests/tester.inc b/sapi/fpm/tests/tester.inc
|
||||
index 90798865433..91ba564edf8 100644
|
||||
--- a/sapi/fpm/tests/tester.inc
|
||||
+++ b/sapi/fpm/tests/tester.inc
|
||||
@@ -225,7 +225,7 @@ class Tester
|
||||
*/
|
||||
static public function findExecutable(): bool|string
|
||||
{
|
||||
- $phpPath = getenv("TEST_PHP_EXECUTABLE");
|
||||
+ $phpPath = getenv("TEST_PHP_FPM_EXECUTABLE");
|
||||
for ($i = 0; $i < 2; $i++) {
|
||||
$slashPosition = strrpos($phpPath, "/");
|
||||
if ($slashPosition) {
|
||||
@@ -135,6 +135,7 @@ DEPEND="${COMMON_DEPEND}
|
||||
BDEPEND="virtual/pkgconfig"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/php-set-fpm-test-executable.patch"
|
||||
"${FILESDIR}/php-8.3.31-ipv6-printing-test-fix.patch"
|
||||
)
|
||||
|
||||
@@ -729,6 +730,10 @@ src_test() {
|
||||
export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi"
|
||||
fi
|
||||
|
||||
if [[ -x "${WORKDIR}/sapis-build/fpm/sapi/fpm/php-fpm" ]] ; then
|
||||
export TEST_PHP_FPM_EXECUTABLE="${WORKDIR}/sapis-build/fpm/sapi/fpm/php-fpm"
|
||||
fi
|
||||
|
||||
if [[ -x "${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" ]] ; then
|
||||
export TEST_PHPDBG_EXECUTABLE="${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg"
|
||||
fi
|
||||
|
||||
@@ -136,6 +136,7 @@ DEPEND="${COMMON_DEPEND}
|
||||
BDEPEND="virtual/pkgconfig"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/php-set-fpm-test-executable.patch"
|
||||
"${FILESDIR}/php-8.3.31-ipv6-printing-test-fix.patch"
|
||||
)
|
||||
|
||||
@@ -728,6 +729,10 @@ src_test() {
|
||||
export TEST_PHP_CGI_EXECUTABLE="${WORKDIR}/sapis-build/cgi/sapi/cgi/php-cgi"
|
||||
fi
|
||||
|
||||
if [[ -x "${WORKDIR}/sapis-build/fpm/sapi/fpm/php-fpm" ]] ; then
|
||||
export TEST_PHP_FPM_EXECUTABLE="${WORKDIR}/sapis-build/fpm/sapi/fpm/php-fpm"
|
||||
fi
|
||||
|
||||
if [[ -x "${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg" ]] ; then
|
||||
export TEST_PHPDBG_EXECUTABLE="${WORKDIR}/sapis-build/phpdbg/sapi/phpdbg/phpdbg"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user