mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2024-11-25 11:14:15 +08:00
53 lines
1.0 KiB
Bash
53 lines
1.0 KiB
Bash
#!/bin/sh
|
|
|
|
# Make a Solaris shared library
|
|
# contributed by Arno Hahma (arno@nitro.pp.utu.fi)
|
|
|
|
#--identification------------------------------------------------------
|
|
|
|
# $Id: mklib.solaris,v 1.2 1999/09/15 15:10:20 brianp Exp $
|
|
|
|
# $Log: mklib.solaris,v $
|
|
# Revision 1.2 1999/09/15 15:10:20 brianp
|
|
# added third, tiny version number to arguments
|
|
#
|
|
# Revision 1.1 1999/08/19 13:53:06 brianp
|
|
# initial check-in (post-crash)
|
|
#
|
|
|
|
|
|
#--common--------------------------------------------------------------
|
|
|
|
LIBRARY=$1
|
|
shift 1
|
|
|
|
MAJOR=$1
|
|
shift 1
|
|
|
|
MINOR=$1
|
|
shift 1
|
|
|
|
TINY=$1
|
|
shift 1
|
|
|
|
OBJECTS=$*
|
|
|
|
#--platform-------------------------------------------------------------
|
|
|
|
set -x
|
|
|
|
LIBRARY=`basename $LIBRARY .a`
|
|
|
|
VERSION=$MAJOR.$MINOR
|
|
|
|
echo "Building shared object $LIBRARY.so.$VERSION and the archive library $LIBRARY.a"
|
|
rm -f ${LIBRARY}.a ${LIBRARY}.so.${VERSION}
|
|
ar ruv ${LIBRARY}.a ${OBJECTS}
|
|
|
|
ld -G -o ${LIBRARY}.so.${VERSION} ${OBJECTS}
|
|
|
|
cp ${LIBRARY}.a ${LIBRARY}.so.${VERSION} ../lib
|
|
cd ../lib
|
|
ln -s ${LIBRARY}.so.${VERSION} ${LIBRARY}.so
|
|
|