Here's another round, making path searching Even Smarter (tm).
Steve, this should make your installation layout work.
It also contains a patch of x-menubar.el which I sent earlier but
didn't make it into Pygmy-pre2 but does have a ChangeLog entry there.
ChangeLog
1998-04-25 Michael Sperber [Mr. Preprocessor] <sperber(a)informatik.uni-tuebingen.de>
* configure.in: Sychronized ..._USER_DEFINED variables with
datadir setting.
* Makefile.in (mkdir): No longer create sitelispdir.
src/ChangeLog
1998-04-25 Michael Sperber [Mr. Preprocessor] <sperber(a)informatik.uni-tuebingen.de>
* emacs.c (complex_vars_of_emacs): Typo fixes.
* emacs.c: Added configure-exec-prefix-directory.
* paths.h.in: Added PATH_EXEC_PREFIX.
lisp/ChangeLog
1998-04-25 Michael Sperber [Mr. Preprocessor] <sperber(a)informatik.uni-tuebingen.de>
* setup-paths.el, find-paths.el: Removed uses of `not' which
temacs doesn't have.
* find-paths.el (paths-find-emacs-roots): Included exec-prefix
into root searching.
Index: Makefile.in
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/Makefile.in,v
retrieving revision 1.52
diff -u -r1.52 Makefile.in
--- Makefile.in 1998/04/18 07:31:35 1.52
+++ Makefile.in 1998/04/25 22:14:11
@@ -453,7 +453,7 @@
## make-path instead of mkdir. Not all mkdirs have the `-p' flag.
mkdir: FRC.mkdir
${MAKEPATH} ${COPYDESTS} ${lockdir} ${infodir} ${archlibdir} \
- ${mandir} ${bindir} ${datadir} ${libdir} ${sitelispdir} ${pkgdir}
+ ${mandir} ${bindir} ${datadir} ${libdir} ${pkgdir}
-chmod 0777 ${lockdir}
## Delete all the installed files that the `install' target would
Index: configure.in
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/configure.in,v
retrieving revision 1.92
diff -u -r1.92 configure.in
--- configure.in 1998/04/24 21:33:57 1.92
+++ configure.in 1998/04/25 22:14:43
@@ -269,6 +269,8 @@
dnl and all the variables that are supposed to be based on exec_prefix
dnl by default will actually change.
dnl Use braces instead of parens because sh, perl, etc. also accept them.
+dnl If you change these, you need to synchronize with the settings of the
+dnl various ..._USER_DEFINED variables further down.
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
@@ -692,18 +694,19 @@
fi
eval "$opt=\"$val\""
- dnl Changing exec_prefix or libdir will change the default value
- dnl of archlibdir. Changing datadir will change the default value
- dnl of etcdir and lispdir. Changing statedir will change the
- dnl default value of lockdir.
- case "$opt" in
+ dnl You need to synchronize this with the way the
+ dnl default values are built.
+ case "$opt" in
lispdir ) AC_DEFINE(LISPDIR_USER_DEFINED) ;;
dnl sitelispdir ) AC_DEFINE(SITELISPDIR_USER_DEFINED) ;;
etcdir ) AC_DEFINE(ETCDIR_USER_DEFINED) ;;
infodir ) AC_DEFINE(INFODIR_USER_DEFINED) ;;
infopath ) AC_DEFINE(INFOPATH_USER_DEFINED) ;;
package_path ) AC_DEFINE(PACKAGE_PATH_USER_DEFINED) ;;
- datadir ) AC_DEFINE(ETCDIR_USER_DEFINED) ;;
+ datadir )
+ AC_DEFINE(INFODIR_USER_DEFINED)
+ AC_DEFINE(LISPDIR_USER_DEFINED)
+ AC_DEFINE(ETCDIR_USER_DEFINED) ;;
statedir | lockdir ) AC_DEFINE(LOCKDIR_USER_DEFINED) ;;
exec_prefix | libdir | archlibdir ) AC_DEFINE(ARCHLIBDIR_USER_DEFINED) ;;
esac
@@ -3539,8 +3542,8 @@
AC_SUBST(infodir)
AC_SUBST(INFODIR_USER_DEFINED)
-dnl Yo, Stephen Bourne! I want to marry you!
INFODIR=$infodir
+dnl Yo, Stephen Bourne! I want to marry you!
while true; do
case "$INFODIR" in
*\$* ) eval "INFODIR=$INFODIR" ;;
Index: lisp/find-paths.el
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/lisp/find-paths.el,v
retrieving revision 1.6
diff -u -r1.6 find-paths.el
--- find-paths.el 1998/04/18 07:31:47 1.6
+++ find-paths.el 1998/04/25 22:14:48
@@ -243,11 +243,11 @@
(append list-1
(reverse reverse-survivors))))
-(defun paths-delete (predicate list)
+(defun paths-filter (predicate list)
"Delete all matches of PREDICATE from LIST."
(let ((reverse-result '()))
(while list
- (if (not (funcall predicate (car list)))
+ (if (funcall predicate (car list))
(setq reverse-result (cons (car list) reverse-result)))
(setq list (cdr list)))
(nreverse reverse-result)))
@@ -265,24 +265,30 @@
(file-name-as-directory component)))
components)))
(if drop-empties
- (paths-delete #'(lambda (component)
- (string-equal "" component))
+ (paths-filter #'(lambda (component)
+ (null (string-equal "" component)))
directories)
directories)))
(defun paths-find-emacs-roots (invocation-directory
invocation-name)
"Find all plausible installation roots for XEmacs."
- (let ((invocation-root
- (paths-find-emacs-root invocation-directory invocation-name))
- (installation-root
- (and configure-prefix-directory
- (file-directory-p configure-prefix-directory)
- (file-name-as-directory configure-prefix-directory))))
- (append (and invocation-root
- (list invocation-root))
- (and installation-root
- (paths-emacs-root-p installation-root)
- (list installation-root)))))
+ (let* ((potential-invocation-root
+ (paths-find-emacs-root invocation-directory invocation-name))
+ (invocation-roots
+ (and potential-invocation-root
+ (list potential-invocation-root)))
+ (potential-installation-roots
+ (paths-uniq-append
+ (and configure-exec-prefix-directory
+ (list (file-name-as-directory
+ configure-exec-prefix-directory)))
+ (and configure-prefix-directory
+ (list (file-name-as-directory
+ configure-prefix-directory)))))
+ (installation-roots
+ (paths-filter #'paths-emacs-root-p potential-installation-roots)))
+ (paths-uniq-append invocation-roots
+ installation-roots)))
;;; find-paths.el ends here
Index: lisp/setup-paths.el
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/lisp/setup-paths.el,v
retrieving revision 1.10
diff -u -r1.10 setup-paths.el
--- setup-paths.el 1998/04/24 21:34:05 1.10
+++ setup-paths.el 1998/04/25 22:14:48
@@ -98,7 +98,7 @@
(packages-find-package-info-path last-packages)
(and info-path-envval
(paths-decode-directory-path info-path-envval 'drop-empties)))
- (and (not info-path-envval)
+ (and (null info-path-envval)
(paths-uniq-append
(paths-directories-which-exist configure-info-path)
(paths-directories-which-exist paths-default-info-directories))))))
Index: lisp/x-menubar.el
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/lisp/x-menubar.el,v
retrieving revision 1.19
diff -u -r1.19 x-menubar.el
--- x-menubar.el 1998/04/24 21:34:07 1.19
+++ x-menubar.el 1998/04/25 22:14:58
@@ -570,7 +570,8 @@
(customize-set-variable 'font-menu-this-frame-only-p
(not font-menu-this-frame-only-p))
:style toggle
- :selected font-menu-this-frame-only-p]
+ :selected (and (boundp 'font-menu-this-frame-only-p)
+ font-menu-this-frame-only-p)]
,@(if (featurep 'scrollbar)
'(["Scrollbars"
(customize-set-variable 'scrollbars-visible-p
Index: src/emacs.c
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/src/emacs.c,v
retrieving revision 1.68
diff -u -r1.68 emacs.c
--- emacs.c 1998/04/24 21:34:17 1.68
+++ emacs.c 1998/04/25 22:15:22
@@ -145,7 +145,7 @@
Lisp_Object Vinternal_error_checking;
/* The default base directory XEmacs is installed under. */
-Lisp_Object Vconfigure_prefix_directory;
+Lisp_Object Vconfigure_exec_prefix_directory, Vconfigure_prefix_directory;
/* If nonzero, set XEmacs to run at this priority. This is also used
in child_setup and sys_suspend to make sure subshells run at normal
@@ -2810,7 +2810,7 @@
DEFVAR_LISP ("configure-package-path", &Vconfigure_package_path /*
For internal use by the build procedure only.
-configure's idea of what PACKAGE-DIRECTORY will be.
+configure's idea of what the package path will be.
*/ );
#ifdef PATH_PACKAGEPATH
Vconfigure_package_path = decode_path (PATH_PACKAGEPATH);
@@ -2887,6 +2887,17 @@
(build_string ((char *) PATH_DOC));
#else
Vconfigure_doc_directory = Qnil;
+#endif
+
+ DEFVAR_LISP ("configure-exec-prefix-directory", &Vconfigure_exec_prefix_directory /*
+For internal use by the build procedure only.
+configure's idea of what EXEC-PREFIX-DIRECTORY will be.
+*/ );
+#ifdef PATH_EXEC_PREFIX
+ Vconfigure_exec_prefix_directory = Ffile_name_as_directory
+ (build_string ((char *) PATH_EXEC_PREFIX));
+#else
+ Vconfigure_exec_prefix_directory = Qnil;
#endif
DEFVAR_LISP ("configure-prefix-directory", &Vconfigure_prefix_directory /*
Index: src/paths.h.in
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs-20/src/paths.h.in,v
retrieving revision 1.5
diff -u -r1.5 paths.h.in
--- paths.h.in 1998/04/14 07:04:38 1.5
+++ paths.h.in 1998/04/25 22:15:23
@@ -24,8 +24,9 @@
If it defines anything, this file should define some subset of the following:
- PATH_PREFIX The default value of `prefix-directory'. This is the
- default root for everything.
+ PATH_EXEC_PREFIX The value of --exec-prefix.
+
+ PATH_PREFIX The value of --prefix.
PATH_LOADSEARCH The default value of `load-path'.
@@ -51,6 +52,8 @@
PATH_INFOPATH The default value of `Info-directory-list'.
These are additional places info files are searched
for. */
+
+#define PATH_EXEC_PREFIX "@exec_prefix@"
#define PATH_PREFIX "@prefix@"
--
Cheers =8-} Chipsy
Friede, Völkerverständigung und überhaupt blabla