1 AC_DEFUN(AC_DEFINE_GNUS_PRODUCT_NAME,
2 [dnl Defining gnus product name.
5 AC_DEFUN(AC_CHECK_EMACS,
6 [dnl Check for Emacsen.
8 dnl Apparently, if you run a shell window in Emacs, it sets the EMACS
9 dnl environment variable to 't'. Lets undo the damage.
10 test x$EMACS = xt && EMACS=
13 [ --with-emacs=EMACS compile with EMACS [EMACS=emacs, mule...]],
14 [if test x$withval = xyes -o x$withval = x; then
15 AC_CHECK_PROGS(EMACS, emacs xemacs mule, emacs)
17 AC_CHECK_PROG(EMACS, $withval, $withval, emacs)
20 [ --with-xemacs=XEMACS compile with XEMACS [XEMACS=xemacs]],
21 [if test x$withval = xyes -o x$withval = x; then
22 AC_CHECK_PROG(XEMACS, xemacs, xemacs, xemacs)
24 AC_CHECK_PROG(XEMACS, $withval, $withval, xemacs)
29 AC_CHECK_PROGS(EMACS, emacs xemacs mule, emacs)])
33 AC_DEFUN(AC_PATH_LISPDIR,
34 [dnl Check for LISPDIR.
35 AC_MSG_CHECKING([where lisp files should go])
37 [ --with-lispdir=DIR Where to install lisp files
38 (for XEmacs package, use --with-packagedir instead)],
40 [emacsdir=$datadir/emacs
41 test x$prefix = xNONE && prefix=$ac_default_prefix
42 case `echo x$EMACS | sed -e 's/x//' -e 's/^.*\///'` in
44 if test -d $prefix/share/emacs; then
45 emacsdir=$prefix/share/emacs
46 elif test -d $prefix/lib/emacs; then
47 emacsdir=$prefix/lib/emacs
50 if test -d $prefix/lib/xemacs; then
51 emacsdir=$prefix/lib/xemacs
52 elif test -d $prefix/share/xemacs; then
53 emacsdir=$prefix/share/xemacs
56 if test -d $prefix/share/mule; then
57 emacsdir=$prefix/share/mule
58 elif test -d $prefix/lib/mule; then
59 emacsdir=$prefix/lib/mule
60 elif test -d $prefix/share/emacs; then
61 emacsdir=$prefix/share/emacs
62 elif test -d $prefix/lib/emacs; then
63 emacsdir=$prefix/lib/emacs
66 lispdir=$emacsdir/site-lisp/$GNUS_PRODUCT_NAME])
67 AC_MSG_RESULT([$lispdir
68 (it will be ignored when \"make install-package[[-ja]]\" is done)])
71 AC_DEFUN(AC_PATH_PACKAGEDIR,
72 [dnl Check for PACKAGEDIR.
73 AC_ARG_WITH(packagedir,
74 [ --with-packagedir=DIR package DIR for XEmacs],
75 [if test x$withval != xyes -a x$withval != x; then
76 AC_MSG_CHECKING([where the package should go])
78 AC_MSG_RESULT($PACKAGEDIR)
81 AC_SUBST(PACKAGEDIR)])
83 AC_DEFUN(AC_ADD_LOAD_PATH,
84 [dnl Check for additional load path.
86 [ --with-addpath=PATH search Emacs-Lisp libraries with PATH
87 use colons to separate directory names],
88 [if test x$withval != xyes -a x$withval != x; then
89 AC_MSG_CHECKING([where to find the additional elisp libraries])
90 ADDITIONAL_LOAD_PATH=$withval
91 AC_MSG_RESULT($ADDITIONAL_LOAD_PATH)
93 ADDITIONAL_LOAD_PATH=)
94 AC_SUBST(ADDITIONAL_LOAD_PATH)])