# This is a bourne shell script. # @(#)SUN_LIB_DEF version 3.23 created 6/13/96 # @(#)Copyright (c), 1987, 1996 StatSci, Inc. All rights reserved. # This script produces (on standard output) a suggested library # specification for linking S-PLUS using ld(1) on the Sun (Sun puts # the libraries in different places for different versions). The ouput # excludes the C library. # Exit status is 0 for ok, non-zero for can't come up with specification. # It finds the specification by checking what directories exist. # (This could also use f77(1) -v, but it may not be so good to make this # automatic. If things aren't as we expect, we might tell how to use # f77 -v, but probably good to make users aware that things are not # what we expected at the time of S-PLUS release.) # Fortran versions currently supported: 1.4, 1.3, 1.2 (and older). # If you have later versions, this script likely won't not know about them. # The RUNPATH variable is currently only used on the Solaris and is used # to set up the run-time location for picking up the required libraries # when LD_LIBRARY_PATH is not set. SUN_LANG="/opt/SUNWspro" SUN_LIB="$SUN_LANG/lib" # Figure out what library specification to go with. RUNPATH="" if [ -d "$SUN_LANG/SC3.0.1/lib" ]; then RUNPATH="-R/opt/SUNWspro/SC3.0.1/lib" fi LIB_RESULT="$RUNPATH -Bdynamic -lF77 -lM77 -lsunmath -lelf -ldl" # Other library specifications used for S-PLUS. LIB_OTHER="-lm" # Produce output. LIB_RESULT="$LIB_RESULT $LIB_OTHER" echo $LIB_RESULT # Done. exit 0