CVS update by aidan xemacs/lisp/mule ...

xemacs-cvs at xemacs.org xemacs-cvs at xemacs.org
Wed Oct 31 07:21:16 EDT 2007


  User: aidan   
  Date: 07/10/31 12:21:16

  Modified:    xemacs/lisp/mule general-late.el
Log:
Use correct coding system information for Installation-string.

Revision  Changes    Path
1.854     +33 -0     XEmacs/xemacs/lisp/ChangeLog

Index: ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/ChangeLog,v
retrieving revision 1.853
retrieving revision 1.854
diff -u -p -r1.853 -r1.854
--- ChangeLog	2007/10/26 10:51:02	1.853
+++ ChangeLog	2007/10/31 11:21:02	1.854
@@ -1,5 +1,38 @@
 2007-10-26  Aidan Kehoe  <kehoea at parhasard.net>
 
+	* mule/general-late.el:
+	Now that all the dumped coding systems are available, decode
+	Installation-string using the value for
+	Installation-file-coding-system at dump time. 
+
+2007-10-26  Aidan Kehoe  <kehoea at parhasard.net>
+
+	* dumped-lisp.el (preloaded-file-list):
+	Allow version.el to be compiled. 
+	* help.el (describe-installation):
+	Use and-boundp instead of (and (boundp ...); don't decode
+	Installation-string. Call #'error with a DATUM arg. 
+	* loadup.el:
+	* loadup.el (Installation-string): Removed.
+	Moved to version.el.
+	* loadup.el (really-early-error-handler):
+	Move the initialization of Installation-string to version.el too.
+	* update-elc-2.el (update-elc-ignored-files):
+	* update-elc-2.el (batch-update-elc-2):
+	Remove version.el from the ignored files; if Mule is available,
+	always recompile it, since Installation-file-coding-system depends
+	on relatively complex Mule code. 
+	* update-elc.el (unbytecompiled-lisp-files):
+	Remove version.el.
+	* version.el:
+	* version.el (Installation-file-coding-system): New.
+	Variable reflecting the native coding system at build time, to
+	better work out Installation-string. 
+	* version.el (Installation-string): New.
+	Moved from loadup.el; documented in more detail.
+
+2007-10-26  Aidan Kehoe  <kehoea at parhasard.net>
+
 	* mule/latin.el:
 	"pl" is the normal POSIX language code for Polish, not "po"; if a
 	tutorial is provided, set tutorial-coding-system explicitly based



1.64      +1 -1      XEmacs/xemacs/lisp/dumped-lisp.el

Index: dumped-lisp.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/dumped-lisp.el,v
retrieving revision 1.63
retrieving revision 1.64
diff -u -p -r1.63 -r1.64
--- dumped-lisp.el	2007/07/22 22:03:31	1.63
+++ dumped-lisp.el	2007/10/31 11:21:05	1.64
@@ -33,7 +33,7 @@ in dumped-lisp.el and is not itself list
        "post-gc"
        "replace" 		; match-string used in version.el.
 
-       "version.el"             ; Ignore compiled-by-mistake version.elc
+       "version"
 
        "cl"
        "cl-extra"



1.50      +4 -7      XEmacs/xemacs/lisp/help.el

Index: help.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/help.el,v
retrieving revision 1.49
retrieving revision 1.50
diff -u -p -r1.49 -r1.50
--- help.el	2007/08/07 23:08:51	1.49
+++ help.el	2007/10/31 11:21:05	1.50
@@ -829,16 +829,13 @@ of the key sequence that ran this comman
 (defun describe-installation ()
   "Display a buffer showing information about this XEmacs was compiled."
   (interactive)
-  (if (and (boundp 'Installation-string)
-	   (stringp Installation-string))
+  (if (and-boundp 'Installation-string
+	(stringp Installation-string))
       (with-displaying-help-buffer
        (lambda ()
-	 (princ
-	  (if (fboundp 'decode-coding-string)
-	      (decode-coding-string Installation-string 'automatic-conversion)
-	    Installation-string)))
+	 (princ Installation-string))
        "Installation")
-    (error "No Installation information available.")))
+    (error 'unimplemented "No Installation information available.")))
 
 (defun view-emacs-news ()
   "Display info on recent changes to XEmacs."



1.34      +0 -19     XEmacs/xemacs/lisp/loadup.el

Index: loadup.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/loadup.el,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -p -r1.33 -r1.34
--- loadup.el	2006/12/29 18:09:43	1.33
+++ loadup.el	2007/10/31 11:21:05	1.34
@@ -69,9 +69,6 @@ Used during loadup and for documenting s
 (defvar preloaded-file-list nil
   "List of files preloaded into the XEmacs binary image.")
 
-(defvar Installation-string nil
-  "Description of XEmacs installation.")
-
 ;(start-profiling)
 
 (let ((gc-cons-threshold
@@ -88,22 +85,6 @@ Used during loadup and for documenting s
 ;; This is awfully damn early to be getting an error, right?
 (call-with-condition-handler 'really-early-error-handler
     #'(lambda ()
-
-	;; Initialize Installation-string.  We do it before loading
-	;; anything so that dumped code can make use of its value.
-	(setq Installation-string
-	      (save-current-buffer
-		(set-buffer (get-buffer-create (generate-new-buffer-name
-						" *temp*")))
-		;; insert-file-contents-internal bogusly calls
-		;; format-decode without checking if it's defined.
-		(fset 'format-decode #'(lambda (f l &optional v) l))
-		(insert-file-contents-internal
-		 (expand-file-name "Installation" build-directory))
-		(fmakunbound 'format-decode)
-		(prog1 (buffer-substring)
-		  (kill-buffer (current-buffer)))))
-
 	(setq load-path (list source-lisp))
 	(setq module-load-path (list 
 				(expand-file-name "modules" build-directory)))



1.13      +7 -4      XEmacs/xemacs/lisp/update-elc-2.el

Index: update-elc-2.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/update-elc-2.el,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -p -r1.12 -r1.13
--- update-elc-2.el	2005/02/03 07:11:20	1.12
+++ update-elc-2.el	2007/10/31 11:21:05	1.13
@@ -65,8 +65,7 @@
     "^make-docfile\\.el$"
     "^site-start\\.el$"
     "^site-load\\.el$"
-    "^site-init\\.el$"
-    "^version\\.el$"))
+    "^site-init\\.el$"))
 
 (defvar dirfiles-table (make-hash-table :test 'equal))
 
@@ -190,8 +189,12 @@
     (byte-recompile-file (expand-file-name "custom-load.el" dir) 0)
     (when (featurep 'mule)
       (Custom-make-dependencies (expand-file-name "mule" dir))
-      (byte-recompile-file (expand-file-name "mule/custom-load.el" dir) 0))
-    )
+      (byte-recompile-file (expand-file-name "mule/custom-load.el" dir) 0)
+      ;; See the eval-when-compile in the definition of
+      ;; Installation-file-coding-system; if the file name sniffing or the
+      ;; available coding systems have changed, version.elc should be
+      ;; rebuilt.
+      (byte-recompile-file (expand-file-name "version.el" dir) 0)))
   (setq command-line-args-left nil))
 
 ;;; update-elc-2.el ends here



1.37      +1 -2      XEmacs/xemacs/lisp/update-elc.el

Index: update-elc.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/update-elc.el,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -p -r1.36 -r1.37
--- update-elc.el	2006/07/16 12:23:58	1.36
+++ update-elc.el	2007/10/31 11:21:05	1.37
@@ -117,8 +117,7 @@
   '("paths.el"
     "dumped-lisp.el"
     "dumped-pkg-lisp.el"
-    "raw-process.el"
-    "version.el")
+    "raw-process.el")
   "Lisp files that should not be byte compiled.
 Files in `additional-dump-dependencies' do not need to be listed here.")
 



1.51      +43 -11    XEmacs/xemacs/lisp/version.el

Index: version.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/version.el,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -p -r1.50 -r1.51
--- version.el	2002/08/28 05:36:32	1.50
+++ version.el	2007/10/31 11:21:05	1.51
@@ -129,16 +129,48 @@ argument are optional. Only the Non-nil 
 ;;; We hope that this alias is easier for people to find.
 (define-function 'version 'emacs-version)
 
-;; Put the emacs version number into the `pure[]' array in a form that
-;; `what(1)' can extract from the executable or a core file.  We don't
-;; actually need this to be pointed to from lisp; pure objects can't
-;; be GCed.
-(concat "\n@" "(#)" (emacs-version)
-	"\n@" "(#)" "Configuration: "
-	system-configuration "\n")
+(defvar Installation-file-coding-system
+  (eval-when-compile `,(coding-system-name (find-coding-system 'native)))
+  "The coding system used to create the `Installation' file.
 
-;;Local variables:
-;;version-control: never
-;;End:
+The `Installation' file is created by configure, and the
+`Installation-string' variable reflects its contents.
 
-;;; version.el ends here
+This is initialized to reflect the native coding system at the time
+version.el was byte-compiled; ideally it would reflect the native coding
+system of the environment when XEmacs was dumped, but the locale
+initialization code isn't called at dump time, and the appropriate value
+at byte-compile time should be close enough.  Note that this means that the
+value of `Installation-string' during dump time thus reflects loading the
+file using the `binary' coding system.  ")
+
+(defvar Installation-string
+  ;; Initialize Installation-string.  We do it before loading
+  ;; anything so that dumped code can make use of its value.
+  (save-current-buffer
+    (set-buffer (get-buffer-create (generate-new-buffer-name
+				    " *temp*")))
+    ;; insert-file-contents-internal bogusly calls
+    ;; format-decode without checking if it's defined.
+    (fset 'format-decode #'(lambda (f l &optional v) l))
+    (insert-file-contents-internal
+     (expand-file-name "Installation" build-directory)
+     ;; Relies on our working out the system coding system
+     ;; correctly at startup.
+     nil nil nil nil 
+     ;; Installation-file-coding-system is actually respected in
+     ;; mule/general-late.el, after all the dumped coding systems have been
+     ;; loaded.
+     'binary)
+    (fmakunbound 'format-decode)
+    (prog1 (buffer-substring)
+      (kill-buffer (current-buffer))))
+  "Description of XEmacs installation.
+
+This reflects the values that the configure script worked out at build time,
+including things like the C code features included at compile time and the
+installation prefix.  Normally used when submitting a bug report;
+occasionally used, in a way the XEmacs developers don't endorse, to work out
+version information.  ")
+
+;;; version.el ends here
\ No newline at end of file



1.5       +11 -2     XEmacs/xemacs/lisp/mule/general-late.el

Index: general-late.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/lisp/mule/general-late.el,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -p -r1.4 -r1.5
--- general-late.el	2007/08/26 20:00:41	1.4
+++ general-late.el	2007/10/31 11:21:15	1.5
@@ -54,12 +54,21 @@
 	    (remassoc "German" language-info-alist))
       language-info-alist
       (cons (assoc "English" language-info-alist)
-	    (remassoc "English" language-info-alist)))
+	    (remassoc "English" language-info-alist))
 
+      ;; Make Installation-string actually reflect the environment at
+      ;; byte-compile time. (We can't necessarily decode it when version.el
+      ;; is loaded, since not all the coding systems are available then.)
+      Installation-string (if-boundp 'Installation-file-coding-system
+			      (decode-coding-string
+			       Installation-string
+			       Installation-file-coding-system)
+			    Installation-string))
+
 ;; At this point in the dump, all the charsets have been loaded. Now, load
 ;; their Unicode mappings.
 (if load-unicode-tables-at-dump-time
     (let ((data-directory (expand-file-name "etc" source-directory)))
       (load-unicode-tables)))
 
-;;; general-late.el ends here
\ No newline at end of file
+;;; general-late.el ends here





More information about the XEmacs-CVS mailing list