In the attached patch, "compile-file" was changed to allow overriding
the default compilation options (previously the default options were
always added to the options given).


cheers,
felix
>From aa7ec49c16b38fad36b2340d03229e9ec8977778 Mon Sep 17 00:00:00 2001
From: felix <[email protected]>
Date: Sun, 4 Mar 2012 11:53:54 +0100
Subject: [PATCH] options explicitly given to compile-file override default options

---
 utils.scm |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/utils.scm b/utils.scm
index 0db5c96..41934bc 100644
--- a/utils.scm
+++ b/utils.scm
@@ -83,14 +83,16 @@
   (let ((csc (foreign-value "C_CSC_PROGRAM" c-string))
 	(load-file load)
 	(path (foreign-value "C_INSTALL_BIN_HOME" c-string)) )
-    (lambda (filename #!key (options '()) output-file (load #t) verbose)
+    (lambda (filename #!key options output-file (load #t) verbose)
       (let* ((cscpath (or (file-exists? (make-pathname path csc)) "csc"))
 	     (tmpfile (and (not output-file) (create-temporary-file "so")))
 	     (crapshell (eq? (build-platform) 'mingw32))
 	     (cmd (sprintf "~a~a -s ~a ~a -o ~a~a" 
 		    (if crapshell "\"" "")
 		    (qs cscpath)
-		    (string-intersperse (append (compile-file-options) options) " ")
+		    (string-intersperse
+		     (or options
+			 (compile-file-options)))
 		    (qs filename)
 		    (qs (or output-file tmpfile))
 		    (if crapshell "\"" ""))))
-- 
1.6.0.4

_______________________________________________
Chicken-hackers mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/chicken-hackers

Reply via email to