blob: f13da91f390043ccbe28e033bd8f52609c942b93 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001 build/ltmain.sh | 32 +++++++++++++++++++++++++++-----
2 1 file changed, 27 insertions(+), 5 deletions(-)
3
Brad Bishop316dfdd2018-06-25 12:45:53 -04004Index: httpd-2.4.29/build/ltmain.sh
5===================================================================
6--- httpd-2.4.29.orig/build/ltmain.sh
7+++ httpd-2.4.29/build/ltmain.sh
8@@ -6969,7 +6969,7 @@ func_mode_link ()
Patrick Williamsb48b7b42016-08-17 15:04:38 -05009 dir=$func_resolve_sysroot_result
10 # We need an absolute path.
11 case $dir in
12- [\\/]* | [A-Za-z]:[\\/]*) ;;
13+ =* | [\\/]* | [A-Za-z]:[\\/]*) ;;
14 *)
15 absdir=`cd "$dir" && pwd`
16 test -z "$absdir" && \
Brad Bishop316dfdd2018-06-25 12:45:53 -040017@@ -8167,7 +8167,7 @@ func_mode_link ()
Patrick Williamsb48b7b42016-08-17 15:04:38 -050018 $ECHO "*** $linklib is not portable!"
19 fi
20 if test lib = "$linkmode" &&
21- test yes = "$hardcode_into_libs"; then
22+ test "x$wrs_use_rpaths" = "xyes" && test "$hardcode_into_libs" = yes; then
23 # Hardcode the library path.
24 # Skip directories that are in the system default run-time
25 # search path.
Brad Bishop316dfdd2018-06-25 12:45:53 -040026@@ -8434,7 +8434,7 @@ func_mode_link ()
Patrick Williamsb48b7b42016-08-17 15:04:38 -050027
28 if test lib = "$linkmode"; then
29 if test -n "$dependency_libs" &&
30- { test yes != "$hardcode_into_libs" ||
31+ { test yes != "$hardcode_into_libs" || test "x$wrs_use_rpaths" != "xyes" ||
32 test yes = "$build_old_libs" ||
33 test yes = "$link_static"; }; then
34 # Extract -R from dependency_libs
Brad Bishop316dfdd2018-06-25 12:45:53 -040035@@ -9086,7 +9086,8 @@ func_mode_link ()
Patrick Williamsb48b7b42016-08-17 15:04:38 -050036 *) func_append finalize_rpath " $libdir" ;;
37 esac
38 done
39- if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then
40+ if test yes != "$hardcode_into_libs" || test "x$wrs_use_rpaths" != "xyes" ||
41+ test yes = "$build_old_libs"; then
42 dependency_libs="$temp_xrpath $dependency_libs"
43 fi
44 fi
Brad Bishop316dfdd2018-06-25 12:45:53 -040045@@ -9534,7 +9535,7 @@ EOF
Patrick Williamsb48b7b42016-08-17 15:04:38 -050046 case $archive_cmds in
47 *\$LD\ *) wl= ;;
48 esac
49- if test yes = "$hardcode_into_libs"; then
50+ if test yes = "$hardcode_into_libs" && test "x$wrs_use_rpaths" = "xyes"; then
51 # Hardcode the library paths
52 hardcode_libdirs=
53 dep_rpath=
Brad Bishop316dfdd2018-06-25 12:45:53 -040054@@ -10272,6 +10273,27 @@ EOF
Patrick Williamsb48b7b42016-08-17 15:04:38 -050055 # Now hardcode the library paths
56 rpath=
57 hardcode_libdirs=
58+
59+ # short circuit putting rpaths in executables
60+ #
61+ if test "x$wrs_use_rpaths" != "xyes" ; then
62+ flag=
63+ for libdir in $compile_rpath; do
64+ case $(echo $libdir | ${SED} 's,/[/]*,/,g') in
65+ /usr/lib/* | /usr/lib32/* | /usr/lib64/* ) flag="$flag $libdir" ;;
66+ esac
67+ done
68+ compile_rpath="$flag"
69+
70+ flag=
71+ for libdir in $finalize_rpath; do
72+ case $(echo $libdir | ${SED} 's,/[/]*,/,g') in
73+ /usr/lib/* | /usr/lib32/* | /usr/lib64/* ) flag="$flag $libdir" ;;
74+ esac
75+ done
76+ finalize_rpath="$flag"
77+ fi
78+
79 for libdir in $compile_rpath $finalize_rpath; do
80 if test -n "$hardcode_libdir_flag_spec"; then
81 if test -n "$hardcode_libdir_separator"; then