Skip to content

Commit b42409e

Browse files
committed
LD_LIBRARY_PATH for frankenphp sanity check
1 parent cb010d8 commit b42409e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/SPC/builder/unix/UnixBuilderBase.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,9 @@ protected function sanityCheck(int $build_target): void
227227
if (!file_exists($frankenphp)) {
228228
throw new RuntimeException('FrankenPHP binary not found: ' . $frankenphp);
229229
}
230-
[$ret, $output] = shell()->execWithResult("{$frankenphp} version");
230+
[$ret, $output] = shell()
231+
->setEnv(['LD_LIBRARY_PATH' => BUILD_LIB_PATH])
232+
->execWithResult("{$frankenphp} version");
231233
if ($ret !== 0 || !str_contains(implode('', $output), 'FrankenPHP')) {
232234
throw new RuntimeException('FrankenPHP failed sanity check: ret[' . $ret . ']. out[' . implode('', $output) . ']');
233235
}
@@ -308,7 +310,6 @@ protected function buildFrankenphp(): void
308310
$arch = arch2gnu(php_uname('m'));
309311

310312
// define executables for go and xcaddy
311-
$go_exec = PKG_ROOT_PATH . "/go-mod-frankenphp-{$arch}-{$os}/bin/go";
312313
$xcaddy_exec = PKG_ROOT_PATH . "/go-mod-frankenphp-{$arch}-{$os}/bin/xcaddy";
313314

314315
$nobrotli = $this->getLib('brotli') === null ? ',nobrotli' : '';

0 commit comments

Comments
 (0)