14887Schin######################################################################## 24887Schin# # 34887Schin# This software is part of the ast package # 4*12068SRoger.Faulkner@Oracle.COM# Copyright (c) 1985-2010 AT&T Intellectual Property # 54887Schin# and is licensed under the # 64887Schin# Common Public License, Version 1.0 # 78462SApril.Chin@Sun.COM# by AT&T Intellectual Property # 84887Schin# # 94887Schin# A copy of the License is available at # 104887Schin# http://www.opensource.org/licenses/cpl1.0.txt # 114887Schin# (with md5 checksum 059e8cd6165cb4c31e351f2b69388fd9) # 124887Schin# # 134887Schin# Information and Software Systems Research # 144887Schin# AT&T Research # 154887Schin# Florham Park NJ # 164887Schin# # 174887Schin# Glenn Fowler <gsf@research.att.com> # 184887Schin# David Korn <dgk@research.att.com> # 194887Schin# Phong Vo <kpv@research.att.com> # 204887Schin# # 214887Schin######################################################################## 224887Schinok=0 234887Schinfor i in \ 244887Schin -x /lib/ld.so /lib/ld-*.so /usr/lib/ld.so /lib/rld \ 254887Schin -f /usr/shlib/libc.so /shlib/libc.so /usr/lib/libc.so \ 264887Schin -r /usr/shlib/libc.so /shlib/libc.so 274887Schindo case $i in 284887Schin -*) op=$i; continue ;; 294887Schin esac 304887Schin if test $op $i 314887Schin then ok=1 324887Schin break 334887Schin fi 344887Schin set x $i.[0-9]* 354887Schin if test $op $2 364887Schin then ok=1 374887Schin break 384887Schin fi 394887Schindone 404887Schinif test "0" != "$ok" 414887Schinthen libpath=lib:LD_LIBRARY_PATH 424887Schin case `package` in 434887Schin sgi.*) if test -d /lib32 444887Schin then libpath="lib32:LD_LIBRARYN32_PATH:sgi.mips3|sgi.*-n32,$libpath" 454887Schin fi 464887Schin if test -d /lib64 474887Schin then libpath="lib64:LD_LIBRARY64_PATH:sgi.mips[4-9]|sgi.*-64,$libpath" 484887Schin fi 494887Schin ;; 504887Schin sol*.*) if test -d /lib/32 514887Schin then libpath="lib/32:LD_LIBRARY_PATH_32,$libpath" 524887Schin fi 534887Schin if test -d /lib/64 544887Schin then libpath="lib/64:LD_LIBRARY_PATH_64:sol.*64*,$libpath" 554887Schin fi 564887Schin ;; 574887Schin esac 584887Schinelif test -x /lib/dld.sl 594887Schinthen libpath=lib:SHLIB_PATH 604887Schinelif test -x /usr/lib/dyld 614887Schinthen libpath=lib:DYLD_LIBRARY_PATH 624887Schinelse case `package` in 634887Schin ibm.*|mvs.*) 644887Schin libpath=lib:LIBPATH 654887Schin ;; 664887Schin *) libpath= 674887Schin ;; 684887Schin esac 694887Schinfi 704887Schincase $libpath in 714887Schin'') libpath=bin ;; 724887Schinesac 734887Schinecho "#define CONF_LIBPATH \"$libpath\"" 74