From e119fbc6e7f4e5454e800900a9ad2dd10270b353 Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Mon, 29 Oct 2001 22:12:39 +0000 Subject: [PATCH] * m4/lispdir.m4 (AM_PATH_LISPDIR): Use AC_RUN_LOG to avoid cluttering configure's stdout. --- ChangeLog | 6 ++++++ m4/lispdir.m4 | 59 +++++++++++++++++++++++++++++---------------------- 2 files changed, 40 insertions(+), 25 deletions(-) diff --git a/ChangeLog b/ChangeLog index e880ad0c..8e78a17f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2001-10-29 Akim Demaille + + * m4/lispdir.m4 (AM_PATH_LISPDIR): Use AC_RUN_LOG to avoid + cluttering configure's stdout. + + 2001-10-28 Akim Demaille * automake.in: Various formatting changes. diff --git a/m4/lispdir.m4 b/m4/lispdir.m4 index 9022b802..2c534d99 100644 --- a/m4/lispdir.m4 +++ b/m4/lispdir.m4 @@ -1,4 +1,4 @@ -## ------------------------ +## ------------------------ -*- Autoconf -*- ## Emacs LISP file handling ## From Ulrich Drepper ## Almost entirely rewritten by Alexandre Oliva @@ -21,29 +21,38 @@ # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. -# serial 3 +# serial 4 +# AM_PATH_LISPDIR +# --------------- AC_DEFUN([AM_PATH_LISPDIR], - [AC_ARG_WITH(lispdir, - [ --with-lispdir Override the default lisp directory ], - [ lispdir="$withval" - AC_MSG_CHECKING([where .elc files should go]) - AC_MSG_RESULT([$lispdir])], - [ - # If set to t, that means we are running in a shell under Emacs. - # If you have an Emacs named "t", then use the full path. - test x"$EMACS" = xt && EMACS= - AC_CHECK_PROGS(EMACS, emacs xemacs, no) - if test $EMACS != "no"; then - if test x${lispdir+set} != xset; then - AC_CACHE_CHECK([where .elc files should go], [am_cv_lispdir], [dnl - am_cv_lispdir=`$EMACS -batch -q -eval '(while load-path (princ (concat (car load-path) "\n")) (setq load-path (cdr load-path)))' | sed -n -e 's,/$,,' -e '/.*\/lib\/\(x\?emacs\/site-lisp\)$/{s,,${libdir}/\1,;p;q;}' -e '/.*\/share\/\(x\?emacs\/site-lisp\)$/{s,,${datadir}/\1,;p;q;}'` - if test -z "$am_cv_lispdir"; then - am_cv_lispdir='${datadir}/emacs/site-lisp' - fi - ]) - lispdir="$am_cv_lispdir" - fi - fi - ]) - AC_SUBST(lispdir)]) +[AC_ARG_WITH(lispdir, + [ --with-lispdir Override the default lisp directory ], + [ lispdir="$withval" + AC_MSG_CHECKING([where .elc files should go]) + AC_MSG_RESULT([$lispdir])], + [ + # If set to t, that means we are running in a shell under Emacs. + # If you have an Emacs named "t", then use the full path. + test x"$EMACS" = xt && EMACS= + AC_CHECK_PROGS(EMACS, emacs xemacs, no) + if test $EMACS != "no"; then + if test x${lispdir+set} != xset; then + AC_CACHE_CHECK([where .elc files should go], [am_cv_lispdir], + [AC_RUN_LOG([$EMACS -batch -q -eval '(while load-path (princ (concat (car load-path) "\n")) (setq load-path (cdr load-path)))' >conftest.out]) + am_cv_lispdir=`sed -n \ + -e 's,/$,,' \ + -e '/.*\/lib\/\(x\?emacs\/site-lisp\)$/{s,,${libdir}/\1,;p;q;}' \ + -e '/.*\/share\/\(x\?emacs\/site-lisp\)$/{s,,${datadir}/\1,;p;q;}' \ + conftest.out` + rm conftest.out + if test -z "$am_cv_lispdir"; then + am_cv_lispdir='${datadir}/emacs/site-lisp' + fi + ]) + lispdir="$am_cv_lispdir" + fi + fi +]) +AC_SUBST(lispdir) +])# AM_PATH_LISPDIR -- 2.43.5