#!/bin/sh # # Install script to w32dlib # # $Id$ # if [ "$2" == "" ] ; then echo usage: $0 install-dir script-flag exit 1 fi incbase=$1/include incdir=$incbase/w32dlib libdir=$1/lib mkinfo=$2 conf=/usr/local/bin/w32dlib-config echo ==== Copying header files to $incdir ==== mkdir -p $incdir cp --verbose --force w32dlib/*.h $incdir echo ==== Copying library files to $libdir ==== mkdir -p $libdir cp --verbose --force libw32dlib.a $libdir if [ $mkinfo == "1" ] ; then echo ==== Creating $conf ==== cat << EOF > $conf #!/bin/sh if [ "\$1" == "--libs" ] ; then echo -L$libdir -mwindows -lw32dlib elif [ "\$1" == "--cflags" ] ; then echo -I$incbase elif [ "\$1" == "--archive" ] ; then echo $libdir/libw32dlib.a else echo usage: \$0 [--libs\|--cflags\|-archive] fi EOF fi exit 0