Commit f70b13b5 authored by Francois-Rene Rideau's avatar Francois-Rene Rideau
Browse files

2.117: fix more breakage from the 2.112 optimization.

Fix wild-modules to work nicely well with ASDF2.
Allow to pass multiple script arguments to run-tests.sh.
Tests now pass on ABCL.
parent 5ee6773f
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@

(eval-when (:load-toplevel :compile-toplevel :execute)
  (let* ((asdf-version ;; the 1+ helps the version bumping script discriminate
          (subseq "VERSION:2.116" (1+ (length "VERSION"))))
          (subseq "VERSION:2.117" (1+ (length "VERSION"))))
         (existing-asdf (find-package :asdf))
         (vername '#:*asdf-version*)
         (versym (and existing-asdf
@@ -753,8 +753,10 @@ actually-existing directory."
  "when given a pathname P, probes the filesystem for a file or directory
with given pathname and if it exists return its truename."
  (and (pathnamep p) (not (wild-pathname-p p))
       #+(or allegro clozure cmu ecl sbcl scl) (probe-file p)
       #+clisp (ext:probe-pathname p)
       #-clisp (probe-file p)))
       #-(or allegro clisp clozure cmu ecl sbcl scl)
       (ignore-errors (truename p))))

(defun* truenamize (p)
  "Resolve as much of a pathname as possible"
+3 −3
Original line number Diff line number Diff line
@@ -41,11 +41,12 @@ if [ x"$1" = "xhelp" ]; then
    usage
    exit 1
fi
lisp=$1 ; shift

if [ -z "$2" ]; then
if [ -z "$*" ]; then
    scripts="*.script"
else
    scripts="$2"
    scripts="$*"
fi

sok=1
@@ -98,7 +99,6 @@ do_tests() {
# terminate on error
set -e

lisp=$1
if [ -z $1 ] ; then
    lisp="sbcl"
fi
+4 −1
Original line number Diff line number Diff line
@@ -25,7 +25,7 @@
                           :direction :output
                           :if-exists :supersede)
        (with-standard-io-syntax
          (format out "~{~S~}" contents))))))
          (format out "~{~S~%~}" contents))))))

(defparameter *test-asd-directories*
  (loop
@@ -69,6 +69,9 @@

(create-asd-files)
(create-conf-files)

#+abcl (trace directory)

(initialize-source-registry
 `(:source-registry (:include ,(under-test-directory "conf.d/"))
                    :ignore-inherited-configuration))
+10 −15
Original line number Diff line number Diff line
@@ -12,27 +12,22 @@
use a wild pathname instead." module)))

(defmethod reinitialize-instance :after ((self wild-module) &key)
  (let ((pathname (slot-value self 'relative-pathname)))
    (and pathname
         (not (wild-pathname-p pathname))
  (let ((pathname (component-pathname self)))
    (unless (and pathname (wild-pathname-p pathname))
      (sysdef-error "Wild-module ~A specified with non-wild pathname ~A."
                    self pathname))
    (setf (slot-value self 'components)
          (let* ((*default-pathname-defaults* (component-parent-pathname self))
                 (files (directory (merge-pathnames (component-relative-pathname self))))
          (let* ((files (directory pathname))
                 (class (wild-module-component-class self))
                 (options (wild-module-component-options self)))
            (mapcar (lambda (file)
                      (apply #'make-instance class
                             :name (file-namestring file)
                                        ;; XXX fails when wildcards are in
                                        ;; the directory or higher parts.
                             :name (namestring file)
                             :pathname file
                             :parent self
                             options))
                    files)))))
                    files)))
    (compute-module-components-by-name self)
    (values)))

;; Don't export wild-module or else will get a full warning
;; when (require :asdf) if asdf is already loaded

;;(export '(wild-module))
(export 'wild-module)