X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=blobdiff_plain;f=Configure;h=d55dd9416437d080c3fd12827e2c677171bf8fe2;hp=b35cc614598d23b8aa4400dc6f4118ea5a546db7;hb=c313e32a8b9514868f3fae09a8af025df76a4a8d;hpb=77519b51dbfe8652dad58536f6fa21a089080c1d diff --git a/Configure b/Configure index b35cc61459..d55dd94164 100755 --- a/Configure +++ b/Configure @@ -1181,8 +1181,10 @@ if (!$IsMK1MF) $cpuid_obj.=" uplink.o uplink-cof.o" if ($cflags =~ /\-DOPENSSL_USE_APPLINK/); -# Compiler fix-ups -if ($target =~ /icc$/) +# +# Platform fix-ups +# +if ($target =~ /\-icc$/) # Intel C compiler { my $iccver=0; if (open(FD,"$cc -V 2>&1 |")) @@ -1208,6 +1210,19 @@ if ($target =~ /icc$/) } } +# Unlike other OSes (like Solaris, Linux, Tru64, IRIX) BSD run-time +# linkers (tested OpenBSD, NetBSD and FreeBSD) "demand" RPATH set on +# .so objects. Apparently application RPATH is not global and does +# not apply to .so linked with other .so. Problem manifests itself +# when libssl.so fails to load libcrypto.so. One can argue that we +# should engrave this into Makefile.shared rules or into BSD-* config +# lines above. Meanwhile let's try to be cautious and pass -rpath to +# linker only when --prefix is not /usr. +if ($target =~ /^BSD\-/) + { + $shared_ldflag.=" -Wl,-rpath,\$(LIBRPATH)" if ($prefix !~ m|^/usr[/]*$|); + } + if ($sys_id ne "") { #$cflags="-DOPENSSL_SYSNAME_$sys_id $cflags";