--- util/makeshlib.sh.orig	Fri Feb  6 21:45:49 1998
+++ util/makeshlib.sh	Fri Nov  6 17:17:04 1998
@@ -17,6 +17,21 @@
 VERSION="$1" ; shift
 
 case $host  in
+*-*-freebsd*)
+	FILES=`for i
+	do
+		sed -e "s;^;$i/shared/;" -e "s; ; $i/shared/;g" -e "s;^$i/shared/\$;;" $i/DONE
+	done`
+	# Hack to deal with the fact that with cc options are different
+	# from ld...
+	ldflags=`echo $ldflags |sed  -e "s/-Wl,//g"`
+	if test "$PORTOBJFORMAT" = "elf"; then
+	    ldflags="$ldflags -soname $library"
+	fi
+	echo ld -Bshareable $ldflags -o $library $FILES $libdirfl $liblist
+	ld -Bshareable $ldflags -o $library $FILES $libdirfl $liblist
+	stat=$?
+	;;
 *-*-netbsd*)
 	FILES=`for i
 	do
