Patch - Defsystem - load-defsystem.lisp - *compile-file-truename*

Sean Champ <[email protected]> Sat, 29 Jul 2006 23:35:39 -0700
Newsgroups gmane.lisp.clocc.devel
Message-ID <[email protected]>
The patch attached to this message updates the eval-when form in the file
CLOCC src/defsystem4/src/load-defsystem.lisp 

The update is so as to use the value of *COMPILE-FILE-TRUENAME*, in
preference before *LOAD-TRUENAME* . This should serve to support that the
file would be compiled before being loaded.

Additionally, some typographic things are corrected, in the patch. There
were a couple of extra words in some comment text, removed in the patch,
and a typo is fixed.

--
Sean

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

_______________________________________________
clocc-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/clocc-devel
defsystem.load-defsystem.lisp.diff (text/x-diff, 2.7 KB)
Index: load-defsystem.lisp
===================================================================
RCS file: /cvsroot/clocc/clocc/src/defsystem-4/src/load-defsystem.lisp,v
retrieving revision 1.15
diff -p -u -u -r1.15 load-defsystem.lisp
--- load-defsystem.lisp	25 Nov 2002 23:56:31 -0000	1.15
+++ load-defsystem.lisp	30 Jul 2006 06:29:41 -0000
@@ -24,14 +24,15 @@
 ;;; Thanks to Kevin Rosenberg for the following very nice idea.
 
 (eval-when (:compile-toplevel :load-toplevel :execute)
-  (defparameter *mk-defsystem-absolute-directory-pathname*
-    (make-pathname :host (pathname-host *load-truename*)
-		   :device (pathname-device *load-truename*)
-		   :directory (pathname-directory *load-truename*)
-		   )))
+  (let ((the-pathname (or *compile-file-truename* *load-truename*)))
+    (defparameter *mk-defsystem-absolute-directory-pathname*
+      (make-pathname :host (pathname-host the-pathname)
+		     :device (pathname-device the-pathname)
+		     :directory (pathname-directory the-pathname)
+		     ))))
 
 ;;; The following three parameters are tested IN SEQUENCE and
-;;; exclusively.  The first one found true one will cause the
+;;; exclusively.  The first one found true will cause the
 ;;; associated action to be performed.
 
 (defparameter *mk-defsystem-load-source-only-p* nil
@@ -49,7 +50,7 @@
 ;;; They are used to override the values of *LOAD-PRINT* and
 ;;; *LOAD-VERBOSE*.
 ;;;
-;;; Note that it they are DEFVAR's for a good reason.  Loading the
+;;; Note that they are DEFVAR's for a good reason.  Loading the
 ;;; file should not change their values; however, loading the file should
 ;;; define them if they are not defined yet.
 
@@ -60,7 +61,7 @@
 
 ;;;===========================================================================
 ;;; Support code and actual load forms.
-;;; You should not be required to look at anyhting beyond this point
+;;; You should not be required to look at anything beyond this point
 ;;; if not for debugging purposes.
 
 
@@ -71,7 +72,7 @@
 (defparameter *mk-defsystem-lp-filenames*
   '(
     "MAKE-DEFSYSTEM:;adjoin-dirs"
-    
+
     "MAKE-DEFSYSTEM:defsystem-pkg"
     ;; "MAKE-DEFSYSTEM:conditions"
     ;; "MAKE-DEFSYSTEM:utilities;split-sequence" ; Loaded separatedly.
@@ -103,7 +104,7 @@
 
     ;; This was above.
     "MAKE-DEFSYSTEM:utilities;user-interaction"
-    
+
     "MAKE-DEFSYSTEM:impl-dependent;common"
     #+(or cmu sbcl scl) "MAKE-DEFSYSTEM:impl-dependent;cmucl" ; Hopefully correct.
     #+clisp "MAKE-DEFSYSTEM:impl-dependent;clisp"
@@ -137,7 +138,7 @@
   ;; :WILD-INFERIORS on the right hand side of the definitions.
   ;; For the time being, since we only have three subdirectories it
   ;; should not be a problem.
-  
+
   (setf (logical-pathname-translations "MAKE-DEFSYSTEM")
 	`(("impl-dependent;*.*.*"
 	   ,(make-pathname