Skip to content

Commit 8d0486f

Browse files
committed
Always add -Wl,-rpath to output of root-config --libs
Follows up on 26d24de, where the `rpath` configuration path was made the default and can't be disabled anymore. This means that the `rpath` CMake configuration option is gone, but there was still some code that checked it, which I missed to update. Addresses #19501 (comment).
1 parent 8429baa commit 8d0486f

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

config/root-config.in

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -331,11 +331,9 @@ case $arch in
331331
freebsd*)
332332
auxcflags="-pthread $auxcflags"
333333
auxlibs="-pthread $auxlibs"
334+
auxlibs="-Wl,-rpath,$libdir $auxlibs"
334335

335336
for f in $features ; do
336-
if test "x$f" = "xrpath" ; then
337-
auxlibs="-Wl,-rpath,$libdir $auxlibs"
338-
fi
339337
if test "x$f" = "xlibcxx" ; then
340338
auxcflags="-stdlib=libc++ $auxcflags"
341339
auxlibs="-stdlib=libc++ $auxlibs"
@@ -345,11 +343,9 @@ freebsd*)
345343
openbsd* | linux*)
346344
auxcflags="-pthread $auxcflags"
347345
auxlibs="-pthread $auxlibs"
346+
auxlibs="-Wl,-rpath,$libdir $auxlibs"
348347

349348
for f in $features ; do
350-
if test "x$f" = "xrpath" ; then
351-
auxlibs="-Wl,-rpath,$libdir $auxlibs"
352-
fi
353349
if test "x$f" = "xlibcxx" ; then
354350
auxcflags="-stdlib=libc++ $auxcflags"
355351
auxlibs="-stdlib=libc++ $auxlibs"
@@ -359,10 +355,9 @@ openbsd* | linux*)
359355
macosx*)
360356
auxcflags="-pthread $auxcflags"
361357
auxlibs="-lpthread $auxlibs"
358+
auxlibs="-Wl,-rpath,$libdir $auxlibs"
359+
362360
for f in $features ; do
363-
if test "x$f" = "xrpath" ; then
364-
auxlibs="-Wl,-rpath,$libdir $auxlibs"
365-
fi
366361
if test "x$f" = "xlibcxx" ; then
367362
auxcflags="-stdlib=libc++ $auxcflags"
368363
auxlibs="-stdlib=libc++ $auxlibs"

0 commit comments

Comments
 (0)