+ check for yp_*() functions

This commit is contained in:
eknauel 2003-11-25 22:07:38 +00:00
parent b11dc32afa
commit 073edccf69
2 changed files with 29 additions and 24 deletions

View File

@ -1,15 +1 @@
SUBDIRS= c
scheme/load-yp.scm:
(echo '(user)'; \
echo "(open 'dynamic-externals)"; \
echo "(open 'external-calls)"; \
echo '(run '; \
echo " '(let ((initializer-name \"scsh_yp_main\")"; \
echo ' (module-file "$(prefix)/lib/libscshyp.so"))'; \
echo ' (dynamic-load module-file)'; \
echo ' (call-external (get-external initializer-name))))'; \
echo '(config)'; \
echo '(load "yp-interfaces.scm")'; \
echo '(load "yp-packages.scm")'; \
) > $@
SUBDIRS= c scheme

View File

@ -2,12 +2,7 @@ AC_INIT(scsh-yp,1.0)
AC_CONFIG_SRCDIR(configure.in)
AM_INIT_AUTOMAKE
dnl AM_MAINTAINER_MODE
AC_LIBTOOL_DLOPEN
AC_PROG_LIBTOOL
AC_LIB_LTDL
AC_PROG_CC
AC_ARG_WITH(scsh-includes,
@ -24,10 +19,34 @@ AC_ARG_WITH(scsh-libraries,
scsh_libraries=/usr/local/lib/scsh)
AC_SUBST(scsh_libraries)
AC_CHECK_FUNCS(yp_get_default_domain yp_bind yp_unbind)
AC_CHECK_FUNCS(yperr_string ypprot_err)
AC_CHECK_FUNCS(yp_match yp_order)
AC_CHECK_FUNCS(yp_master yp_first yp_next)
define([PREPEND], [[$2]="$[$2] [$1]"])
missing_yp_funs = ""
AC_CHECK_FUNC(yp_get_default_domain,
[], PREPEND(yp_get_default_domain, missing_yp_funs))
AC_CHECK_FUNC(yp_bind,
[], PREPEND(yp_bind, missing_yp_funs))
AC_CHECK_FUNC(yp_unbind,
[], PREPEND(yp_unbind, missing_yp_funs))
AC_CHECK_FUNC(yperr_string,
[], PREPEND(yperr_string, missing_yp_funs))
AC_CHECK_FUNC(ypprot_err,
[], PREPEND(ypprot_err, missing_yp_funs))
AC_CHECK_FUNC(yp_match,
[], PREPEND(yp_match, missing_yp_funs))
AC_CHECK_FUNC(yp_order,
[], PREPEND(yp_order, missing_yp_funs))
AC_CHECK_FUNC(yp_master,
[], PREPEND(yp_master, missing_yp_funs))
AC_CHECK_FUNC(yp_first,
[], PREPEND(yp_first, missing_yp_funs))
AC_CHECK_FUNC(yp_next,
[], PREPEND(yp_next, missing_yp_funs))
if test "$missing_yp_funs" != ""; then
AC_MSG_FAILURE([The following yp functions calls could not be found: $missing_yp_funs])
fi
AC_SUBST(LIBS)
AC_SUBST(CC)