From 71bdb6802f8781a51a537f16063802c320b86698 Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Thu, 29 Aug 2002 12:05:06 +0000 Subject: [PATCH] * aclocal.m4 (CHOOSE_ET, CHOOSE_SS): New macros. (CONFIG_RULES): Invoke them. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14794 dc483132-0cff-0310-8789-dd5450dbe970 --- src/ChangeLog | 5 +++++ src/aclocal.m4 | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index dcaecaa61..2ab0c63e0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2002-08-29 Ken Raeburn + + * aclocal.m4 (CHOOSE_ET, CHOOSE_SS): New macros. + (CONFIG_RULES): Invoke them. + 2002-08-26 Ezra Peisach * aclocal.m4 (KRB5_LIB_PARAMS): Substitute krb5_cv_host in diff --git a/src/aclocal.m4 b/src/aclocal.m4 index 9c6fc6d56..4855c2fb9 100644 --- a/src/aclocal.m4 +++ b/src/aclocal.m4 @@ -51,6 +51,8 @@ WITH_LINKER dnl WITH_LDOPTS dnl WITH_CPPOPTS dnl WITH_KRB4 dnl +CHOOSE_ET dnl +CHOOSE_SS dnl dnl allow stuff in tree to access deprecated/private stuff for now ADD_DEF([-DKRB5_PRIVATE=1]) dnl ifdef([AC_PROG_CC_STDC], [AC_PROG_CC_STDC]) @@ -1410,3 +1412,55 @@ do done done ]) +dnl +dnl +AC_DEFUN([CHOOSE_ET],[ +AC_ARG_WITH([system-com_err], +[ --with-system-com_err use system -lcom_err and compile_et]) +AC_MSG_CHECKING(which version of com_err to use) +if test "$with_system_com_err" = yes ; then + COM_ERR_VERSION=sys + AC_MSG_RESULT(system) +else + COM_ERR_VERSION=k5 + AC_MSG_RESULT(krb5) +fi +if test $COM_ERR_VERSION = sys; then + # check for various functions we need + AC_CHECK_LIB(com_err, add_error_table, :, AC_MSG_ERROR(cannot find add_error_table in com_err library)) + AC_CHECK_LIB(com_err, remove_error_table, :, AC_MSG_ERROR(cannot find remove_error_table in com_err library)) + # make sure compile_et provides "et_foo" name + cat >> conf$$e.et </dev/null 2>&1 ; then true ; else + AC_MSG_ERROR(execution failed) + fi + AC_TRY_COMPILE([#include "conf$$e.h" + ],[ et_foo_error_table; ],:, + [AC_MSG_ERROR(cannot use et_foo_error_table)]) + # Anything else we need to test for? + rm -f conf$$e.et conf$$e.c conf$$e.h + krb5_cv_compile_et_useful=yes + ]) +fi +AC_SUBST(COM_ERR_VERSION) +]) +AC_DEFUN([CHOOSE_SS],[ +AC_ARG_WITH([system-ss], +[ --with-system-ss use system -lss and mk_cmds]) +if test "$with_system_ss" = yes ; then + SS_VERSION=sys + # check for various libraries we might need +else + SS_VERSION=k5 +fi +AC_SUBST(SS_VERSION) +]) -- 2.26.2