Commit cab5dfa1 authored by Francois-Rene Rideau's avatar Francois-Rene Rideau

2.26.128: punt on CLISP upgrade. Test with ECL, SBCL.

Better version mangling helpers.

Image: for compatibility with existing CL practice,
the call the entry-point *without* arguments rather than with C command line.
parent 49ab669e
......@@ -55,7 +55,7 @@ install: archive-copy
bump: bump-version
bump-version: build/asdf.lisp
./bin/asdf-builder bump-version
./bin/asdf-builder bump-version ${v}
driver-files:
@echo $(driver_lisp)
......
......@@ -15,7 +15,7 @@
:licence "MIT"
:description "Another System Definition Facility"
:long-description "ASDF builds Common Lisp software organized into defined systems."
:version "2.26.127" ;; to be automatically updated by bin/bump-revision
:version "2.26.128" ;; to be automatically updated by make bump-version
:depends-on ()
:components ((:module "build" :components ((:file "asdf"))))
:in-order-to (#+asdf2.27 (compile-op (monolithic-load-concatenated-source-op asdf/defsystem))))
......
......@@ -172,7 +172,7 @@
(defparameter *versioned-files*
'(("version.lisp-expr" "\"" "\"")
("asdf.asd" " :version \"" "\" ;; to be automatically updated by bin/bump-revision")
("asdf.asd" " :version \"" "\" ;; to be automatically updated by make bump-version")
("header.lisp" "This is ASDF " ": Another System Definition Facility.")
("upgrade.lisp" " (asdf-version \"" "\")")))
......
......@@ -3,13 +3,23 @@
(format t "Loading your implementation's ASDF... ~%")
(require :asdf)
(in-package :asdf)
(format t "~:[No ~;~]ASDF~:*~@[ ~A~] was provided~%"
(when (find-package :asdf)
(or (symbol-value (or (find-symbol (string :*asdf-version*) :asdf)
(find-symbol (string :*asdf-revision*) :asdf)))
(string :1.x))))
#-asdf2 (error "Not ASDF2, you lose!")
(in-package :asdf)
(defparameter *provided-version* (asdf-version))
(format t "Initializing the source registry... ~%")
(initialize-source-registry)
(format t "Upgrading to the latest ASDF... ~%")
(upgrade-asdf)
(format t "At ASDF ~A.~%" (asdf-version))
(load-system :asdf)
(let ((ver (asdf-version)))
(if (equal ver *provided-version*)
(format t "Congratulations to your implementation for being up to date!~%")
(format t "Upgraded to ASDF ~A~%" ver)))
(format t "Now loading some dependencies... ~%")
(load-systems :cl-ppcre :fare-utils :inferior-shell)
......
;; -*- mode: Common-Lisp; Base: 10 ; Syntax: ANSI-Common-Lisp ; coding: utf-8 -*-
;;; This is ASDF 2.26.127: Another System Definition Facility.
;;; This is ASDF 2.26.128: Another System Definition Facility.
;;;
;;; Feedback, bug reports, and patches are all welcome:
;;; please mail to <asdf-devel@common-lisp.net>.
......@@ -46,3 +46,21 @@
;;; we can't use defsystem to compile it. Hence, all in one file.
#+xcvb (module ())
#+clisp
(in-package :cl-user)
#+clisp
(eval-when (:load-toplevel :compile-toplevel :execute)
(unless (member :asdf2.27 *features*)
(let ((p (find-package :asdf)))
(when p
(rename-package
:asdf
(format nil "~A-~A" :asdf
(or (symbol-value (and (member :asdf2 *features*)
(or (find-symbol (string :*asdf-version*) :asdf)
(find-symbol (string :*asdf-revision*) :asdf))))
:1.x)))
(when *load-verbose*
(format t "; Renamed package ~A away to ~A~%"
:asdf (package-name p)))))))
......@@ -226,7 +226,7 @@ if we are not called from a directly executable image dumped by XCVB."
(standard-eval-thunk *image-prelude*)
(let ((results (multiple-value-list
(if *image-entry-point*
(apply (ensure-function *image-entry-point*) *command-line-arguments*)
(call-function *image-entry-point*)
t))))
(if *lisp-interaction*
(apply 'values results)
......
......@@ -10,8 +10,6 @@
;; and reexported in a different package
;; (alternatively the package may be dropped & replaced by one with a new name).
#+clisp (declaim (optimize (speed 1)(safety 3)(debug 3)))
(defpackage :asdf/package
(:use :common-lisp)
(:export
......
......@@ -240,7 +240,7 @@ upgrade_tags () {
# 1.369 is the last release by Gary King
# 2.000 to 2.019 and 2.20 to 2.27 and beyond are Faré's "stable" releases
# 2.26.61 is the last single-package ASDF.
echo REQUIRE 1.37 1.97 1.369 2.26.61
echo REQUIRE 1.37 1.97 1.369
git tag -l '2.0??'
git tag -l '2.??'
}
......
......@@ -251,14 +251,6 @@ is bound, write a message and exit on an error. If
(defun register-directory (dir)
(pushnew dir (symbol-value (asym :*central-registry*))))
(defun clean-asdf-system ()
(let ((fasl (resolve-output "asdf" "build" "asdf.fasl")))
(when (DBG :clean fasl (probe-file fasl)) (delete-file fasl))))
(defun load-asdf-lisp-clean ()
(load-asdf-lisp)
(clean-asdf-system))
(defun load-asdf-system (&rest keys)
(quietly
(register-directory *asdf-directory*)
......@@ -359,16 +351,22 @@ is bound, write a message and exit on an error. If
(register-directory *test-directory*)
(acall :oos (asym :load-op) x :verbose verbose)))
(defun get-asdf-version ()
(when (find-package :asdf)
(or (symbol-value (or (find-symbol (string :*asdf-version*) :asdf)
(find-symbol (string :*asdf-revision*) :asdf)))
(string :1.x))))
(defun test-upgrade (old-method new-method tag) ;; called by run-test
(with-test ()
#+clisp (trace compile-file load)
(when old-method
(cond
((string-equal tag "REQUIRE")
(format t "Requiring some previous asdf ~A~%" tag)
(format t "Requiring some previous ASDF ~A~%" tag)
(ignore-errors (funcall 'require "asdf"))
(unless (member "ASDF" *modules* :test 'equalp)
(leave-test "Your Lisp implementation does not provide ASDF. Skipping test.~%" 0)))
(if (member "ASDF" *modules* :test 'equalp)
(format t "Your Lisp implementation provided ASDF ~A~%" (get-asdf-version))
(leave-test "Your Lisp implementation does not provide ASDF. Skipping test.~%" 0)))
(t
(format t "Loading old asdf ~A via ~A~%" tag old-method)
(funcall old-method tag))))
......@@ -394,6 +392,14 @@ is bound, write a message and exit on an error. If
(defun test-fasl (file)
(acall :compile-file-pathname* (test-source file)))
(defun clean-asdf-system ()
(let ((fasl (resolve-output "asdf" "build" "asdf.fasl")))
(when (DBG :clean fasl (probe-file fasl)) (delete-file fasl))))
(defun load-asdf-lisp-clean ()
(load-asdf-lisp)
(clean-asdf-system))
(defun configure-asdf ()
(setf *debug-asdf* (or *debug-asdf* (acall :getenvp "DEBUG_ASDF_TEST")))
(untrace)
......
......@@ -2,9 +2,6 @@
(load-asdf)
#+clisp
(trace load compile-file)
#-gcl<2.7
(setf (logical-pathname-translations "ASDF")
#+(or allegro clisp)
......
......@@ -56,8 +56,8 @@
'("file1" "file2" "file3"))))))
;; and loaded
(assert (eval (asdf::find-symbol* '#:*file1* :test-package)))
(assert (eval (asdf::find-symbol* '#:*file3* :test-package)))
(assert (eval (find-symbol* '#:*file1* :test-package)))
(assert (eval (find-symbol* '#:*file3* :test-package)))
;; now touch file1 and check that file2 _is_ also recompiled
......@@ -66,21 +66,19 @@
;; dependency bug is fixed and the excessive compilation bug is fixed.
(defparameter before file3-date)
(touch-file "file1.lisp" :timestamp (- before 60))
(touch-file (test-source "file1.lisp") :timestamp (- before 60))
(touch-file file1 :timestamp (- before 90))
(touch-file "file2.lisp" :timestamp (- before 30))
(touch-file (test-source "file2.lisp") :timestamp (- before 30))
(touch-file file2 :timestamp (- before 15))
(defparameter plan (asdf::traverse
(make-instance 'asdf:load-op)
(asdf:find-system 'test-module-excessive-depend)))
(defparameter file3 (asdf:find-component :file3-only "file3"))
(defparameter plan (traverse 'load-op 'test-module-excessive-depend))
(defparameter file3c (find-component :file3-only "file3"))
#|(format t "~%Operation plan is:~%")(pprint plan)(terpri)|#
(when (loop :for (o . c) :in plan :thereis (and (eq c file3) (typep o 'asdf:compile-op)))
(when (loop :for (o . c) :in plan :thereis (and (eq c file3c) (typep o 'asdf:compile-op)))
(error "Excessive operations on file3-only system. Bad propagation of dependencies."))
(asdf:operate 'asdf:load-op 'test-module-excessive-depend)
(assert (>= (file-write-date file1) before))
(assert (>= (file-write-date file2) before)))
(assert (>= (file-write-date file2) before))
(unless (= (file-write-date file3)
file3-date)
(error "Excessive compilation of file3.lisp: traverse bug."))
......@@ -28,14 +28,14 @@
(eval-when (:load-toplevel :compile-toplevel :execute)
(let* (;; For bug reporting sanity, please always bump this version when you modify this file.
;; Please also modify asdf.asd to reflect this change. The script bin/bump-version
;; Please also modify asdf.asd to reflect this change. make bump-version
;; can help you do these changes in synch (look at the source for documentation).
;; Relying on its automation, the version is now redundantly present on top of this file.
;; "2.345" would be an official release
;; "2.345.6" would be a development version in the official upstream
;; "2.345.0.7" would be your seventh local modification of official release 2.345
;; "2.345.6.7" would be your seventh local modification of development version 2.345.6
(asdf-version "2.26.127")
(asdf-version "2.26.128")
(existing-asdf (find-class (find-symbol* :component :asdf nil) nil))
(existing-version *asdf-version*)
(already-there (equal asdf-version existing-version))
......@@ -65,7 +65,7 @@
(format *trace-output*
(compatfmt "~&~@<; ~@;Upgrading ASDF ~@[from version ~A ~]to version ~A~@:>~%")
existing-version asdf-version))
(loop :for name :in (append #-(or clisp ecl common-lisp) redefined-functions)
(loop :for name :in (append #-(or clisp ecl) redefined-functions)
:for sym = (find-symbol* name :asdf nil) :do
(when sym
;;(format t "Undefining ~S~%" sym);XXX
......
......@@ -59,11 +59,11 @@
(declare (ignorable supersede))
`(progn
;; undefining the previous function is the portable way
;; of overriding any incompatible previous gf,
;; but we usually try to do it only for the functions that need it,
;; of overriding any incompatible previous gf, except on CLISP.
;; We usually try to do it only for the functions that need it,
;; which happens in asdf/upgrade - however, for ECL, we need this hammer,
;; (which causes issues in clisp)
,@(when (or #-ecl supersede #+(or (and gcl (not gcl-pre2.7))) t) ; XXX
,@(when (or supersede #+(or ecl (and gcl (not gcl-pre2.7))) t) ; XXX
`((undefine-function ',name)))
#-gcl ; gcl 2.7.0 notinline functions lose secondary return values :-(
,@(when (and #+ecl (symbolp name)) ; fails for setf functions on ecl
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment