From: Ken Raeburn Date: Wed, 17 Aug 2005 01:46:59 +0000 (+0000) Subject: * env-setup.shin: Export $libdir. X-Git-Tag: ms-bug-test-20060525~173 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=24d1bca4a0bacd4a691b699b254e8b130872a565;p=krb5.git * env-setup.shin: Export $libdir. * init_db: Substitue __MODDIR__ with the fakedest module directory. * start_servers: Likewise. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@17336 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/kadmin/testing/scripts/ChangeLog b/src/kadmin/testing/scripts/ChangeLog index 6330c23a0..59a925093 100644 --- a/src/kadmin/testing/scripts/ChangeLog +++ b/src/kadmin/testing/scripts/ChangeLog @@ -1,3 +1,10 @@ +2005-08-16 Ken Raeburn + + * env-setup.shin: Export $libdir. + * init_db: Substitue __MODDIR__ with the fakedest module + directory. + * start_servers: Likewise. + 2004-09-30 Ken Raeburn * start_servers_local: If one of the servers failed to start, log diff --git a/src/kadmin/testing/scripts/env-setup.shin b/src/kadmin/testing/scripts/env-setup.shin index 0f790ac1c..03e6d065e 100644 --- a/src/kadmin/testing/scripts/env-setup.shin +++ b/src/kadmin/testing/scripts/env-setup.shin @@ -15,6 +15,10 @@ TOP=@RBUILD@/kadmin STOP=@S_TOP@/kadmin export TOP export STOP +# These two may be needed in case $libdir references them. +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ ; eval "libdir=$libdir"; export libdir # The shared library run time setup TOPLIBD=@RBUILD@/lib diff --git a/src/kadmin/testing/scripts/init_db b/src/kadmin/testing/scripts/init_db index bc7ac216e..5ebacc091 100644 --- a/src/kadmin/testing/scripts/init_db +++ b/src/kadmin/testing/scripts/init_db @@ -18,13 +18,28 @@ if [ "$STOP" = "" ]; then exit 1 fi +if [ "$libdir" = "" ]; then + echo "init_db: Environment variable \$libdir must point to library install directory" 1>&2 + exit 1 +fi + IROOT=$TOP/.. ADMIN=$TOP/dbutil BIN=$IROOT/bin ETC=$IROOT/etc +MODDIR=$TOP/../util/fakedest$libdir/db-modules SBIN=$TOP/keytab:$TOP/server DUMMY=${REALM=SECURE-TEST.OV.COM}; export REALM +if [ ! -d $MODDIR ]; then + echo "+++" 1>&2 + echo "+++ Error! $MODDIR does not exist!" 1>&2 + echo "+++ The MODDIR variable should point to the directory in which" 1>&2 + echo "+++ database modules have been installed for testing." 1>&2 + echo "+++" 1>&2 + exit 1 +fi + DUMMY=${TESTDIR=$TOP/testing}; export TESTDIR DUMMY=${STESTDIR=$STOP/testing} DUMMY=${SRVTCL=$TESTDIR/util/ovsec_kadm_srv_tcl}; export SRVTCL @@ -67,6 +82,7 @@ qualname=`$QUALNAME` sed -e "s/__REALM__/$REALM/g" -e "s#__K5ROOT__#$K5ROOT#g" \ -e "s/__KDCHOST__/$qualname/g" \ -e "s/__LOCALHOST__/$qualname/g" \ + -e "s#__MODDIR__#$MODDIR#g" \ < $STESTDIR/proto/krb5.conf.proto > $K5ROOT/krb5.conf sed -e "s/__REALM__/$REALM/g" -e "s#__K5ROOT__#$K5ROOT#g" \ < $STESTDIR/proto/kdc.conf.proto > $K5ROOT/kdc.conf diff --git a/src/kadmin/testing/scripts/start_servers b/src/kadmin/testing/scripts/start_servers index d38a42f52..b59d97b91 100644 --- a/src/kadmin/testing/scripts/start_servers +++ b/src/kadmin/testing/scripts/start_servers @@ -41,6 +41,7 @@ if [ $local = 0 ]; then sed -e "s/__REALM__/$REALM/g" -e "s#__K5ROOT__#$K5ROOT#g" \ -e "s/__KDCHOST__/$hostname/g" \ -e "s/__LOCALHOST__/$localname/g" \ + -e "s#__MODDIR__#$TOP/../util/fakedest$libdir/db-modules#g"\ < $STESTDIR/proto/krb5.conf.proto > $K5ROOT/krb5.conf # Using /usr/ucb/rsh and getting rid of "-k $REALM" until we get