Ticket #204: abcl-asdf-fix.patch

File abcl-asdf-fix.patch, 1.9 KB (added by Cyrusharmon, 13 years ago)

Patch that fixes maybe-parse-mvn to respect version information

  • contrib/abcl-asdf/abcl-asdf.lisp

    diff --git a/contrib/abcl-asdf/abcl-asdf.lisp b/contrib/abcl-asdf/abcl-asdf.lisp
    index 5ca8dbb..8f78dbf 100644
    a b (defun maybe-parse-mvn (component) 
    3434               asdf::version asdf::schema asdf::path)
    3535      component
    3636    (when (null asdf::artifact-id)
    37       (let ((parsed (abcl-asdf::split-string name "/")))
    38          (unless (or (= (length parsed) 3)
    39                      (and (= (length parsed) 2)
    40                           asdf::version))
    41           (error "Failed to construct a mvn reference from name '~A' and version '~A'"
    42                  asdf::name
    43                  (if asdf::version
    44                      asdf::version
    45                      "UNSPECIFED")))
    46          (setf asdf::group-id (first parsed)
    47                asdf::artifact-id (second parsed)
    48                asdf::schema "mvn"
    49                asdf::version (if (third parsed)
    50                                  (third parsed)
    51                                  "LATEST"))
    52          (setf asdf::path (format nil "~A/~A" asdf::name asdf::version))))))
     37      (let ((parsed (abcl-asdf::split-string name "/"))
     38            (version "LATEST"))
     39        (cond ((= (length parsed) 3)
     40               (setf version (third parsed)))
     41              ((and (= (length parsed) 2)
     42                    (setf version (or asdf::version version))))
     43              (t (error "Failed to construct a mvn reference from name '~A' and version '~A'"
     44                        asdf::name
     45                        (if asdf::version
     46                            asdf::version
     47                            "UNSPECIFED"))))
     48        (setf asdf::group-id (first parsed)
     49              asdf::artifact-id (second parsed)
     50              asdf::schema "mvn"
     51              asdf::version version)
     52        (setf asdf::path (format nil "~A/~A" asdf::name asdf::version))))))
    5353
    5454(defmethod source-file-type ((component iri) (system system))
    5555  nil)