~ chicken-core (chicken-5) c19d3c2a86574437b27723ebfd9dd13d6c1686be


commit c19d3c2a86574437b27723ebfd9dd13d6c1686be
Author:     felix <felix@y.(none)>
AuthorDate: Sat Mar 20 23:04:58 2010 +0100
Commit:     felix <felix@y.(none)>
CommitDate: Sat Mar 20 23:04:58 2010 +0100

    cleanup and trivial fix

diff --git a/library.scm b/library.scm
index 5756ec26..cd0dbc2f 100644
--- a/library.scm
+++ b/library.scm
@@ -262,7 +262,7 @@ EOF
 	    (and (##core#inline "C_specialp" x) (fx= i 0))
 	    (##core#inline "C_byteblockp" x) ) 
     (##sys#signal-hook '#:type-error '##sys#block-set! "slot not accessible" x) )
-  (##sys#check-range i 0 (##sys#size x) '##sys#block-set!) ]
+  (##sys#check-range i 0 (##sys#size x) '##sys#block-set!)
   (##sys#setslot x i y) )
 
 (define (current-seconds) 
diff --git a/setup-api.scm b/setup-api.scm
index 95503b5a..abe860e5 100644
--- a/setup-api.scm
+++ b/setup-api.scm
@@ -203,11 +203,6 @@
 
 (define run-verbose (make-parameter #t))
 
-(define (->symbol x)
-  (cond ((symbol? x) x)
-	((string? x) (string->symbol x))
-	(else (string->symbol (->string x)))))
-
 (define (register-program name #!optional
 			  (path (make-pathname *chicken-bin-path* (->string name))))
   (set! *registered-programs* 
@@ -223,30 +218,26 @@
 (let ()
   (define (reg name rname) 
     (register-program name (make-pathname *chicken-bin-path* rname)))
-  ;; csc is handled below
   (reg "chicken" (foreign-value "C_CHICKEN_PROGRAM" c-string))
   (reg "csi" (foreign-value "C_CSI_PROGRAM" c-string))
+  (reg "csc" (foreign-value "C_CSC_PROGRAM" c-string))
   (reg "chicken-bug" (foreign-value "C_CHICKEN_BUG_PROGRAM" c-string)))
 
 (define (fixpath prg)
-  (cond ((string=? prg "csc")
-	 (string-intersperse 
-	  (cons* (shellpath
-		  (make-pathname 
-		   *chicken-bin-path*
-		   (cdr (assoc prg *installed-executables*))))
-		 "-feature" "compiling-extension" 
-		 (if (and (feature? #:cross-chicken)
-			  (not (host-extension)))
-		     "" "-setup-mode")
-		 (if (keep-intermediates) "-k" "")
-		 (if (host-extension) "-host" "")
-		 (if (deployment-mode) "-deployed" "")
-		 *csc-options*) 
-	  " ") )
-	((assoc prg *registered-programs*) => 
-	 (lambda (a) (shellpath (cdr a))))
-	(else prg) ) )
+  (if (string=? prg "csc")
+      (string-intersperse 
+       (cons*
+	(shellpath (find-program "csc"))
+	"-feature" "compiling-extension" 
+	(if (and (feature? #:cross-chicken)
+		 (not (host-extension)))
+	    "" "-setup-mode")
+	(if (keep-intermediates) "-k" "")
+	(if (host-extension) "-host" "")
+	(if (deployment-mode) "-deployed" "")
+	*csc-options*) 
+       " ")
+      (shellpath (find-program prg))))
 
 (define (fixmaketarget file)
   (if (and (equal? "so" (pathname-extension file))
Trap