diff --git a/asdf.lisp b/asdf.lisp index c328d72..0e9a2f1 100755 --- a/asdf.lisp +++ b/asdf.lisp @@ -1351,6 +1351,7 @@ make sure we clear them thoroughly." :accessor system-license :initarg :license) (source-file :reader system-source-file :initarg :source-file :writer %set-system-source-file) + (compilation-nicknames :reader compilation-nicknames :initarg :compile-with-nicknames) (defsystem-depends-on :reader system-defsystem-depends-on :initarg :defsystem-depends-on))) @@ -2220,6 +2221,17 @@ recursive calls to traverse.") (class-of operation) component)) ;;;; ------------------------------------------------------------------------- +;;;; package nickname handling for compile-op + +(defun set-package-nicknames (compilation-nicknames) + ;; TODO implement this! + 'set-nicknames) + +(defun unset-package-nicknames (set-nicknames) + ;; TODO implement this! + t) + +;;;; ------------------------------------------------------------------------- ;;;; compile-op (defclass compile-op (operation) @@ -2274,6 +2286,7 @@ recursive calls to traverse.") (defmethod perform ((operation compile-op) (c cl-source-file)) #-:broken-fasl-loader (let ((source-file (component-pathname c)) + (system (component-system c)) ;; on some implementations, there are more than one output-file, ;; but the first one should always be the primary fasl that gets loaded. (output-file (first (output-files operation c))) @@ -2282,8 +2295,12 @@ recursive calls to traverse.") (multiple-value-bind (output warnings-p failure-p) (call-with-around-compile-hook c (lambda () - (apply *compile-op-compile-file-function* source-file - :output-file output-file (compile-op-flags operation)))) + (let ((set-nicknames (set-package-nicknames + (compilation-nicknames system)))) + (unwind-protect + (apply *compile-op-compile-file-function* source-file + :output-file output-file (compile-op-flags operation)) + (unset-package-nicknames set-nicknames))))) (unless output (error 'compile-error :component c :operation operation)) (when failure-p