File:  [LON-CAPA] / loncom / homework / caparesponse / commands
Revision 1.10: download - view: text, annotated - select for diffs
Wed Jan 17 18:01:31 2001 UTC (23 years, 3 months ago) by harris41
Branches: MAIN
CVS tags: HEAD
inserting logic to make sure that swig is available if we are on a RedHat
system -Scott

CAPADIR=../../../CAPA

if test -f /etc/redhat-release
then
	if rpm -q swig
	then
		echo "Swig found.  Assuming it works..."
	else
		echo "ERROR ERROR: Swig must exist but doesn't!!!"
		echo "To get swig, go to"
		echo "http://install.lon-capa.org/3.1/SupplementalRPMS"
		echo "Install this RPM, swig-1.1p5-3.i386.rpm"
		exit 1
	fi
	if test -e /usr/include/asm
	then
		echo ""
	else
		ln -s /usr/src/linux/include/asm /usr/include/asm
	fi
	if test -e /usr/include/linux
	then
		echo ""
	else
		ln -s /usr/src/linux/include/linux /usr/include/linux
	fi
fi
make -f Makefile clean
mkdir capaFunctions
path=`pwd`
cd $CAPADIR/pProj
make ARCH=LONCAPA libcapa
cd $path
cp $CAPADIR/pProj/LONCAPA/*.o capaFunctions
swig -perl5 capa.i 
cp Makefile.PL Makefile.pl
perl Makefile.PL 
make -f Makefile 
cp blib/arch/auto/capa/capa.so . 
perl capa.pm     

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>