summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorAkim Demaille <akim@epita.fr>2001-09-28 11:56:26 +0000
committerAkim Demaille <akim@epita.fr>2001-09-28 11:56:26 +0000
commite16f9eefe02966c5410c71cb6a9fa771bb95a914 (patch)
tree4fd68126a464f4b2f03391aaa9b5d6093139a1b2 /m4
parentf656cde7349a15a27077efb53c2c890351bdec8b (diff)
downloadautoconf-e16f9eefe02966c5410c71cb6a9fa771bb95a914.tar.gz
* lib/emacs/autoconf-mode.el, lib/emacs/autotest-mode.el: New.
* configure.ac: Adjust.
Diffstat (limited to 'm4')
-rw-r--r--m4/Makefile.am1
-rw-r--r--m4/Makefile.in1
-rw-r--r--m4/lispdir.m449
3 files changed, 51 insertions, 0 deletions
diff --git a/m4/Makefile.am b/m4/Makefile.am
index 8fb55c61..5a7b2065 100644
--- a/m4/Makefile.am
+++ b/m4/Makefile.am
@@ -25,6 +25,7 @@ depend.m4 \
init.m4 \
install-sh.m4 \
m4.m4 \
+lispdir.m4 \
missing.m4 \
sanity.m4 \
strip.m4
diff --git a/m4/Makefile.in b/m4/Makefile.in
index 6ba27387..d16512f6 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -70,6 +70,7 @@ depend.m4 \
init.m4 \
install-sh.m4 \
m4.m4 \
+lispdir.m4 \
missing.m4 \
sanity.m4 \
strip.m4
diff --git a/m4/lispdir.m4 b/m4/lispdir.m4
new file mode 100644
index 00000000..9022b802
--- /dev/null
+++ b/m4/lispdir.m4
@@ -0,0 +1,49 @@
+## ------------------------
+## Emacs LISP file handling
+## From Ulrich Drepper
+## Almost entirely rewritten by Alexandre Oliva
+## ------------------------
+
+# Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 3
+
+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)])