#!/bin/sh if test `whoami` != "root" ; then echo "-------------------------------------------------------------------" echo "ERROR! You must login as root in order to install this software" echo "-------------------------------------------------------------------" exit 0; fi if test -d $1 ; then echo "-------------------------------------------------------------------" echo "installing to: $1"; echo "-------------------------------------------------------------------" else echo "-------------------------------------------------------------------" echo "ERROR! The directory $1 does not exist." echo "You must choose an existing directory for installation." echo "-------------------------------------------------------------------" fi # copy files. if test -d $1/lib ; then echo else mkdir $1/lib fi cp ./lib/libmoth.a $1/lib chmod 644 $1/lib/libmoth.a if test -d $1/include ; then echo else mkdir $1/include fi if test -d $1/include/moth ; then echo else mkdir $1/include/moth fi cp ./include/moth/*.h $1/include/moth chmod 644 $1/include/moth/*.h