123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- AC_DEFUN([AM_PATH_LISPDIR],
- [AC_PREREQ([2.60])dnl
-
-
- test x"$EMACS" = xt && EMACS=
- AC_CHECK_PROGS([EMACS], [emacs xemacs], [no])
- AC_ARG_VAR([EMACS], [the Emacs editor command])
- AC_ARG_VAR([EMACSLOADPATH], [the Emacs library search path])
- AC_ARG_WITH([lispdir],
- [AS_HELP_STRING([--with-lispdir],
- [override the default lisp directory])],
- [ lispdir="$withval"
- AC_MSG_CHECKING([where .elc files should go])
- AC_MSG_RESULT([$lispdir])],
- [
- AC_CACHE_CHECK([where .elc files should go], [am_cv_lispdir], [
- if test $EMACS != "no"; then
- if test x${lispdir+set} != xset; then
-
-
-
-
-
- AC_RUN_LOG([$EMACS -batch -Q -eval '(while load-path (princ (concat (car load-path) "\n")) (setq load-path (cdr load-path)))' </dev/null >conftest.out])
- am_cv_lispdir=`sed -n \
- -e 's,/$,,' \
- -e '/.*\/lib\/x*emacs\/site-lisp$/{s,.*/lib/\(x*emacs/site-lisp\)$,${libdir}/\1,;p;q;}' \
- -e '/.*\/share\/x*emacs\/site-lisp$/{s,.*/share/\(x*emacs/site-lisp\),${datarootdir}/\1,;p;q;}' \
- conftest.out`
- rm conftest.out
- fi
- fi
- test -z "$am_cv_lispdir" && am_cv_lispdir='${datadir}/emacs/site-lisp'
- ])
- lispdir="$am_cv_lispdir"
- ])
- AC_SUBST([lispdir])
- ])
|