Skip to content

Commit 695e259

Browse files
committed
relative rpath for librdkafka links
1 parent 6746c8f commit 695e259

File tree

2 files changed

+6
-1
lines changed
  • support/build/extensions

2 files changed

+6
-1
lines changed

support/build/extensions/no-debug-non-zts-20180731/rdkafka

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,8 @@ esac
1717

1818
CONFIGURE_EXTRA="--with-rdkafka=${OUT_PREFIX}"
1919

20+
from_ext_to_lib=$(realpath --relative-to="$(php-config --extension-dir)" "${OUT_PREFIX}/lib")
21+
22+
MAKE_EXTRA="LDFLAGS=${LDFLAGS:--Wl},-rpath='\$\$ORIGIN/${from_ext_to_lib}'"
23+
2024
source $(dirname $BASH_SOURCE)/../pecl

support/build/extensions/pecl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ phpize
2929
./configure \
3030
--prefix=${OUT_PREFIX} \
3131
${CONFIGURE_EXTRA:-}
32-
make -s -j $(($(nproc)+1))
32+
make -s -j $(($(nproc)+1)) \
33+
${MAKE_EXTRA:-}
3334

3435
# php was a build dep, and it's in $OUT_PREFIX; we only want our build results in the final archive, and no build deps
3536
# the easiest way is to nuke $OUT_PREFIX and running "make install", but extensions built for PHP 8.1+ need PHP headers during linking

0 commit comments

Comments
 (0)