Skip to content

Commit

Permalink
CI: Use LD_RUN_PATH during the httpd build to embed the path to OpenSSL
Browse files Browse the repository at this point in the history
in httpd binaries, but unset it after so that it doesn't affect running
e.g. php-fpm or perl later. Should fix warning from logs when php-fpm
is executed --

[26-Jul-2024 07:43:34] NOTICE: PHP message: PHP Warning:  PHP Startup: Unable to load dynamic library 'curl.so' (tried: /usr/lib/php/20210902/curl.so (/lib/x86_64-linux-gnu/libcurl.so.4: undefined symbol: ENGINE_init, version OPENSSL_3.0.0), /usr/lib/php/20210902/curl.so.so (/usr/lib/php/20210902/curl.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
  • Loading branch information
notroj committed Jul 26, 2024
1 parent 09aa4aa commit 23a13f0
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion test/travis_run_linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ fi

if test -v TEST_OPENSSL3; then
CONFIG="$CONFIG --with-ssl=$HOME/root/openssl3"
export LD_LIBRARY_PATH=$HOME/root/openssl3/lib:$HOME/root/openssl3/lib64
# Temporarily set LD_RUN_PATH so that httpd/mod_ssl binaries pick
# up the custom OpenSSL build
export LD_RUN_PATH=$HOME/root/openssl3/lib:$HOME/root/openssl3/lib64
export PATH=$HOME/root/openssl3/bin:$PATH
openssl version
fi
Expand All @@ -78,6 +80,14 @@ builddir=$PWD
$srcdir/configure --prefix=$PREFIX $CONFIG
make $MFLAGS

if test -v TEST_OPENSSL3
# Clear the library/run paths so that anything else run during
# testing is not forced to use the custom OpenSSL build; e.g. perl,
# php-fpm, ...
unset LD_LIBRARY_PATH
unset LD_RUN_PATH
fi

if test -v TEST_INSTALL; then
make install
pushd $PREFIX
Expand Down

0 comments on commit 23a13f0

Please sign in to comment.