# original from Krishna Sethuraman, krishna@sgi.com
#
# Modified Mon Jul 22 14:52:25 EDT 1996
-# Andy Dougherty <doughera@lafcol.lafayette.edu>
+# Andy Dougherty <doughera@lafayette.edu>
# with help from Dean Roehrich <roehrich@cray.com>.
# cc -n32 update info from Krishna Sethuraman, krishna@sgi.com.
# additional update from Scott Henry, scotth@sgi.com
# 64-bitty by Jarkko Hietaniemi on 9/1998
+# Martin Pool added -shared for gcc on 2004-01-27
+
# Use sh Configure -Dcc='cc -n32' to try compiling with -n32.
# or -Dcc='cc -n32 -mips3' (or -mips4) to force (non)portability
# Don't bother with -n32 unless you have the 7.1 or later compilers.
test -z "$plibpth" && plibpth='/usr/lib64 /lib64 /usr/ccs/lib'
;;
*gcc*)
- ccflags="$ccflags -D_BSD_TYPES -D_BSD_TIME -D_POSIX_C_SOURCE"
+ ccflags="$ccflags -D_BSD_TYPES -D_BSD_TIME"
test -z "$optimize" && optimize="-O3"
usenm='undef'
+ # It seems gcc can build Irix shlibs, but of course it needs
+ # -shared. Otherwise you get link errors looking for main().
+ lddlflags="$lddlflags -shared"
case "`uname -s`" in
# Without the -mabi=64 gcc in 64-bit IRIX has problems passing
# and returning small structures. This affects inet_*() and semctl().
# We don't want these libraries.
# Socket networking is in libc, these are not installed by default,
# and just slow perl down. (scotth@sgi.com)
-set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /'`
+# librt contains nothing we need (some places need it for Time::HiRes) --jhi
+set `echo X "$libswanted "|sed -e 's/ socket / /' -e 's/ nsl / /' -e 's/ dl / /' -e 's/ rt / /'`
shift
libswanted="$*"