chiark / gitweb /
Added slot LIBNAME to component class LIBRARY
[clg] / tools / asdf-extensions.lisp
index cd69b8557f5fc7a6396315fc14562b87551c8c28..576c8f82b4616610c8c834b76c3565af130c3fdc 100644 (file)
@@ -2,7 +2,7 @@ (in-package :asdf)
 
 (export '*dso-extension*)
 
-(defvar *dso-extension* #-darwin"so" #+darwin"dylib")
+(defparameter *dso-extension* #-darwin"so" #+darwin"dylib")
 
 
 ;;; The following code is more or less copied frm sb-bsd-sockets.asd,
@@ -106,7 +106,8 @@ (defmethod perform ((operation load-op) (c c-source-file))
 ;;; Shared libraries
 
 (defclass library (component) 
-  ((libdir :initarg :libdir)))
+  ((libdir :initarg :libdir)
+   (libname :initarg :libname :initform nil)))
 
 
 (defun split-path (path)
@@ -123,7 +124,7 @@ (defun split-path (path)
 
 (defmethod component-pathname ((lib library))
   (make-pathname :type *dso-extension*
-                :name (component-name lib)
+                :name (or (slot-value lib 'libname) (component-name lib))
                 :directory (split-path (slot-value lib 'libdir))))
 
 (defmethod perform ((o load-op) (c library))