summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Benkard <code@mail.matthias.benkard.de>2008-02-19 23:45:32 +0100
committerMatthias Benkard <code@mail.matthias.benkard.de>2008-02-19 23:45:32 +0100
commit62cf73f61556ad494ebe98dc6bb349086da5453c (patch)
treea00a5f44f85f01ff66d5561ff2868b2ffb18149c
parent6e5edeca079d53152a87ea2c883eb94e888fa090 (diff)
Make the system loadable from SLIME on Allegro CL.
darcs-hash:df48e2c1f0a91284c607d36ea4cedc85b555a9ca
-rw-r--r--objective-cl-libobjcl.asd75
1 files changed, 41 insertions, 34 deletions
diff --git a/objective-cl-libobjcl.asd b/objective-cl-libobjcl.asd
index 20deebb..6c08e6c 100644
--- a/objective-cl-libobjcl.asd
+++ b/objective-cl-libobjcl.asd
@@ -36,23 +36,26 @@
(null (output-files o c)))
(zerop
;; Run `make' at the top level of the directory tree.
- (run-shell-command "make -C '~A'"
- (namestring
- (make-pathname
- :directory
- (pathname-directory
- (merge-pathnames
- (make-pathname :directory '(:relative ".." ".."))
- (first
- (output-files
- o
- (find "libobjcl"
- (module-components
- (first
+ (let (#+allegro (asdf::*verbose-out* (if (find-package '#:swank)
+ nil
+ asdf::*verbose-out*)))
+ (run-shell-command "make -C '~A'"
+ (namestring
+ (make-pathname
+ :directory
+ (pathname-directory
+ (merge-pathnames
+ (make-pathname :directory '(:relative ".." ".."))
+ (first
+ (output-files
+ o
+ (find "libobjcl"
(module-components
- (find-system "objective-cl-libobjcl"))))
- :key #'component-name
- :test #'string=)))))))))))
+ (first
+ (module-components
+ (find-system "objective-cl-libobjcl"))))
+ :key #'component-name
+ :test #'string=))))))))))))
(defmethod output-files :around ((o compile-op) (c objc-source-file))
;; If this doesn't get called at all, we're kind of screwed.
@@ -129,7 +132,10 @@
(output-dir
(merge-pathnames #p"../../"
(directory-namestring (first output-files))))
- (output-parent-dir (merge-pathnames #p"../" output-dir)))
+ (output-parent-dir (merge-pathnames #p"../" output-dir))
+ #+allegro (asdf::*verbose-out* (if (find-package '#:swank)
+ nil
+ asdf::*verbose-out*)))
;; First try using cp to copy the files over to the compilation
;; directory. If that fails, do it manually, file by file.
(unless (and (not (position #\' (namestring source-dir))) ; a safety measure
@@ -139,23 +145,24 @@
;;
;; But first, do some sanity checks about the
;; environment.
- (or (and (zerop (run-shell-command "ls -d -i '~A'"
- source-dir))
- (zerop (run-shell-command "ls -d -i '~A'"
- output-parent-dir))
- (zerop (run-shell-command "echo"))
- (zerop (run-shell-command "echo | awk '{ print $1 }'"))
- (zerop
- (run-shell-command
- "test ~
- \"x$(ls -d -i '~A' | awk '{ print $1 }')\" ~
- = ~
- \"x$(ls -d -i '~A' | awk '{ print $1 }')\""
- source-dir
- output-parent-dir)))
- (zerop (run-shell-command "cp -R -P -f -p '~A' '~A/'"
- source-dir
- output-parent-dir))))
+ (ignore-errors
+ (or (and (zerop (run-shell-command "ls -d -i '~A'"
+ source-dir))
+ (zerop (run-shell-command "ls -d -i '~A'"
+ output-parent-dir))
+ (zerop (run-shell-command "echo"))
+ (zerop (run-shell-command "echo | awk '{ print $1 }'"))
+ (zerop
+ (run-shell-command
+ "test ~
+ \"x$(ls -d -i '~A' | awk '{ print $1 }')\" ~
+ = ~
+ \"x$(ls -d -i '~A' | awk '{ print $1 }')\""
+ source-dir
+ output-parent-dir)))
+ (zerop (run-shell-command "cp -R -P -f -p '~A' '~A/'"
+ source-dir
+ output-parent-dir)))))
;; We couldn't use cp. Copy the files manually.
(let ((sources
(mapcar #'(lambda (x)