#!/bin/sh

# Make an n32 IRIX 6.x DSO

# $Id: mklib.irix6-n32,v 1.1 1996/09/26 22:38:49 brianp Exp $

# $Log: mklib.irix6-n32,v $
# Revision 1.1  1996/09/26 22:38:49  brianp
# Initial revision
#


# First argument is name of output library
# Rest of arguments are object files

LIBRARY=$1

shift 1
OBJECTS=$*


# This is a bit of a kludge, but...
if test ${LIBRARY} = "libMesaGL.so" ; then
	# must add libXext.a to MesaGL.so in case one relinks a precompiled
	# OpenGL program which wasn't linked with -lXext.
	OBJECTS="${OBJECTS} -lXext"
fi


ld -n32 -shared -all -o ${LIBRARY} ${OBJECTS}


# You may want to add the following to the ld line:
#   -soname <path>$LIBNAME
#
# where LIBNAME=`basename $LIBRARY` and <path> is where you're going to
# put Mesa's libraries.  This may solve problems with the runtime
# loader/linker (rld) not being able to find the library.
# For example:  -soname /usr/local/lib/$LIBNAME
