diff src/emodules.c @ 1750:7580e52a8218

[xemacs-hg @ 2003-10-15 03:09:02 by james] Define module-load-path and module-extensions even when compiling without modulesupport.
author james
date Wed, 15 Oct 2003 03:09:03 +0000
parents 5903b079bee1
children 3fe1a35b705d
line wrap: on
line diff
--- a/src/emodules.c	Tue Oct 14 17:27:54 2003 +0000
+++ b/src/emodules.c	Wed Oct 15 03:09:03 2003 +0000
@@ -21,6 +21,12 @@
 #include "emodules.h"
 #include "sysdll.h"
 
+/* Load path */
+static Lisp_Object Vmodule_load_path;
+
+/* Module lFile extensions */
+static Lisp_Object Vmodule_extensions;
+
 #ifdef HAVE_SHLIB
 
 /* CE-Emacs version number */
@@ -33,8 +39,6 @@
    as it allows the unbinding of symbol-value-forward variables. */
 int unloading_module;
 
-/* Load path */
-Lisp_Object Vmodule_load_path;
 Lisp_Object Qdll_error;
 Lisp_Object Qmodule, Qunload_module, module_tag;
 
@@ -49,8 +53,6 @@
   dll_handle dlhandle;  /* Dynamic lib handle                              */
 } emodules_list;
 
-static Lisp_Object Vmodule_extensions;
-
 static int emodules_depth;
 static dll_handle dlhandle;
 static emodules_list *modules;
@@ -576,9 +578,14 @@
   modnum = 0;
 }
 
+#endif /* HAVE_SHLIB */
+
 void
 vars_of_module (void)
 {
+#ifdef HAVE_SHLIB
+  Fprovide (intern ("modules"));
+
   reinit_vars_of_module ();
 
   DEFVAR_LISP ("module-version", &Vmodule_version /*
@@ -603,6 +610,14 @@
 */);
   load_modules_quietly = 0;
 
+  DEFVAR_BOOL ("unloading-module", &unloading_module /*
+Used internally by `unload-feature'.  Do not set this variable.
+Danger, danger, Will Robinson!
+*/);
+  unloading_module = 0;
+
+#endif /* HAVE_SHLIB */
+
   DEFVAR_LISP ("module-load-path", &Vmodule_load_path /*
 *List of directories to search for dynamic modules to load.
 Each element is a string (directory name) or nil (try default directory).
@@ -625,12 +640,6 @@
 */);
   Vmodule_load_path = Qnil;
 
-  DEFVAR_BOOL ("unloading-module", &unloading_module /*
-Used internally by `unload-feature'.  Do not set this variable.
-Danger, danger, Will Robinson!
-*/);
-  unloading_module = 0;
-
   DEFVAR_LISP ("module-extensions", &Vmodule_extensions /*
 *List of filename extensions to use when searching for dynamic modules.
 */);
@@ -639,8 +648,4 @@
 			      build_string (".dll"),
 			      build_string (".dylib"),
 			      build_string (""));
-
-  Fprovide (intern ("modules"));
 }
-
-#endif /* HAVE_SHLIB */