#!/bin/sh # Part of EasySQL, Copyright (c) 1997 by Andrew Maltsev # # This is NOT autoconf derived `configure' and it doesn't accept any # autoconf nifty switches. May be it will be converted to autoconf, but # not now. Btw - it's good place for contribution.. # # Asking a question. Answer is in `asnwer' and default value is in `default' # ask () { if [ "x$default" = x ] then default=none fi echo -n "$* ? [$default] " read answer if [ "x$answer" = "x" ] then answer="$default" fi if [ "x$answer" = xnone ] then answer= fi default= } ############################################################################## echo "EasySQL configuration" echo "~~~~~~~~~~~~~~~~~~~~~" # Help # if [ "x$1" = "x-h" -o "x$1" = "x--help" ] then echo "Usage: configure" exit 1 fi # Making Config # sed 's@%PWD%@'`pwd`@g Config.subst > Config # Configuring drivers # default='Y/n' ask 'Would you like to configure drivers' if [ "x$answer" = "xy" -o "x$answer" = "Y" -o "x$answer" = "xY/n" ] then cd drivers ./configure cd .. fi # Issuing make # MAKE=make eval `grep '^MAKE' Config.subst | sed 's/[ ]//g'` exec $MAKE