Commit 38159c01 authored by Hugo Ishimaru's avatar Hugo Ishimaru
Browse files

Merge branch 'master' into ja

parents b2499102 9ac28afa
......@@ -93,7 +93,7 @@
:licence "MIT"
:description "Another System Definition Facility"
:long-description "ASDF builds Common Lisp software organized into defined systems."
:version "3.3.2.12" ;; to be automatically updated by make bump-version
:version "3.3.2.13" ;; to be automatically updated by make bump-version
:depends-on ()
:components ((:module "build" :components ((:file "asdf"))))
. #-asdf3 () #+asdf3
......
......@@ -65,7 +65,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@titlepage
@title ASDF: Another System Definition Facility
@subtitle Manual for Version 3.3.2.12
@subtitle Manual for Version 3.3.2.13
@c The following two commands start the copyright page.
@page
@vskip 0pt plus 1filll
......@@ -82,7 +82,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@node Top, Introduction, (dir), (dir)
@top ASDF: Another System Definition Facility
@ifnottex
Manual for Version 3.3.2.12
Manual for Version 3.3.2.13
@end ifnottex
......@@ -934,15 +934,17 @@ ASDF hooks into the @code{cl:require} facility and you can just use:
(require :@var{foo})
@end example
Note that the canonical name of a system is a string, conventionally lowercase.
A system name can also be specified as a symbol (including a keyword),
in which case its @code{symbol-name} is taken and lowercased.
Note that the canonical name of a system is a string, in @emph{lowercase}.
System names can also be specified as symbols (including keyword
symbols).
If a symbol is given as argument, its package is ignored,
its @code{symbol-name} is taken, and converted to lowercase.
The name must be a suitable value for the @code{:name} initarg
to @code{make-pathname} in whatever filesystem the system is to be found.
The lower-casing-symbols behaviour is unconventional,
Using lowercase as canonical is unconventional,
but was selected after some consideration.
The type of systems we want to support
The type of file systems we support
either have lowercase as customary case (Unix, Mac, Windows)
or silently convert lowercase to uppercase (lpns).
@c so this makes more sense than attempting to use @code{:case :common},
......@@ -1419,7 +1421,15 @@ Presumably, the 4th form looks like @code{(defparameter *foo-version* "5.6.7")}.
@example
system-definition := ( defsystem system-designator @var{system-option}* )
system-definition := ( defsystem system-designator @var{system-option}*)
system-designator := simple-component-name | complex-component-name
simple-component-name := lower-case string | symbol
NOTE: Underscores are not permitted. See below.
complex-component-name := string | symbol
See below.
system-option := :defsystem-depends-on system-list
| :weakly-depends-on @var{system-list}
......@@ -1485,6 +1495,10 @@ simple-component-name := string
| symbol
pathname-specifier := pathname | string | symbol
NOTE: pathnames should be all lower case, and have no
underscores, although hyphens are permitted.
version-specifier := string
| (:read-file-form <pathname-specifier> <form-specifier>?)
......@@ -1502,11 +1516,50 @@ feature-expression := keyword
| (:not @var{feature-expression})
@end example
@subsection System designators
System designators are either simple component names, or
complex (``slashy'') component names.
@subsection Simple component names (@code{simple-component-name})
Simple component names may be written as either strings or symbols.
When using strings, use lower case exclusively.
@subsection Component names
Symbols will be interpreted as convenient shorthand for the string
that is their @code{symbol-name}, converted to lower case. Put
differently, a symbol may be a simple component name @emph{designator},
but the simple component name itself is the string.
Component names (@code{simple-component-name})
may be either strings or symbols.
@strong{Never} use underscores in component names, whether written as
strings or symbols.
@strong{Never} use slashes (``/'') in simple component names. A slash
indicates a @emph{complex} component name; see below. Using a slash
improperly will cause ASDF to issue a warning.
Violating these constraints by mixing case, or including underscores in
component names, may lead to systems or components being impossible to
find, because component names are interpreted as file names. These
problems will @emph{definitely} occur for users who have configured ASDF
using logical pathnames.
@subsection Complex component names
A complex component name is a master name followed by a slash, followed
by a subsidiary name. This allows programmers to put multiple system
definitions in a single @code{.asd} file, while still allowing ASDF to
find these systems.
The master name of a complex system @strong{must} be the same as the
name of the @code{.asd} file.
The file @code{foo.asd} will contain the definition of the system
@code{"foo"}. However, it may @emph{also} contain definitions of
subsidiary systems, such as @code{"foo/test"}, @code{"foo/docs"}, and so
forth. ASDF will ``know'' that if you ask it to load system
@code{"foo/test"} it should look for that system's definition in @code{foo.asd}.
@subsection Component types
@anchor{Component types}
......@@ -1642,13 +1695,17 @@ If a symbol is given, it will be translated into a string,
and downcased in the process.
The downcasing of symbols is unconventional,
but was selected after some consideration.
Observations suggest that the type of systems we want to support
either have lowercase as customary case (Unix, Mac, windows)
The file systems we support
either have lowercase as customary case (Unix, Mac, Windows)
or silently convert lowercase to uppercase (lpns),
so this makes more sense than attempting to use @code{:case :common}
as argument to @code{make-pathname},
which is reported not to work on some implementations.
Please avoid using underscores in system names, or component (module or
file) names, since underscores are not
compatible with logical pathnames (@pxref{Using logical pathnames}).
Pathname objects may be given to override the path for a component.
Such objects are typically specified using reader macros such as @code{#p}
or @code{#.(make-pathname ...)}.
......
......@@ -185,7 +185,7 @@ The `:perform` clause in the second system does the testing itself.
In the test system, `fiveam` is the name of a popular test library,
and the content of the `perform` method is how to invoke this library
to run the test suite `:foobar`.
Obvious YMMV if you use a different library.
Obviously your mileage may vary if you use a different library.
#### <a name="notes_asdf2"></a>Note on ASDF 2 compatibility
......@@ -773,7 +773,7 @@ in a separate `.asd` file that you `:defsystem-depends-on`.
Then, `.asd` files are read with the current package being `asdf-user`.
You MAY use any symbols defined in packages `cl`, `asdf` and `uiop`,
and you SHOULD stay in package `asdf-user` if it suffices;
you SHOULD NOT needlessly create a package for you system definition file
you SHOULD NOT needlessly create a package for your system definition file
if you're not going to define any such function nor variable nor macro.
But you MUST NOT pollute that package with bindings that could clash with uses by other systems.
......@@ -830,7 +830,7 @@ to the otherwise deprecated use of read-time conditionals, as in:
If the condition you want to express doesn't have a corresponding `*features*` keyword,
you MAY use a `(when ... (pushnew :my-keyword *features*))` form to add a feature keyword for it.
However, you SHOULD NOT needlessly push new features;
in particular, the mere fact of have loaded your system does not warrant a new feature.
in particular, the mere fact of having loaded your system does not warrant a new feature.
A feature is only warranted if your system is some deep infrastructure
with mostly compatible rivals that it needs to be distinguished from.
......
;;; -*- mode: Lisp; Base: 10 ; Syntax: ANSI-Common-Lisp ; buffer-read-only: t; -*-
;;; This is ASDF 3.3.2.12: Another System Definition Facility.
;;; This is ASDF 3.3.2.13: Another System Definition Facility.
;;;
;;; Feedback, bug reports, and patches are all welcome:
;;; please mail to <asdf-devel@common-lisp.net>.
......
......@@ -17,7 +17,8 @@
#:class-for-type #:*default-component-class*
#:determine-system-directory #:parse-component-form
#:non-toplevel-system #:non-system-system #:bad-system-name
#:*known-name-exception-systems*
#:*known-systems-with-bad-secondary-system-names*
#:known-system-with-bad-secondary-system-names-p
#:sysdef-error-component #:check-component-input
#:explain))
(in-package :asdf/parse-defsystem)
......@@ -345,7 +346,12 @@ system names contained using COERCE-NAME. Return the result."
(coerce-name (component-system component))))
component)))
(defparameter* *known-name-exception-systems* '("cl-ppcre"))
(defparameter* *known-systems-with-bad-secondary-system-names*
(list-to-hash-set '("cl-ppcre")))
(defun known-system-with-bad-secondary-system-names-p (asd-name)
;; Does .asd file with name ASD-NAME contain known exceptions
;; that should be screened out of checking for BAD-SYSTEM-NAME?
(gethash asd-name *known-systems-with-bad-secondary-system-names*))
(defun register-system-definition
(name &rest options &key pathname (class 'system) (source-file () sfp)
......@@ -360,21 +366,15 @@ system names contained using COERCE-NAME. Return the result."
(with-asdf-session ())
(let* ((name (coerce-name name))
(source-file (if sfp source-file (resolve-symlinks* (load-pathname))))))
(flet ((fix-case (x) (if (logical-pathname-p source-file) (string-downcase x) x))
(known-exception (name)
;; is NAME a known exception that should be screened out
;; of checking for BAD-SYSTEM-NAME?
(member-if #'(lambda (x) (uiop:string-prefix-p x name))
*known-name-exception-systems*))))
(flet ((fix-case (x) (if (logical-pathname-p source-file) (string-downcase x) x))))
(let* ((asd-name (and source-file
(equal "asd" (fix-case (pathname-type source-file)))
(fix-case (pathname-name source-file))))
;; note that PRIMARY-NAME is a *syntactically* primary name --
;; so "cl-ppcre-test" (grrr.....) is a PRIMARY-NAME.
;; note that PRIMARY-NAME is a *syntactically* primary name
(primary-name (primary-system-name name)))
(when (and asd-name
(not (equal asd-name primary-name))
(not (known-exception primary-name)))
(not (known-system-with-bad-secondary-system-names-p asd-name)))
(warn (make-condition 'bad-system-name :source-file source-file :name name))))
(let* (;; NB: handle defsystem-depends-on BEFORE to create the system object,
;; so that in case it fails, there is no incomplete object polluting the build.
......
......@@ -372,12 +372,18 @@ upgrade_tags () {
# The 3.3 series provides the asdf3.3 feature, meaning users can rely on
# all its new features (proper phase separation) as well as earlier features.
# 3.3.0 (2017-10-06) first in 3.3 series
# 3.3.1 (2017-11-14) bug fixes, second and latest in 3.3 series
# 3.3.1 (2017-11-14) bug fixes, second
# 3.3.2 (2018-05-03) bug fixes, third and latest in 3.3 series
#
# We return the above designated versions in order of decreasing relevance,
# which pretty much means REQUIRE and most recent first.
# We picked the last and first in each relevant series, plus 2.26.
echo REQUIRE 3.3.1 3.3.0 3.2.1 3.2.0 3.1.7 3.1.2 3.0.3 2.26
if [ "$lisp" = cmucl ]; then
echo REQUIRE 3.3.2 3.3.1 3.3.0
else
echo REQUIRE 3.3.2 3.3.1 3.3.0 3.2.1 3.2.0 3.1.7 3.1.2 3.0.3 2.26
fi
#echo 3.1.7 3.1.6 3.1.5 3.1.4 3.1.3 3.1.2
#echo 3.0.3 3.0.2 3.0.1
......
......@@ -25,5 +25,6 @@
(declare (ignorable c))
(format t "~&Catching bad name warning: ~A~%" c)
(throw 'bad-name-warn nil))))
(let ((asdf::*known-name-exception-systems* '("test-bad-system-name")))
(let ((asdf::*known-systems-with-bad-secondary-system-names*
(list-to-hash-set '("test-bad-system-name"))))
(find-system "test-bad-system-name")))))
;;; -*- Lisp -*-
(in-package :asdf-test)
(when (member :clisp *features*)
(quit 0))
(defparameter *lambda-string* nil)
(defun string-char-codes (s)
......
......@@ -40,7 +40,7 @@ you already have a matching UIOP loaded."
(:file "image" :depends-on ("stream"))
(:file "lisp-build" :depends-on ("image"))
(:file "launch-program" :depends-on ("stream"))
(:file "run-program" :depends-on ("launch-program"))
(:file "run-program" :depends-on ("launch-program" "version"))
(:file "configuration" :depends-on ("image"))
(:file "backward-driver" :depends-on ("lisp-build" "run-program" "configuration" "version"))
(:file "driver" :depends-on ("backward-driver")))
......
......@@ -12,7 +12,7 @@
(in-package :uiop/version)
(with-upgradability ()
(defparameter *uiop-version* "3.3.2.12")
(defparameter *uiop-version* "3.3.2.13")
(defun unparse-version (version-list)
"From a parsed version (a list of natural numbers), compute the version string"
......
......@@ -94,7 +94,7 @@ previously-loaded version of ASDF."
;; "3.4.5.67" would be a development version in the official branch, on top of 3.4.5.
;; "3.4.5.0.8" would be your eighth local modification of official release 3.4.5
;; "3.4.5.67.8" would be your eighth local modification of development version 3.4.5.67
(asdf-version "3.3.2.12")
(asdf-version "3.3.2.13")
(existing-version (asdf-version)))
(setf *asdf-version* asdf-version)
(when (and existing-version (not (equal asdf-version existing-version)))
......
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