1 1.1 christos #! /bin/sh 2 1.1 christos # Output a system dependent set of variables, describing how to set the 3 1.1 christos # run time search path of shared libraries in an executable. 4 1.1 christos # 5 1.1 christos # Copyright 1996-2006 Free Software Foundation, Inc. 6 1.1 christos # Taken from GNU libtool, 2001 7 1.1 christos # Originally by Gordon Matzigkeit <gord (at] gnu.ai.mit.edu>, 1996 8 1.1 christos # 9 1.1 christos # This file is free software; the Free Software Foundation gives 10 1.1 christos # unlimited permission to copy and/or distribute it, with or without 11 1.1 christos # modifications, as long as this notice is preserved. 12 1.1 christos # 13 1.1 christos # The first argument passed to this file is the canonical host specification, 14 1.1 christos # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM 15 1.1 christos # or 16 1.1 christos # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM 17 1.1 christos # The environment variables CC, GCC, LDFLAGS, LD, with_gnu_ld 18 1.1 christos # should be set by the caller. 19 1.1 christos # 20 1.1 christos # The set of defined variables is at the end of this script. 21 1.1 christos 22 1.1 christos # Known limitations: 23 1.1 christos # - On IRIX 6.5 with CC="cc", the run time search patch must not be longer 24 1.1 christos # than 256 bytes, otherwise the compiler driver will dump core. The only 25 1.1 christos # known workaround is to choose shorter directory names for the build 26 1.1 christos # directory and/or the installation directory. 27 1.1 christos 28 1.1 christos # All known linkers require a `.a' archive for static linking (except MSVC, 29 1.1 christos # which needs '.lib'). 30 1.1 christos libext=a 31 1.1 christos shrext=.so 32 1.1 christos 33 1.1 christos host="$1" 34 1.1 christos host_cpu=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` 35 1.1 christos host_vendor=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` 36 1.1 christos host_os=`echo "$host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` 37 1.1 christos 38 1.1 christos # Code taken from libtool.m4's _LT_CC_BASENAME. 39 1.1 christos 40 1.1 christos for cc_temp in $CC""; do 41 1.1 christos case $cc_temp in 42 1.1 christos compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; 43 1.1 christos distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; 44 1.1 christos \-*) ;; 45 1.1 christos *) break;; 46 1.1 christos esac 47 1.1 christos done 48 1.1 christos cc_basename=`echo "$cc_temp" | sed -e 's%^.*/%%'` 49 1.1 christos 50 1.1 christos # Code taken from libtool.m4's AC_LIBTOOL_PROG_COMPILER_PIC. 51 1.1 christos 52 1.1 christos wl= 53 1.1 christos if test "$GCC" = yes; then 54 1.1 christos wl='-Wl,' 55 1.1 christos else 56 1.1 christos case "$host_os" in 57 1.1 christos aix*) 58 1.1 christos wl='-Wl,' 59 1.1 christos ;; 60 1.1 christos darwin*) 61 1.1 christos case $cc_basename in 62 1.1 christos xlc*) 63 1.1 christos wl='-Wl,' 64 1.1 christos ;; 65 1.1 christos esac 66 1.1 christos ;; 67 1.1 christos mingw* | pw32* | os2*) 68 1.1 christos ;; 69 1.1 christos hpux9* | hpux10* | hpux11*) 70 1.1 christos wl='-Wl,' 71 1.1 christos ;; 72 1.1 christos irix5* | irix6* | nonstopux*) 73 1.1 christos wl='-Wl,' 74 1.1 christos ;; 75 1.1 christos newsos6) 76 1.1 christos ;; 77 1.1 christos linux*) 78 1.1 christos case $cc_basename in 79 1.1 christos icc* | ecc*) 80 1.1 christos wl='-Wl,' 81 1.1 christos ;; 82 1.1 christos pgcc | pgf77 | pgf90) 83 1.1 christos wl='-Wl,' 84 1.1 christos ;; 85 1.1 christos ccc*) 86 1.1 christos wl='-Wl,' 87 1.1 christos ;; 88 1.1 christos como) 89 1.1 christos wl='-lopt=' 90 1.1 christos ;; 91 1.1 christos *) 92 1.1 christos case `$CC -V 2>&1 | sed 5q` in 93 1.1 christos *Sun\ C*) 94 1.1 christos wl='-Wl,' 95 1.1 christos ;; 96 1.1 christos esac 97 1.1 christos ;; 98 1.1 christos esac 99 1.1 christos ;; 100 1.1 christos osf3* | osf4* | osf5*) 101 1.1 christos wl='-Wl,' 102 1.1 christos ;; 103 1.1 christos sco3.2v5*) 104 1.1 christos ;; 105 1.1 christos solaris*) 106 1.1 christos wl='-Wl,' 107 1.1 christos ;; 108 1.1 christos sunos4*) 109 1.1 christos wl='-Qoption ld ' 110 1.1 christos ;; 111 1.1 christos sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 112 1.1 christos wl='-Wl,' 113 1.1 christos ;; 114 1.1 christos sysv4*MP*) 115 1.1 christos ;; 116 1.1 christos unicos*) 117 1.1 christos wl='-Wl,' 118 1.1 christos ;; 119 1.1 christos uts4*) 120 1.1 christos ;; 121 1.1 christos esac 122 1.1 christos fi 123 1.1 christos 124 1.1 christos # Code taken from libtool.m4's AC_LIBTOOL_PROG_LD_SHLIBS. 125 1.1 christos 126 1.1 christos hardcode_libdir_flag_spec= 127 1.1 christos hardcode_libdir_separator= 128 1.1 christos hardcode_direct=no 129 1.1 christos hardcode_minus_L=no 130 1.1 christos 131 1.1 christos case "$host_os" in 132 1.1 christos cygwin* | mingw* | pw32*) 133 1.1 christos # FIXME: the MSVC++ port hasn't been tested in a loooong time 134 1.1 christos # When not using gcc, we currently assume that we are using 135 1.1 christos # Microsoft Visual C++. 136 1.1 christos if test "$GCC" != yes; then 137 1.1 christos with_gnu_ld=no 138 1.1 christos fi 139 1.1 christos ;; 140 1.1 christos interix*) 141 1.1 christos # we just hope/assume this is gcc and not c89 (= MSVC++) 142 1.1 christos with_gnu_ld=yes 143 1.1 christos ;; 144 1.1 christos openbsd*) 145 1.1 christos with_gnu_ld=no 146 1.1 christos ;; 147 1.1 christos esac 148 1.1 christos 149 1.1 christos ld_shlibs=yes 150 1.1 christos if test "$with_gnu_ld" = yes; then 151 1.1 christos # Set some defaults for GNU ld with shared library support. These 152 1.1 christos # are reset later if shared libraries are not supported. Putting them 153 1.1 christos # here allows them to be overridden if necessary. 154 1.1 christos # Unlike libtool, we use -rpath here, not --rpath, since the documented 155 1.1 christos # option of GNU ld is called -rpath, not --rpath. 156 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' 157 1.1 christos case "$host_os" in 158 1.1 christos aix3* | aix4* | aix5*) 159 1.1 christos # On AIX/PPC, the GNU linker is very broken 160 1.1 christos if test "$host_cpu" != ia64; then 161 1.1 christos ld_shlibs=no 162 1.1 christos fi 163 1.1 christos ;; 164 1.1 christos amigaos*) 165 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 166 1.1 christos hardcode_minus_L=yes 167 1.1 christos # Samuel A. Falvo II <kc5tja (at] dolphin.openprojects.net> reports 168 1.1 christos # that the semantics of dynamic libraries on AmigaOS, at least up 169 1.1 christos # to version 4, is to share data among multiple programs linked 170 1.1 christos # with the same dynamic library. Since this doesn't match the 171 1.1 christos # behavior of shared libraries on other platforms, we cannot use 172 1.1 christos # them. 173 1.1 christos ld_shlibs=no 174 1.1 christos ;; 175 1.1 christos beos*) 176 1.1 christos if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 177 1.1 christos : 178 1.1 christos else 179 1.1 christos ld_shlibs=no 180 1.1 christos fi 181 1.1 christos ;; 182 1.1 christos cygwin* | mingw* | pw32*) 183 1.1 christos # hardcode_libdir_flag_spec is actually meaningless, as there is 184 1.1 christos # no search path for DLLs. 185 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 186 1.1 christos if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then 187 1.1 christos : 188 1.1 christos else 189 1.1 christos ld_shlibs=no 190 1.1 christos fi 191 1.1 christos ;; 192 1.1 christos interix3*) 193 1.1 christos hardcode_direct=no 194 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath,$libdir' 195 1.1 christos ;; 196 1.1 christos linux*) 197 1.1 christos if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 198 1.1 christos : 199 1.1 christos else 200 1.1 christos ld_shlibs=no 201 1.1 christos fi 202 1.1 christos ;; 203 1.1 christos netbsd*) 204 1.1 christos ;; 205 1.1 christos solaris*) 206 1.1 christos if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then 207 1.1 christos ld_shlibs=no 208 1.1 christos elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 209 1.1 christos : 210 1.1 christos else 211 1.1 christos ld_shlibs=no 212 1.1 christos fi 213 1.1 christos ;; 214 1.1 christos sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) 215 1.1 christos case `$LD -v 2>&1` in 216 1.1 christos *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) 217 1.1 christos ld_shlibs=no 218 1.1 christos ;; 219 1.1 christos *) 220 1.1 christos if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 221 1.1 christos hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' 222 1.1 christos else 223 1.1 christos ld_shlibs=no 224 1.1 christos fi 225 1.1 christos ;; 226 1.1 christos esac 227 1.1 christos ;; 228 1.1 christos sunos4*) 229 1.1 christos hardcode_direct=yes 230 1.1 christos ;; 231 1.1 christos *) 232 1.1 christos if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then 233 1.1 christos : 234 1.1 christos else 235 1.1 christos ld_shlibs=no 236 1.1 christos fi 237 1.1 christos ;; 238 1.1 christos esac 239 1.1 christos if test "$ld_shlibs" = no; then 240 1.1 christos hardcode_libdir_flag_spec= 241 1.1 christos fi 242 1.1 christos else 243 1.1 christos case "$host_os" in 244 1.1 christos aix3*) 245 1.1 christos # Note: this linker hardcodes the directories in LIBPATH if there 246 1.1 christos # are no directories specified by -L. 247 1.1 christos hardcode_minus_L=yes 248 1.1 christos if test "$GCC" = yes; then 249 1.1 christos # Neither direct hardcoding nor static linking is supported with a 250 1.1 christos # broken collect2. 251 1.1 christos hardcode_direct=unsupported 252 1.1 christos fi 253 1.1 christos ;; 254 1.1 christos aix4* | aix5*) 255 1.1 christos if test "$host_cpu" = ia64; then 256 1.1 christos # On IA64, the linker does run time linking by default, so we don't 257 1.1 christos # have to do anything special. 258 1.1 christos aix_use_runtimelinking=no 259 1.1 christos else 260 1.1 christos aix_use_runtimelinking=no 261 1.1 christos # Test if we are trying to use run time linking or normal 262 1.1 christos # AIX style linking. If -brtl is somewhere in LDFLAGS, we 263 1.1 christos # need to do runtime linking. 264 1.1 christos case $host_os in aix4.[23]|aix4.[23].*|aix5*) 265 1.1 christos for ld_flag in $LDFLAGS; do 266 1.1 christos if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then 267 1.1 christos aix_use_runtimelinking=yes 268 1.1 christos break 269 1.1 christos fi 270 1.1 christos done 271 1.1 christos ;; 272 1.1 christos esac 273 1.1 christos fi 274 1.1 christos hardcode_direct=yes 275 1.1 christos hardcode_libdir_separator=':' 276 1.1 christos if test "$GCC" = yes; then 277 1.1 christos case $host_os in aix4.[012]|aix4.[012].*) 278 1.1 christos collect2name=`${CC} -print-prog-name=collect2` 279 1.1 christos if test -f "$collect2name" && \ 280 1.1 christos strings "$collect2name" | grep resolve_lib_name >/dev/null 281 1.1 christos then 282 1.1 christos # We have reworked collect2 283 1.1 christos hardcode_direct=yes 284 1.1 christos else 285 1.1 christos # We have old collect2 286 1.1 christos hardcode_direct=unsupported 287 1.1 christos hardcode_minus_L=yes 288 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 289 1.1 christos hardcode_libdir_separator= 290 1.1 christos fi 291 1.1 christos ;; 292 1.1 christos esac 293 1.1 christos fi 294 1.1 christos # Begin _LT_AC_SYS_LIBPATH_AIX. 295 1.1 christos echo 'int main () { return 0; }' > conftest.c 296 1.1 christos ${CC} ${LDFLAGS} conftest.c -o conftest 297 1.1 christos aix_libpath=`dump -H conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } 298 1.1 christos }'` 299 1.1 christos if test -z "$aix_libpath"; then 300 1.1 christos aix_libpath=`dump -HX64 conftest 2>/dev/null | sed -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } 301 1.1 christos }'` 302 1.1 christos fi 303 1.1 christos if test -z "$aix_libpath"; then 304 1.1 christos aix_libpath="/usr/lib:/lib" 305 1.1 christos fi 306 1.1 christos rm -f conftest.c conftest 307 1.1 christos # End _LT_AC_SYS_LIBPATH_AIX. 308 1.1 christos if test "$aix_use_runtimelinking" = yes; then 309 1.1 christos hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" 310 1.1 christos else 311 1.1 christos if test "$host_cpu" = ia64; then 312 1.1 christos hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' 313 1.1 christos else 314 1.1 christos hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" 315 1.1 christos fi 316 1.1 christos fi 317 1.1 christos ;; 318 1.1 christos amigaos*) 319 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 320 1.1 christos hardcode_minus_L=yes 321 1.1 christos # see comment about different semantics on the GNU ld section 322 1.1 christos ld_shlibs=no 323 1.1 christos ;; 324 1.1 christos bsdi[45]*) 325 1.1 christos ;; 326 1.1 christos cygwin* | mingw* | pw32*) 327 1.1 christos # When not using gcc, we currently assume that we are using 328 1.1 christos # Microsoft Visual C++. 329 1.1 christos # hardcode_libdir_flag_spec is actually meaningless, as there is 330 1.1 christos # no search path for DLLs. 331 1.1 christos hardcode_libdir_flag_spec=' ' 332 1.1 christos libext=lib 333 1.1 christos ;; 334 1.1 christos darwin* | rhapsody*) 335 1.1 christos hardcode_direct=no 336 1.1 christos if test "$GCC" = yes ; then 337 1.1 christos : 338 1.1 christos else 339 1.1 christos case $cc_basename in 340 1.1 christos xlc*) 341 1.1 christos ;; 342 1.1 christos *) 343 1.1 christos ld_shlibs=no 344 1.1 christos ;; 345 1.1 christos esac 346 1.1 christos fi 347 1.1 christos ;; 348 1.1 christos dgux*) 349 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 350 1.1 christos ;; 351 1.1 christos freebsd1*) 352 1.1 christos ld_shlibs=no 353 1.1 christos ;; 354 1.1 christos freebsd2.2*) 355 1.1 christos hardcode_libdir_flag_spec='-R$libdir' 356 1.1 christos hardcode_direct=yes 357 1.1 christos ;; 358 1.1 christos freebsd2*) 359 1.1 christos hardcode_direct=yes 360 1.1 christos hardcode_minus_L=yes 361 1.1 christos ;; 362 1.1 christos freebsd* | kfreebsd*-gnu | dragonfly*) 363 1.1 christos hardcode_libdir_flag_spec='-R$libdir' 364 1.1 christos hardcode_direct=yes 365 1.1 christos ;; 366 1.1 christos hpux9*) 367 1.1 christos hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' 368 1.1 christos hardcode_libdir_separator=: 369 1.1 christos hardcode_direct=yes 370 1.1 christos # hardcode_minus_L: Not really in the search PATH, 371 1.1 christos # but as the default location of the library. 372 1.1 christos hardcode_minus_L=yes 373 1.1 christos ;; 374 1.1 christos hpux10*) 375 1.1 christos if test "$with_gnu_ld" = no; then 376 1.1 christos hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' 377 1.1 christos hardcode_libdir_separator=: 378 1.1 christos hardcode_direct=yes 379 1.1 christos # hardcode_minus_L: Not really in the search PATH, 380 1.1 christos # but as the default location of the library. 381 1.1 christos hardcode_minus_L=yes 382 1.1 christos fi 383 1.1 christos ;; 384 1.1 christos hpux11*) 385 1.1 christos if test "$with_gnu_ld" = no; then 386 1.1 christos hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' 387 1.1 christos hardcode_libdir_separator=: 388 1.1 christos case $host_cpu in 389 1.1 christos hppa*64*|ia64*) 390 1.1 christos hardcode_direct=no 391 1.1 christos ;; 392 1.1 christos *) 393 1.1 christos hardcode_direct=yes 394 1.1 christos # hardcode_minus_L: Not really in the search PATH, 395 1.1 christos # but as the default location of the library. 396 1.1 christos hardcode_minus_L=yes 397 1.1 christos ;; 398 1.1 christos esac 399 1.1 christos fi 400 1.1 christos ;; 401 1.1 christos irix5* | irix6* | nonstopux*) 402 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' 403 1.1 christos hardcode_libdir_separator=: 404 1.1 christos ;; 405 1.1 christos netbsd*) 406 1.1 christos hardcode_libdir_flag_spec='-R$libdir' 407 1.1 christos hardcode_direct=yes 408 1.1 christos ;; 409 1.1 christos newsos6) 410 1.1 christos hardcode_direct=yes 411 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' 412 1.1 christos hardcode_libdir_separator=: 413 1.1 christos ;; 414 1.1 christos openbsd*) 415 1.1 christos hardcode_direct=yes 416 1.1 christos if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then 417 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath,$libdir' 418 1.1 christos else 419 1.1 christos case "$host_os" in 420 1.1 christos openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) 421 1.1 christos hardcode_libdir_flag_spec='-R$libdir' 422 1.1 christos ;; 423 1.1 christos *) 424 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath,$libdir' 425 1.1 christos ;; 426 1.1 christos esac 427 1.1 christos fi 428 1.1 christos ;; 429 1.1 christos os2*) 430 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 431 1.1 christos hardcode_minus_L=yes 432 1.1 christos ;; 433 1.1 christos osf3*) 434 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' 435 1.1 christos hardcode_libdir_separator=: 436 1.1 christos ;; 437 1.1 christos osf4* | osf5*) 438 1.1 christos if test "$GCC" = yes; then 439 1.1 christos hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' 440 1.1 christos else 441 1.1 christos # Both cc and cxx compiler support -rpath directly 442 1.1 christos hardcode_libdir_flag_spec='-rpath $libdir' 443 1.1 christos fi 444 1.1 christos hardcode_libdir_separator=: 445 1.1 christos ;; 446 1.1 christos solaris*) 447 1.1 christos hardcode_libdir_flag_spec='-R$libdir' 448 1.1 christos ;; 449 1.1 christos sunos4*) 450 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 451 1.1 christos hardcode_direct=yes 452 1.1 christos hardcode_minus_L=yes 453 1.1 christos ;; 454 1.1 christos sysv4) 455 1.1 christos case $host_vendor in 456 1.1 christos sni) 457 1.1 christos hardcode_direct=yes # is this really true??? 458 1.1 christos ;; 459 1.1 christos siemens) 460 1.1 christos hardcode_direct=no 461 1.1 christos ;; 462 1.1 christos motorola) 463 1.1 christos hardcode_direct=no #Motorola manual says yes, but my tests say they lie 464 1.1 christos ;; 465 1.1 christos esac 466 1.1 christos ;; 467 1.1 christos sysv4.3*) 468 1.1 christos ;; 469 1.1 christos sysv4*MP*) 470 1.1 christos if test -d /usr/nec; then 471 1.1 christos ld_shlibs=yes 472 1.1 christos fi 473 1.1 christos ;; 474 1.1 christos sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7*) 475 1.1 christos ;; 476 1.1 christos sysv5* | sco3.2v5* | sco5v6*) 477 1.1 christos hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' 478 1.1 christos hardcode_libdir_separator=':' 479 1.1 christos ;; 480 1.1 christos uts4*) 481 1.1 christos hardcode_libdir_flag_spec='-L$libdir' 482 1.1 christos ;; 483 1.1 christos *) 484 1.1 christos ld_shlibs=no 485 1.1 christos ;; 486 1.1 christos esac 487 1.1 christos fi 488 1.1 christos 489 1.1 christos # Check dynamic linker characteristics 490 1.1 christos # Code taken from libtool.m4's AC_LIBTOOL_SYS_DYNAMIC_LINKER. 491 1.1 christos libname_spec='lib$name' 492 1.1 christos case "$host_os" in 493 1.1 christos aix3*) 494 1.1 christos ;; 495 1.1 christos aix4* | aix5*) 496 1.1 christos ;; 497 1.1 christos amigaos*) 498 1.1 christos ;; 499 1.1 christos beos*) 500 1.1 christos ;; 501 1.1 christos bsdi[45]*) 502 1.1 christos ;; 503 1.1 christos cygwin* | mingw* | pw32*) 504 1.1 christos shrext=.dll 505 1.1 christos ;; 506 1.1 christos darwin* | rhapsody*) 507 1.1 christos shrext=.dylib 508 1.1 christos ;; 509 1.1 christos dgux*) 510 1.1 christos ;; 511 1.1 christos freebsd1*) 512 1.1 christos ;; 513 1.1 christos kfreebsd*-gnu) 514 1.1 christos ;; 515 1.1 christos freebsd* | dragonfly*) 516 1.1 christos ;; 517 1.1 christos gnu*) 518 1.1 christos ;; 519 1.1 christos hpux9* | hpux10* | hpux11*) 520 1.1 christos case $host_cpu in 521 1.1 christos ia64*) 522 1.1 christos shrext=.so 523 1.1 christos ;; 524 1.1 christos hppa*64*) 525 1.1 christos shrext=.sl 526 1.1 christos ;; 527 1.1 christos *) 528 1.1 christos shrext=.sl 529 1.1 christos ;; 530 1.1 christos esac 531 1.1 christos ;; 532 1.1 christos interix3*) 533 1.1 christos ;; 534 1.1 christos irix5* | irix6* | nonstopux*) 535 1.1 christos case "$host_os" in 536 1.1 christos irix5* | nonstopux*) 537 1.1 christos libsuff= shlibsuff= 538 1.1 christos ;; 539 1.1 christos *) 540 1.1 christos case $LD in 541 1.1 christos *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= ;; 542 1.1 christos *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 ;; 543 1.1 christos *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 ;; 544 1.1 christos *) libsuff= shlibsuff= ;; 545 1.1 christos esac 546 1.1 christos ;; 547 1.1 christos esac 548 1.1 christos ;; 549 1.1 christos linux*oldld* | linux*aout* | linux*coff*) 550 1.1 christos ;; 551 1.1 christos linux*) 552 1.1 christos ;; 553 1.1 christos knetbsd*-gnu) 554 1.1 christos ;; 555 1.1 christos netbsd*) 556 1.1 christos ;; 557 1.1 christos newsos6) 558 1.1 christos ;; 559 1.1 christos nto-qnx*) 560 1.1 christos ;; 561 1.1 christos openbsd*) 562 1.1 christos ;; 563 1.1 christos os2*) 564 1.1 christos libname_spec='$name' 565 1.1 christos shrext=.dll 566 1.1 christos ;; 567 1.1 christos osf3* | osf4* | osf5*) 568 1.1 christos ;; 569 1.1 christos solaris*) 570 1.1 christos ;; 571 1.1 christos sunos4*) 572 1.1 christos ;; 573 1.1 christos sysv4 | sysv4.3*) 574 1.1 christos ;; 575 1.1 christos sysv4*MP*) 576 1.1 christos ;; 577 1.1 christos sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) 578 1.1 christos ;; 579 1.1 christos uts4*) 580 1.1 christos ;; 581 1.1 christos esac 582 1.1 christos 583 1.1 christos sed_quote_subst='s/\(["`$\\]\)/\\\1/g' 584 1.1 christos escaped_wl=`echo "X$wl" | sed -e 's/^X//' -e "$sed_quote_subst"` 585 1.1 christos shlibext=`echo "$shrext" | sed -e 's,^\.,,'` 586 1.1 christos escaped_hardcode_libdir_flag_spec=`echo "X$hardcode_libdir_flag_spec" | sed -e 's/^X//' -e "$sed_quote_subst"` 587 1.1 christos 588 1.1 christos LC_ALL=C sed -e 's/^\([a-zA-Z0-9_]*\)=/acl_cv_\1=/' <<EOF 589 1.1 christos 590 1.1 christos # How to pass a linker flag through the compiler. 591 1.1 christos wl="$escaped_wl" 592 1.1 christos 593 1.1 christos # Static library suffix (normally "a"). 594 1.1 christos libext="$libext" 595 1.1 christos 596 1.1 christos # Shared library suffix (normally "so"). 597 1.1 christos shlibext="$shlibext" 598 1.1 christos 599 1.1 christos # Flag to hardcode \$libdir into a binary during linking. 600 1.1 christos # This must work even if \$libdir does not exist. 601 1.1 christos hardcode_libdir_flag_spec="$escaped_hardcode_libdir_flag_spec" 602 1.1 christos 603 1.1 christos # Whether we need a single -rpath flag with a separated argument. 604 1.1 christos hardcode_libdir_separator="$hardcode_libdir_separator" 605 1.1 christos 606 1.1 christos # Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the 607 1.1 christos # resulting binary. 608 1.1 christos hardcode_direct="$hardcode_direct" 609 1.1 christos 610 1.1 christos # Set to yes if using the -LDIR flag during linking hardcodes DIR into the 611 1.1 christos # resulting binary. 612 1.1 christos hardcode_minus_L="$hardcode_minus_L" 613 1.1 christos 614 1.1 christos EOF 615