diff src/emacs.c @ 110967:188673195616

Rename `image-library-alist' to `dynamic-library-alist'. * etc/NEWS: Mention `dynamic-library-alist'. * lisp/image.el (image-library-alist): Declare as obsolete alias. (image-type-available-p): Use `dynamic-library-alist'. * lisp/term/w32-win.el (dynamic-library-alist): Use instead of `image-library-alist'. * nt/INSTALL: Refer to `dynamic-library-alist'. * src/image.c (Vimage_library_alist) (syms_of_image) <image-library-alist>: Move to src/emacs.c and rename. (lookup_image_type): Use Vdynamic_library_alist. (Finit_image_library): Doc fix. * src/emacs.c (Vdynamic_library_alist) (syms_of_emacs) <dynamic-library-alist>: Move from src/image.c and rename. Doc fix. * src/lisp.h (Vdynamic_library_alist): Declare extern.
author Juanma Barranquero <lekktu@gmail.com>
date Wed, 13 Oct 2010 16:50:06 +0200
parents 99084f50aa8e
children 42dfe6f887b0
line wrap: on
line diff
--- a/src/emacs.c	Wed Oct 13 11:55:48 2010 +0000
+++ b/src/emacs.c	Wed Oct 13 16:50:06 2010 +0200
@@ -187,6 +187,9 @@
    Lisp code.  */
 Lisp_Object Vemacs_copyright, Vemacs_version;
 
+/* Alist of external libraries and files implementing them.  */
+Lisp_Object Vdynamic_library_alist;
+
 /* If non-zero, emacs should not attempt to use a window-specific code,
    but instead should use the virtual terminal under which it was started.  */
 int inhibit_window_system;
@@ -2507,6 +2510,24 @@
 	       doc: /* Version numbers of this version of Emacs.  */);
   Vemacs_version = build_string (emacs_version);
 
+  DEFVAR_LISP ("dynamic-library-alist", &Vdynamic_library_alist,
+    doc: /* Alist of dynamic libraries vs external files implementing them.
+Each element is a list (LIBRARY FILE...), where the car is a symbol
+representing a supported external library, and the rest are strings giving
+alternate filenames for that library.
+
+Emacs tries to load the library from the files in the order they appear on
+the list; if none is loaded, the running session of Emacs won't have access
+to that library.
+
+Note that image types `pbm' and `xbm' do not need entries in this variable
+because they do not depend on external libraries and are always available.
+
+Also note that this is not a generic facility for accessing external
+libraries; only those already known by Emacs will be loaded.  */);
+  Vdynamic_library_alist = Qnil;
+  Fput (intern_c_string ("dynamic-library-alist"), Qrisky_local_variable, Qt);
+
   /* Make sure IS_DAEMON starts up as false.  */
   daemon_pipe[1] = 0;
 }