From 34abe734976bd58ceee345f5f6d1ad1a914acfc3 Mon Sep 17 00:00:00 2001 Message-Id: <34abe734976bd58ceee345f5f6d1ad1a914acfc3.1715593992.git.mdw@distorted.org.uk> From: Mark Wooding Date: Wed, 30 Aug 2006 11:08:12 +0000 Subject: [PATCH] Library extensions not hard coded any more Organization: Straylight/Edgeware From: espen --- atk/atk.lisp | 4 ++-- gdk/gdktypes.lisp | 6 +++--- pango/pango.lisp | 11 +++++++---- rsvg/rsvg.lisp | 4 ++-- tools/asdf-extensions.lisp | 9 ++++++--- 5 files changed, 20 insertions(+), 14 deletions(-) diff --git a/atk/atk.lisp b/atk/atk.lisp index b76ce6c..1837108 100644 --- a/atk/atk.lisp +++ b/atk/atk.lisp @@ -20,7 +20,7 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: atk.lisp,v 1.5 2005-04-23 16:48:49 espen Exp $ +;; $Id: atk.lisp,v 1.6 2006-08-30 11:08:12 espen Exp $ (in-package "ATK") @@ -28,6 +28,6 @@ (in-package "ATK") (eval-when (:compile-toplevel :load-toplevel :execute) (init-types-in-library #.(concatenate 'string (pkg-config:pkg-variable "atk" "libdir") - "/libatk-1.0.so") :prefix "atk_")) + "/libatk-1.0." asdf:*dso-extension*) :prefix "atk_")) (define-types-by-introspection "Atk") diff --git a/gdk/gdktypes.lisp b/gdk/gdktypes.lisp index 80983ed..9304173 100644 --- a/gdk/gdktypes.lisp +++ b/gdk/gdktypes.lisp @@ -20,17 +20,17 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: gdktypes.lisp,v 1.25 2006-07-06 13:05:59 espen Exp $ +;; $Id: gdktypes.lisp,v 1.26 2006-08-30 11:08:12 espen Exp $ (in-package "GDK") (eval-when (:compile-toplevel :load-toplevel :execute) (init-types-in-library #.(concatenate 'string (pkg-config:pkg-variable "gtk+-2.0" "libdir") - "/libgdk-x11-2.0.so") :prefix ("gdk_" "_gdk_")) + "/libgdk-x11-2.0." asdf:*dso-extension*) :prefix ("gdk_" "_gdk_")) (init-types-in-library #.(concatenate 'string (pkg-config:pkg-variable "gtk+-2.0" "libdir") - "/libgdk_pixbuf-2.0.so") :prefix "gdk_")) + "/libgdk_pixbuf-2.0." asdf:*dso-extension*) :prefix "gdk_")) (defclass color (boxed) diff --git a/pango/pango.lisp b/pango/pango.lisp index 276f0af..04d90c5 100644 --- a/pango/pango.lisp +++ b/pango/pango.lisp @@ -20,20 +20,23 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: pango.lisp,v 1.11 2006-04-26 12:40:39 espen Exp $ +;; $Id: pango.lisp,v 1.12 2006-08-30 11:08:13 espen Exp $ (in-package "PANGO") (eval-when (:compile-toplevel :load-toplevel :execute) (init-types-in-library #.(concatenate 'string (pkg-variable "pango" "libdir") - "/libpango-1.0.so") :prefix "pango_") + "/libpango-1.0." asdf:*dso-extension*) + :prefix "pango_") (init-types-in-library #.(concatenate 'string (pkg-variable "pango" "libdir") - "/libpangoxft-1.0.so") :prefix "pango_xft") + "/libpangoxft-1.0." asdf:*dso-extension*) + :prefix "pango_xft") (init-types-in-library #.(concatenate 'string (pkg-variable "pango" "libdir") - "/libpangoft2-1.0.so") :prefix "pango_fc")) + "/libpangoft2-1.0." asdf:*dso-extension*) + :prefix "pango_fc")) (eval-when (:compile-toplevel :load-toplevel :execute) diff --git a/rsvg/rsvg.lisp b/rsvg/rsvg.lisp index 466e9e5..4093c0c 100644 --- a/rsvg/rsvg.lisp +++ b/rsvg/rsvg.lisp @@ -20,7 +20,7 @@ ;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE ;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -;; $Id: rsvg.lisp,v 1.4 2006-02-13 20:10:48 espen Exp $ +;; $Id: rsvg.lisp,v 1.5 2006-08-30 11:08:13 espen Exp $ (in-package "RSVG") @@ -28,7 +28,7 @@ (in-package "RSVG") (eval-when (:compile-toplevel :load-toplevel :execute) (init-types-in-library #.(concatenate 'string (pkg-config:pkg-variable "librsvg-2.0" "libdir") - "/librsvg-2.so") :prefix "rsvg_") + "/librsvg-2." asdf:*dso-extension*) :prefix "rsvg_") (define-types-by-introspection "Rsvg" ("RsvgError" :ignore t))) diff --git a/tools/asdf-extensions.lisp b/tools/asdf-extensions.lisp index 93be2d3..14a4db7 100644 --- a/tools/asdf-extensions.lisp +++ b/tools/asdf-extensions.lisp @@ -1,6 +1,9 @@ (in-package :asdf) -(export 'load-dso) +(export '*dso-extension*) + +(defvar *dso-extension* #-darwin"so" #+darwin"dylib") + (defun concatenate-strings (strings &optional delimiter) (if (not (rest strings)) @@ -27,7 +30,7 @@ (defmethod input-files ((operation compile-op) (dso unix-dso)) (defmethod output-files ((operation compile-op) (dso unix-dso)) (let ((dir (component-pathname dso))) (list - (make-pathname :type "so" + (make-pathname :type *dso-extension* :name (car (last (pathname-directory dir))) :directory (butlast (pathname-directory dir)) :defaults dir)))) @@ -125,7 +128,7 @@ (defun split-path (path) (defmethod component-pathname ((lib library)) - (make-pathname :type "so" + (make-pathname :type *dso-extension* :name (component-name lib) :directory (split-path (slot-value lib 'libdir)))) -- [mdw]