#! /bin/sh
arch=$1
osname=$2
suffix=$3
. pari/O$osname-$arch$suffix/dft.Config.in
# /usr/bin/sed on solaris does not understand \+ 
case "$DLLDFLAGS" in
  *LIBPARI_SONAME*)
	mydlldflags=`echo "$DLLDFLAGS" | sed -e 's/-[^ \t][^ \t]*[ \t][ \t]*\$(LIBPARI_SONAME)//'`;;
  *)
	mydlldflags=`echo "$DLLDFLAGS" | sed -e 's/-[^ \t][^ \t]*[ \t][ \t]*\$@//'`;;
esac

myincludedir=`echo "$includedir" | sed -e 's/\/pari\/\?$//'`
echo "$CC -c -o %s.o $cflags -I$myincludedir %s.c && $DLLD -o %s.$DLSUFFIX $mydlldflags $EXTRADLLDFLAGS %s.o"

