diff options
Diffstat (limited to 'app-emacs/slime-cvs/files/swank.asd')
-rw-r--r-- | app-emacs/slime-cvs/files/swank.asd | 55 |
1 files changed, 31 insertions, 24 deletions
diff --git a/app-emacs/slime-cvs/files/swank.asd b/app-emacs/slime-cvs/files/swank.asd index 991c3822d637..39a42b7e5e65 100644 --- a/app-emacs/slime-cvs/files/swank.asd +++ b/app-emacs/slime-cvs/files/swank.asd @@ -1,9 +1,12 @@ -;;; -*- mode: lisp; syntax: common-lisp; indent-tabs-mode: nil; package: cl-user -*- +;;; -*- mode: lisp; syntax: common-lisp; package: common-lisp -*- (defpackage #:swank-system (:use #:common-lisp #:asdf)) +(defpackage #:swank-loader + (:use #:common-lisp)) + (in-package #:swank-system) ;; http://www.caddr.com/macho/archives/sbcl-devel/2004-3/3014.html @@ -15,28 +18,32 @@ (operation-on-failure op) :warn) ; adjust to taste (call-next-method)) -(defsystem #:swank - :name "Swank is the Common Lisp back-end to Slime" - :licence "GPL-2" - :components - #+cmu ((:file "swank-backend") - (:file "nregex") - (:file "swank-source-path-parser") - (:file "swank-cmucl") - (:file "swank")) - #+sbcl ((:file "swank-backend") - (:file "swank-sbcl") - (:file "nregex") - (:file "swank-source-path-parser") - (:file "swank-gray") - (:unsafe-file "swank")) - #+clisp ((:file "swank-backend") - (:file "nregex") - (:file "xref") - (:file "metering") - (:file "swank-clisp") - (:file "swank-gray") - (:file "swank")) - #+sbcl :depends-on #+sbcl (:sb-bsd-sockets)) +(defmacro define-swank-system (&rest sysdep-components) + `(defsystem swank + :name "Swank is the Common Lips back-end to SLIME" + :serial t + :components ((:file "swank-backend") + (:file "nregex") + ,@(mapcar #'(lambda (component) + (if (atom component) + (list :file component) + component)) + sysdep-components) + (:file "swank")) + :depends-on (#+sbcl sb-bsd-sockets))) + +#+sbcl (define-swank-system "swank-sbcl" "swank-source-path-parser" "swank-gray") +#+cmu (define-swank-system "swank-source-path-parser" "swank-cmucl") +#+clisp (define-swank-system "xref" "metering" "swank-clisp" "swank-gray") + +(in-package #:swank-loader) + +(defun user-init-file () + "Return the name of the user init file or nil." + (probe-file (merge-pathnames (user-homedir-pathname) + (make-pathname :name ".swank" :type "lisp")))) + +(when (user-init-file) + (load (user-init-file))) ;; swank.asd ends here |