Commit 624780f0 authored by Glenn Morris's avatar Glenn Morris
Browse files

Preload leim-list.el

* Makefile.in (abs_builddir): New, set by configure.
(buildlisppath): Add leim/.
(epaths-force-w32): Set BLD.

* lisp/loadup.el: Load leim-list.el when found.

* lisp/startup.el (normal-top-level): Skip re-loading leim/leim-list.el.

* nt/epaths.nt (PATH_DUMPLOADSEARCH): Add leim/.

* src/callproc.c (init_callproc): Don't assume PATH_DUMPLOADSEARCH
is a single directory.

* src/epaths.in (PATH_DUMPLOADSEARCH): Add leim/.

Fixes: debbugs:4789
parent 3f73284a
2013-11-26 Glenn Morris <rgm@gnu.org>
Preload leim-list.el.
* Makefile.in (abs_builddir): New, set by configure.
(buildlisppath): Add leim/.
(epaths-force-w32): Set BLD.
2013-11-21 Paul Eggert <eggert@cs.ucla.edu> 2013-11-21 Paul Eggert <eggert@cs.ucla.edu>
Fix some dependency problems that cause unnecessary recompiles. Fix some dependency problems that cause unnecessary recompiles.
......
...@@ -164,6 +164,7 @@ bitmapdir=@bitmapdir@ ...@@ -164,6 +164,7 @@ bitmapdir=@bitmapdir@
# We use $(srcdir) explicitly in dependencies so as not to depend on VPATH. # We use $(srcdir) explicitly in dependencies so as not to depend on VPATH.
srcdir=@srcdir@ srcdir=@srcdir@
abs_srcdir=@abs_srcdir@ abs_srcdir=@abs_srcdir@
abs_builddir=@abs_builddir@
# MinGW CPPFLAGS may use this. # MinGW CPPFLAGS may use this.
abs_top_srcdir=@abs_top_srcdir@ abs_top_srcdir=@abs_top_srcdir@
...@@ -213,13 +214,16 @@ locallisppath=@locallisppath@ ...@@ -213,13 +214,16 @@ locallisppath=@locallisppath@
# The default is ${locallisppath}:${standardlisppath}. # The default is ${locallisppath}:${standardlisppath}.
lisppath=@lisppath@ lisppath=@lisppath@
# Where Emacs will search for its lisp files while # Where Emacs will search for its lisp files while building.
# building. This is only used during the process of # This is only used during the process of compiling Emacs,
# compiling Emacs, to help Emacs find its lisp files # to help Emacs find its lisp files before they've been installed
# before they've been installed in their final location. # in their final location.
# This should be a colon-separated list of directories. # This should be a colon-separated list of directories.
# Normally it points to the lisp/ directory in the sources. # Normally it points to the lisp/ directory in the sources and
buildlisppath=${abs_srcdir}/lisp # the leim/ directory in the build tree.
# NB lread.c relies on lisp/ being first here.
# TODO generate leim in srcdir also, prebuild in tarfiles.
buildlisppath=${abs_srcdir}/lisp:${abs_builddir}/leim
# Where to install the other architecture-independent # Where to install the other architecture-independent
# data files distributed with Emacs (like the tutorial, # data files distributed with Emacs (like the tutorial,
...@@ -337,6 +341,7 @@ msys_sed_sh_escape=sed -e 's/[];$$*.^[]/\\\\&/g' ...@@ -337,6 +341,7 @@ msys_sed_sh_escape=sed -e 's/[];$$*.^[]/\\\\&/g'
# '/foo/bar'). # '/foo/bar').
epaths-force-w32: FRC epaths-force-w32: FRC
@(w32srcdir=`${srcdir}/build-aux/msys-to-w32 "${srcdir}"`; \ @(w32srcdir=`${srcdir}/build-aux/msys-to-w32 "${srcdir}"`; \
w32blddir=`${srcdir}/build-aux/msys-to-w32 .`; \
w32prefix=`${srcdir}/build-aux/msys-to-w32 "${prefix}" N`; \ w32prefix=`${srcdir}/build-aux/msys-to-w32 "${prefix}" N`; \
w32prefixpattern=`echo "${w32prefix}" | ${msys_sed_sh_escape}` ; \ w32prefixpattern=`echo "${w32prefix}" | ${msys_sed_sh_escape}` ; \
w32locallisppath=`${srcdir}/build-aux/msys-to-w32 "${locallisppath}" N ":" "\\;" | ${msys_w32prefix_subst}` ; \ w32locallisppath=`${srcdir}/build-aux/msys-to-w32 "${locallisppath}" N ":" "\\;" | ${msys_w32prefix_subst}` ; \
...@@ -344,6 +349,7 @@ epaths-force-w32: FRC ...@@ -344,6 +349,7 @@ epaths-force-w32: FRC
-e 's;\(#.*PATH_SITELOADSEARCH\).*$$;\1 "'"$${w32locallisppath}"'";' \ -e 's;\(#.*PATH_SITELOADSEARCH\).*$$;\1 "'"$${w32locallisppath}"'";' \
-e '/^.*#/s/@VER@/${version}/g' \ -e '/^.*#/s/@VER@/${version}/g' \
-e '/^.*#/s/@CFG@/${configuration}/g' \ -e '/^.*#/s/@CFG@/${configuration}/g' \
-e '/^.*#/s|@BLD@|$${w32blddir}|g' \
-e "/^.*#/s|@SRC@|$${w32srcdir}|g") && \ -e "/^.*#/s|@SRC@|$${w32srcdir}|g") && \
${srcdir}/build-aux/move-if-change epaths.h.$$$$ src/epaths.h ${srcdir}/build-aux/move-if-change epaths.h.$$$$ src/epaths.h
......
2013-11-26 Glenn Morris <rgm@gnu.org>
Preload leim-list.el. (Bug#4789)
* loadup.el: Load leim-list.el when found.
* startup.el (normal-top-level): Skip re-loading leim/leim-list.el.
2013-11-25 Bozhidar Batsov <bozhidar@batsov.com> 2013-11-25 Bozhidar Batsov <bozhidar@batsov.com>
* emacs-lisp/bytecomp.el (byte-compile-form): Fix a typo. * emacs-lisp/bytecomp.el (byte-compile-form): Fix a typo.
......
;;; loadup.el --- load up standardly loaded Lisp files for Emacs ;;; loadup.el --- load up standardly loaded Lisp files for Emacs
;; Copyright (C) 1985-1986, 1992, 1994, 2001-2013 Free Software ;; Copyright (C) 1985-1986, 1992, 1994, 2001-2013
;; Foundation, Inc. ;; Free Software Foundation, Inc.
;; Maintainer: FSF ;; Maintainer: FSF
;; Keywords: internal ;; Keywords: internal
...@@ -98,6 +98,8 @@ ...@@ -98,6 +98,8 @@
(load "env") (load "env")
(load "format") (load "format")
(load "bindings") (load "bindings")
;; This sets temporary-file-directory, used by eg
;; auto-save-file-name-transforms in files.el.
(load "cus-start") (load "cus-start")
(load "window") ; Needed here for `replace-buffer-in-windows'. (load "window") ; Needed here for `replace-buffer-in-windows'.
(setq load-source-file-function 'load-with-code-conversion) (setq load-source-file-function 'load-with-code-conversion)
...@@ -278,12 +280,16 @@ ...@@ -278,12 +280,16 @@
(load "vc/ediff-hook") (load "vc/ediff-hook")
(if (not (eq system-type 'ms-dos)) (load "tooltip")) (if (not (eq system-type 'ms-dos)) (load "tooltip"))
;If you want additional libraries to be preloaded and their ;; This file doesn't exist when building a development version of Emacs
;doc strings kept in the DOC file rather than in core, ;; from the repository. It is generated just after temacs is built.
;you may load them with a "site-load.el" file. (load "leim-list.el" t)
;But you must also cause them to be scanned when the DOC file
;is generated. ;; If you want additional libraries to be preloaded and their
;For other systems, you must edit ../src/Makefile.in. ;; doc strings kept in the DOC file rather than in core,
;; you may load them with a "site-load.el" file.
;; But you must also cause them to be scanned when the DOC file
;; is generated.
;; For other systems, you must edit ../src/Makefile.in.
(load "site-load" t) (load "site-load" t)
;; Make sure default-directory is unibyte when dumping. This is ;; Make sure default-directory is unibyte when dumping. This is
......
...@@ -499,18 +499,23 @@ It is the default value of the variable `top-level'." ...@@ -499,18 +499,23 @@ It is the default value of the variable `top-level'."
;; available input methods. ;; available input methods.
(let ((tail load-path) (let ((tail load-path)
(lispdir (expand-file-name "../lisp" data-directory)) (lispdir (expand-file-name "../lisp" data-directory))
;; For out-of-tree builds, leim-list is generated in the build dir. ;; For out-of-tree builds, leim-list is generated in the build dir.
;;; (leimdir (expand-file-name "../leim" doc-directory)) (leimdir (expand-file-name "../leim" doc-directory))
dir) dir)
(while tail (while tail
(setq dir (car tail)) (setq dir (car tail))
(let ((default-directory dir)) (let ((default-directory dir))
(load (expand-file-name "subdirs.el") t t t)) (load (expand-file-name "subdirs.el") t t t))
;; Do not scan standard directories that won't contain a leim-list.el. ;; Do not scan standard directories that won't contain a leim-list.el.
;; http://lists.gnu.org/archive/html/emacs-devel/2009-10/msg00502.html ;; http://lists.gnu.org/archive/html/emacs-devel/2009-10/msg00502.html
(or (string-match (concat "\\`" lispdir) dir) ;; Also skip leim/leim-list.el, since we preloaded that one.
(let ((default-directory dir)) (or (string-prefix-p lispdir dir)
(load (expand-file-name "leim-list.el") t t t))) ;; Not supposed to be subdirs.el in leim, but someone
;; might have added one and be keeping their own leim-list
;; files in subdirs of leim.
(string-equal leimdir dir)
(let ((default-directory dir))
(load (expand-file-name "leim-list.el") t t t)))
;; We don't use a dolist loop and we put this "setq-cdr" command at ;; We don't use a dolist loop and we put this "setq-cdr" command at
;; the end, because the subdirs.el files may add elements to the end ;; the end, because the subdirs.el files may add elements to the end
;; of load-path and we want to take it into account. ;; of load-path and we want to take it into account.
......
2013-11-26 Glenn Morris <rgm@gnu.org>
* epaths.nt (PATH_DUMPLOADSEARCH): Add leim/.
2013-11-12 Dani Moncayo <dmoncayo@gmail.com> 2013-11-12 Dani Moncayo <dmoncayo@gmail.com>
* msysconfig.sh: Remove. * msysconfig.sh: Remove.
......
...@@ -12,8 +12,7 @@ ...@@ -12,8 +12,7 @@
the host system (e.g., i686-pc-mingw32), and @SRC@ by the root of the host system (e.g., i686-pc-mingw32), and @SRC@ by the root of
the Emacs source tree used to build Emacs. */ the Emacs source tree used to build Emacs. */
/* /*
Copyright (C) 1993, 1995, 1997, 1999, 2001-2013 Free Software Copyright (C) 1993, 1995, 1997, 1999, 2001-2013 Free Software Foundation, Inc.
Foundation, Inc.
This file is part of GNU Emacs. This file is part of GNU Emacs.
...@@ -51,10 +50,11 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ ...@@ -51,10 +50,11 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
#define PATH_SITELOADSEARCH "%emacs_dir%/share/emacs/@VER@/site-lisp;%emacs_dir%/share/emacs/site-lisp" #define PATH_SITELOADSEARCH "%emacs_dir%/share/emacs/@VER@/site-lisp;%emacs_dir%/share/emacs/site-lisp"
/* Like PATH_LOADSEARCH, but used only during the build process /* Like PATH_LOADSEARCH, but used only during the build process
when Emacs is dumping. Configure (using "make epaths-force") sets when Emacs is dumping. Configure (using "make epaths-force-w32") sets
this to $buildlisppath, which normally has the value: <srcdir>/lisp. this to $buildlisppath, which normally has the value:
<srcdir>/lisp;<builddir>/leim.
*/ */
#define PATH_DUMPLOADSEARCH "@SRC@/lisp" #define PATH_DUMPLOADSEARCH "@SRC@/lisp;@BLD@/leim"
/* The extra search path for programs to invoke. This is appended to /* The extra search path for programs to invoke. This is appended to
whatever the PATH environment variable says to set the Lisp whatever the PATH environment variable says to set the Lisp
......
2013-11-26 Glenn Morris <rgm@gnu.org>
Preload leim-list.el.
* epaths.in (PATH_DUMPLOADSEARCH): Add leim/.
* callproc.c (init_callproc): Don't assume PATH_DUMPLOADSEARCH
is a single directory.
2013-11-25 Paul Eggert <eggert@cs.ucla.edu> 2013-11-25 Paul Eggert <eggert@cs.ucla.edu>
bool-vector-subsetp is now the normal direction (Bug#15912). bool-vector-subsetp is now the normal direction (Bug#15912).
......
...@@ -1607,16 +1607,16 @@ init_callproc (void) ...@@ -1607,16 +1607,16 @@ init_callproc (void)
if (data_dir == 0) if (data_dir == 0)
{ {
Lisp_Object tem, tem1, srcdir; Lisp_Object tem, tem1, srcdir;
Lisp_Object lispdir = Fcar (decode_env_path (0, PATH_DUMPLOADSEARCH, 0));
srcdir = Fexpand_file_name (build_string ("../src/"), lispdir);
srcdir = Fexpand_file_name (build_string ("../src/"),
build_unibyte_string (PATH_DUMPLOADSEARCH));
tem = Fexpand_file_name (build_string ("GNU"), Vdata_directory); tem = Fexpand_file_name (build_string ("GNU"), Vdata_directory);
tem1 = Ffile_exists_p (tem); tem1 = Ffile_exists_p (tem);
if (!NILP (Fequal (srcdir, Vinvocation_directory)) || NILP (tem1)) if (!NILP (Fequal (srcdir, Vinvocation_directory)) || NILP (tem1))
{ {
Lisp_Object newdir; Lisp_Object newdir;
newdir = Fexpand_file_name (build_string ("../etc/"), newdir = Fexpand_file_name (build_string ("../etc/"), lispdir);
build_unibyte_string (PATH_DUMPLOADSEARCH));
tem = Fexpand_file_name (build_string ("GNU"), newdir); tem = Fexpand_file_name (build_string ("GNU"), newdir);
tem1 = Ffile_exists_p (tem); tem1 = Ffile_exists_p (tem);
if (!NILP (tem1)) if (!NILP (tem1))
......
/* Hey Emacs, this is -*- C -*- code! */ /* Hey Emacs, this is -*- C -*- code! */
/* /*
Copyright (C) 1993, 1995, 1997, 1999, 2001-2013 Free Software Copyright (C) 1993, 1995, 1997, 1999, 2001-2013 Free Software Foundation, Inc.
Foundation, Inc.
This file is part of GNU Emacs. This file is part of GNU Emacs.
...@@ -42,9 +41,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ ...@@ -42,9 +41,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Like PATH_LOADSEARCH, but used only during the build process /* Like PATH_LOADSEARCH, but used only during the build process
when Emacs is dumping. Configure (using "make epaths-force") sets when Emacs is dumping. Configure (using "make epaths-force") sets
this to $buildlisppath, which normally has the value: <srcdir>/lisp. this to $buildlisppath, which normally has the value:
<srcdir>/lisp:<builddir>/leim.
*/ */
#define PATH_DUMPLOADSEARCH "../lisp" #define PATH_DUMPLOADSEARCH "../lisp:../leim"
/* The extra search path for programs to invoke. This is appended to /* The extra search path for programs to invoke. This is appended to
whatever the PATH environment variable says to set the Lisp whatever the PATH environment variable says to set the Lisp
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment