Changeset 14502
- Timestamp:
- 05/17/13 11:06:59 (11 years ago)
- Location:
- trunk/abcl
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abcl/doc/asdf/asdf.texinfo
r14461 r14502 7 7 @c We use @&key, etc to escape & from TeX in lambda lists -- 8 8 @c so we need to define them for info as well. 9 @macro &allow-other-keys9 @macro AallowOtherKeys 10 10 &allow-other-keys 11 11 @end macro 12 @macro &optional12 @macro Aoptional 13 13 &optional 14 14 @end macro 15 @macro &rest15 @macro Arest 16 16 &rest 17 17 @end macro 18 @macro &key18 @macro Akey 19 19 &key 20 20 @end macro 21 @macro &body21 @macro Abody 22 22 &body 23 @end macro24 @macro &curly25 {26 @end macro27 @macro &ylruc28 }29 23 @end macro 30 24 … … 870 864 @c insufficient node breakdown that I have not put one in. 871 865 @item 872 Make sure you know how the @code{:version} numbers will be parsed! They 873 are parsed as period-separated lists of integers. I.e., in the example, 874 @code{0.2.1} is to be interpreted, roughly speaking, as @code{(0 2 1)}. 875 In particular, version @code{0.2.1} is interpreted the same as 876 @code{0.0002.1} and is strictly version-less-than version @code{0.20.1}, 866 Make sure you know how the @code{:version} numbers will be parsed! 867 They are parsed as period-separated lists of integers. 868 I.e., in the example, @code{0.2.1} is to be interpreted, 869 roughly speaking, as @code{(0 2 1)}. 870 In particular, version @code{0.2.1} 871 is interpreted the same as @code{0.0002.1} and 872 is strictly version-less-than version @code{0.20.1}, 877 873 even though the two are the same when interpreted as decimal fractions. 878 874 Instead of a string representing the version, … … 881 877 in addition to being a literal string, it can be an expression of the form 882 878 @code{(:read-file-form <pathname-or-string> :at <access-at-specifier>)}, 883 which will be resolved by reading a form 884 in the specified pathname 879 which will be resolved by reading a form in the specified pathname 885 880 (read as a subpathname of the current system if relative or a unix-namestring). 886 You may use an access-at specifier with the (optional) :at keyword, 887 by default the specifier is 0, meaning the first form is returned. 881 You may use a @code{uiop:access-at} specifier 882 with the (optional) @code{:at} keyword, 883 by default the specifier is @code{0}, meaning the first form is returned. 888 884 889 885 @cindex :version … … 1013 1009 pathname-specifier := pathname | string | symbol 1014 1010 1015 method-form := (operation-name qual lambda-list @ &rest body)1011 method-form := (operation-name qual lambda-list @Arest body) 1016 1012 qual := method qualifier 1017 1013 … … 1189 1185 @cindex :version 1190 1186 1191 Version specifiers are parsed as period-separated lists of integers. I.e., in the example, 1192 @code{0.2.1} is to be interpreted, roughly speaking, as @code{(0 2 1)}. 1193 In particular, version @code{0.2.1} is interpreted the same as 1194 @code{0.0002.1} and is strictly version-less-than version @code{0.20.1}, 1195 even though the two are the same when interpreted as decimal fractions. 1187 Version specifiers are strings to be parsed as period-separated lists of integers. 1188 I.e., in the example, @code{"0.2.1"} is to be interpreted, 1189 roughly speaking, as @code{(0 2 1)}. 1190 In particular, version @code{"0.2.1"} is interpreted the same as @code{"0.0002.1"}, 1191 though the latter is not canonical and may lead to a warning being issued. 1192 Also, @code{"1.3"} and @code{"1.4"} are both strictly @code{uiop:version<} to @code{"1.30"}, 1193 quite unlike what would have happened 1194 had the version strings been interpreted as decimal fractions. 1196 1195 1197 1196 System definers are encouraged to use version identifiers of the form 1198 @var{x}.@var{y}.@var{z} for major version, minor version (compatible 1199 API) and patch level. 1197 @var{x}.@var{y}.@var{z} for 1198 major version, minor version and patch level, 1199 where significant API incompatibilities are signaled by an increased major number. 1200 1200 1201 1201 @xref{Common attributes of components}. … … 1349 1349 Files containing @code{defsystem} forms 1350 1350 are regular Lisp files that are executed by @code{load}. 1351 Consequently, you can put whatever Lisp code you like into these files 1352 (e.g., code that examines the compile-time environment 1353 and adds appropriate features to @code{*features*}). 1354 However, some conventions should be followed, 1351 Consequently, you can put whatever Lisp code you like into these files. 1352 However, it is recommended to keep such forms to a minimal, 1353 and to instead define @code{defsystem} extensions 1354 that you use with @code{:defsystem-depends-on}. 1355 1356 If however, you might insist on including code in the @code{.asd} file itself, 1357 e.g., to examine and adjust the compile-time environment, 1358 possibly adding appropriate features to @code{*features*}. 1359 If so, here are some conventions we recommend you follow, 1355 1360 so that users can control certain details of execution 1356 1361 of the Lisp in @file{.asd} files: … … 1485 1490 Operations are invoked on systems via @code{operate}. 1486 1491 @anchor{operate} 1487 @deffn {Generic function} @code{operate} @var{operation} @var{system} @ &rest @var{initargs} @&key @code{force} @code{force-not} @code{verbose} @&allow-other-keys1488 @deffnx {Generic function} @code{oos} @var{operation} @var{system} @ &rest @var{initargs} @&key @&allow-other-keys1492 @deffn {Generic function} @code{operate} @var{operation} @var{system} @Arest @var{initargs} @Akey @code{force} @code{force-not} @code{verbose} @AallowOtherKeys 1493 @deffnx {Generic function} @code{oos} @var{operation} @var{system} @Arest @var{initargs} @Akey @AallowOtherKeys 1489 1494 @code{operate} invokes @var{operation} on @var{system}. 1490 1495 @code{oos} is a synonym for @code{operate}. … … 1541 1546 @end lisp 1542 1547 1543 @deffn Operation @code{compile-op} @ &key @code{proclamations}1548 @deffn Operation @code{compile-op} @Akey @code{proclamations} 1544 1549 1545 1550 This operation compiles the specified component. … … 1558 1563 @end deffn 1559 1564 1560 @deffn Operation @code{load-op} @ &key @code{proclamations}1565 @deffn Operation @code{load-op} @Akey @code{proclamations} 1561 1566 1562 1567 This operation loads a system. … … 1566 1571 @end deffn 1567 1572 1568 @deffn Operation @code{parent-load-op} @ &key @code{proclamations}1573 @deffn Operation @code{parent-load-op} @Akey @code{proclamations} 1569 1574 1570 1575 This operation ensures that the dependencies … … 1652 1657 @end deffn 1653 1658 1654 1655 @c @deffn Operation test-system-version @&key minimum1656 1657 @c Asks the system whether it satisfies a version requirement.1658 1659 @c The default method accepts a string, which is expected to contain of a1660 @c number of integers separated by #\. characters. The method is not1661 @c recursive. The component satisfies the version dependency if it has1662 @c the same major number as required and each of its sub-versions is1663 @c greater than or equal to the sub-version number required.1664 1665 @c @lisp1666 @c (defun version-satisfies (x y)1667 @c (labels ((bigger (x y)1668 @c (cond ((not y) t)1669 @c ((not x) nil)1670 @c ((> (car x) (car y)) t)1671 @c ((= (car x) (car y))1672 @c (bigger (cdr x) (cdr y))))))1673 @c (and (= (car x) (car y))1674 @c (or (not (cdr y)) (bigger (cdr x) (cdr y))))))1675 @c @end lisp1676 1677 @c If that doesn't work for your system, you can override it. I hope1678 @c you have as much fun writing the new method as @verb{|#lisp|} did1679 @c reimplementing this one.1680 @c @end deffn1681 1682 @c @deffn Operation feature-dependent-op1683 1684 @c An instance of @code{feature-dependent-op} will ignore any components1685 @c which have a @code{features} attribute, unless the feature combination1686 @c it designates is satisfied by @code{*features*}. This operation is1687 @c not intended to be instantiated directly, but other operations may1688 @c inherit from it.1689 1690 @c @end deffn1691 1659 1692 1660 @node Creating new operations, , Predefined operations of ASDF, Operations … … 1883 1851 @cindex :version 1884 1852 1885 This optional attribute is used by the generic function 1886 @code{version-satisfies}, which tests to see if @code{:version} 1887 dependencies are satisfied. 1888 the version should be a string of integers separated by dots, 1853 This optional attribute specifies a version for the current component. 1854 The version should typically be a string of integers separated by dots, 1889 1855 for example @samp{1.0.11}. 1890 For more information on the semantics of version specifiers, see @ref{The defsystem grammar}. 1891 1892 @c This optional attribute is intended to be used by the @code{test-system-version} operation. 1893 @c @xref{Predefined operations of ASDF}. 1894 @c @emph{Nota Bene}: 1895 @c This operation, planned for ASDF 1, 1896 @c is still not implemented yet as of ASDF 3. 1897 @c Don't hold your breath. 1898 1899 1856 For more information on version specifiers, see @ref{The defsystem grammar}. 1857 1858 A version may then be queried by the generic function @code{version-satisfies}, 1859 to see if @code{:version} dependencies are satisfied, 1860 and when specifying dependencies, a constraint of minimal version to satisfy 1861 can be specified using e.g. @code{(:version "mydepname" "1.0.11")}. 1862 1863 Note that in the wild, we typically see version numbering 1864 only on components of type @code{system}. 1865 Presumably it is much less useful within a given system, 1866 wherein the library author is responsible to keep the various files in synch. 1900 1867 1901 1868 @subsubsection Required features 1902 1869 1903 @emph{FIXME: This subsection seems to contradict the 1904 @code{defsystem} grammar subsection, 1905 which doesn't provide any obvious way to specify required features. 1906 Furthermore, in 2009, discussions on the 1907 @url{http://common-lisp.net/cgi-bin/mailman/listinfo/asdf-devel,asdf-devel mailing list} 1908 suggested that the specification of required features may be broken, 1909 and that no one may have been using them for a while. 1910 Please contact the 1911 @url{http://common-lisp.net/cgi-bin/mailman/listinfo/asdf-devel,asdf-devel mailing list} 1912 if you are interested in getting this features feature fixed.} 1913 1914 Traditionally defsystem users have used reader conditionals 1870 Traditionally defsystem users have used @code{#+} reader conditionals 1915 1871 to include or exclude specific per-implementation files. 1916 1872 This means that any single implementation cannot read the entire system, … … 1919 1875 as it will omit to process the system-dependent sources for other systems. 1920 1876 1921 Each component in an asdf system may therefore specify features using 1922 the same syntax as @code{#+} does, and it will (somehow) be ignored for 1923 certain operations unless the feature conditional is a member of 1924 @code{*features*}. 1925 1877 Each component in an asdf system may therefore specify using @code{:if-feature} 1878 a feature expression using the same syntax as @code{#+} does, 1879 such that any reference to the component will be ignored 1880 during compilation, loading and/or linking if the expression evaluates to false. 1881 Since the expression is read by the normal reader, 1882 you must explicitly prefix your symbols with @code{:} so they be read as keywords; 1883 this is as contrasted with the @code{#+} syntax 1884 that implicitly reads symbols in the keyword package by default. 1885 1886 For instance, @code{:if-feature (:and :x86 (:or :sbcl :cmu :scl))} specifies that 1887 the given component is only to be compiled and loaded 1888 when the implementation is SBCL, CMUCL or Scieneer CL on an x86 machine. 1889 You can not write it as @code{:if-feature (and x86 (or sbcl cmu scl))} 1890 since the symbols would presumably fail to be read as keywords. 1926 1891 1927 1892 @subsubsection Dependencies … … 1953 1918 1954 1919 @verbatim 1955 (this-op {(other-op required-components)}+)1920 (this-op @{(other-op required-components)@}+) 1956 1921 1957 1922 simple-component-name := string … … 2006 1971 @c Doesn't CLISP now support LIST method combination? 2007 1972 2008 See the discussion of the semantics of @code{:version} in the defsystem 2009 grammar. 1973 A minimal version can be specified for a component you depend on 1974 (typically another system), by specifying @code{(:version "other-system" "1.2.3")} 1975 instead of simply @code{"other-system"} as the dependency. 1976 See the discussion of the semantics of @code{:version} 1977 in the defsystem grammar. 2010 1978 2011 1979 @c FIXME: Should have cross-reference to "Version specifiers" in the … … 2173 2141 @deffn version-satisfies @var{version} @var{version-spec} 2174 2142 Does @var{version} satisfy the @var{version-spec}. A generic function. 2175 ASDF provides built-in methods for @var{version} being a 2176 @code{component} or @code{string}. @var{version-spec} should be a 2177 string. 2178 2179 In the wild, we typically see version numbering only on components of 2180 type @code{system}. 2181 2182 For more information about how @code{version-satisfies} interprets 2183 version strings and specifications, @pxref{The defsystem grammar} and 2143 ASDF provides built-in methods for @var{version} being a @code{component} or @code{string}. 2144 @var{version-spec} should be a string. 2145 If it's a component, its version is extracted as a string before further processing. 2146 2147 A version string satisfies the version-spec if after parsing, 2148 the former is no older than the latter. 2149 Therefore @code{"1.9.1"}, @code{"1.9.2"} and @code{"1.10"} all satisfy @code{"1.9.1"}, 2150 but @code{"1.8.4"} or @code{"1.9"} do not. 2151 For more information about how @code{version-satisfies} parses and interprets 2152 version strings and specifications, 2153 @pxref{The defsystem grammar} (version specifiers) and 2184 2154 @ref{Common attributes of components}. 2155 2156 Note that in versions of ASDF prior to 3.0.1, 2157 including the entire ASDF 1 and ASDF 2 series, 2158 @code{version-satisfies} would also require that the version and the version-spec 2159 have the same major version number (the first integer in the list); 2160 if the major version differed, the version would be considered as not matching the spec. 2161 But that feature was not documented, therefore presumably not relied upon, 2162 whereas it was a nuisance to several users. 2163 Starting with ASDF 3.0.1, 2164 @code{version-satisfies} does not treat the major version number specially, 2165 and returns T simply if the first argument designates a version that isn't older 2166 than the one specified as a second argument. 2167 If needs be, the @code{(:version ...)} syntax for specifying dependencies 2168 could be in the future extended to specify an exclusive upper bound for compatible versions 2169 as well as an inclusive lower bound. 2185 2170 @end deffn 2186 2171 … … 2584 2569 and for XCVB the corresponding functions are in package XCVB. 2585 2570 2586 @defun initialize-source-registry @ &optional PARAMETER2571 @defun initialize-source-registry @Aoptional PARAMETER 2587 2572 will read the configuration and initialize all internal variables. 2588 2573 You may extend or override configuration … … 2609 2594 @end defun 2610 2595 2611 @defun ensure-source-registry @ &optional PARAMETER2596 @defun ensure-source-registry @Aoptional PARAMETER 2612 2597 checks whether a source registry has been initialized. 2613 2598 If not, initialize it with the given @var{PARAMETER}. … … 2829 2814 we provide a limited emulation mode: 2830 2815 2831 @defun enable-asdf-binary-locations-compatibility @ &key centralize-lisp-binaries default-toplevel-directory include-per-user-information map-all-source-files source-to-target-mappings2816 @defun enable-asdf-binary-locations-compatibility @Akey centralize-lisp-binaries default-toplevel-directory include-per-user-information map-all-source-files source-to-target-mappings 2832 2817 This function will initialize the new @code{asdf-output-translations} facility in a way 2833 2818 that emulates the behavior of the old @code{ASDF-Binary-Locations} facility. … … 3072 3057 The specified functions are exported from package ASDF. 3073 3058 3074 @defun initialize-output-translations @ &optional PARAMETER3059 @defun initialize-output-translations @Aoptional PARAMETER 3075 3060 will read the configuration and initialize all internal variables. 3076 3061 You may extend or override configuration … … 3103 3088 @end defun 3104 3089 3105 @defun ensure-output-translations @ &optional PARAMETER3090 @defun ensure-output-translations @Aoptional PARAMETER 3106 3091 checks whether output translations have been initialized. 3107 3092 If not, initialize them with the given @var{PARAMETER}. … … 3402 3387 Please use ASDF-UTILS for the same functions exported from a stable library. 3403 3388 3404 @defun coerce-pathname name @ &key type defaults3389 @defun coerce-pathname name @Akey type defaults 3405 3390 3406 3391 This function (available starting with ASDF 2.012.11) … … 3422 3407 @end defun 3423 3408 3424 @defun merge-pathnames* @ &key specified defaults3409 @defun merge-pathnames* @Akey specified defaults 3425 3410 3426 3411 This function is a replacement for @code{merge-pathnames} that uses the host and device … … 3432 3417 @end defun 3433 3418 3434 @defun system-relative-pathname system name @ &key type3419 @defun system-relative-pathname system name @Akey type 3435 3420 3436 3421 It's often handy to locate a file relative to some system. -
trunk/abcl/src/org/armedbear/lisp/asdf.lisp
r14487 r14502 1 1 ;;; -*- mode: Common-Lisp; Base: 10 ; Syntax: ANSI-Common-Lisp -*- 2 ;;; This is ASDF 2.33.7: Another System Definition Facility.2 ;;; This is ASDF 3.0.1: Another System Definition Facility. 3 3 ;;; 4 4 ;;; Feedback, bug reports, and patches are all welcome: … … 4030 4030 (with-upgradability () 4031 4031 (defgeneric slurp-input-stream (processor input-stream &key &allow-other-keys)) 4032 4032 4033 4033 #-(or gcl2.6 genera) 4034 4034 (defmethod slurp-input-stream ((function function) input-stream &key &allow-other-keys) … … 5019 5019 (:recycle :uiop/configuration :asdf/configuration :asdf) 5020 5020 (:use :uiop/common-lisp :uiop/utility 5021 :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image )5021 :uiop/os :uiop/pathname :uiop/filesystem :uiop/stream :uiop/image :uiop/lisp-build) 5022 5022 (:export 5023 5023 #:get-folder-path … … 5245 5245 ((eql :home) (user-homedir-pathname)) 5246 5246 ((eql :here) (resolve-absolute-location 5247 *here-directory* :ensure-directory t :wilden nil)) 5247 (or *here-directory* (pathname-directory-pathname (load-pathname))) 5248 :ensure-directory t :wilden nil)) 5248 5249 ((eql :user-cache) (resolve-absolute-location 5249 5250 *user-cache* :ensure-directory t :wilden nil))) … … 5421 5422 ;; "3.4.5.0.8" would be your eighth local modification of official release 3.4.5 5422 5423 ;; "3.4.5.67.8" would be your eighth local modification of development version 3.4.5.67 5423 (asdf-version " 2.33.7")5424 (asdf-version "3.0.1") 5424 5425 (existing-version (asdf-version))) 5425 5426 (setf *asdf-version* asdf-version) … … 5782 5783 5783 5784 (defmethod version-satisfies ((cver string) version) 5784 (version -compatible-p cver version)))5785 (version<= version cver))) 5785 5786 5786 5787 … … 8565 8566 |# 8566 8567 8568 #+(or ecl mkcl) 8569 (with-upgradability () 8570 (defun uiop-library-file () 8571 (or (and (find-system :uiop nil) 8572 (system-source-directory :uiop) 8573 (progn 8574 (operate 'lib-op :uiop) 8575 (output-file 'lib-op :uiop))) 8576 (resolve-symlinks* (c::compile-file-pathname "sys:asdf" :type :lib)))) 8577 (defmethod input-files :around ((o program-op) (c system)) 8578 (let ((files (call-next-method)) 8579 (plan (traverse-sub-actions o c :plan-class 'sequential-plan))) 8580 (unless (or (and (find-system :uiop nil) 8581 (system-source-directory :uiop) 8582 (plan-operates-on-p plan '("uiop"))) 8583 (and (system-source-directory :asdf) 8584 (plan-operates-on-p plan '("asdf")))) 8585 (pushnew (uiop-library-file) files :test 'pathname-equal)) 8586 files)) 8587 8588 (defun register-pre-built-system (name) 8589 (register-system (make-instance 'system :name (coerce-name name) :source-file nil)))) 8590 8567 8591 #+ecl 8568 8592 (with-upgradability () … … 8598 8622 (declare (ignore force verbose version)) 8599 8623 (apply #'operate 'binary-op system args))) 8600 8601 #+(or ecl mkcl)8602 (with-upgradability ()8603 (defun register-pre-built-system (name)8604 (register-system (make-instance 'system :name (coerce-name name) :source-file nil))))8605 8606 8624 ;;;; ------------------------------------------------------------------------- 8607 8625 ;;;; Concatenate-source … … 9013 9031 (asdf/package:define-package :asdf/backward-interface 9014 9032 (:recycle :asdf/backward-interface :asdf) 9015 (:use : asdf/common-lisp :asdf/driver:asdf/upgrade9033 (:use :uiop/common-lisp :uiop :asdf/upgrade 9016 9034 :asdf/component :asdf/system :asdf/find-system :asdf/operation :asdf/action 9017 :asdf/lisp- build:asdf/operate :asdf/output-translations)9035 :asdf/lisp-action :asdf/operate :asdf/output-translations) 9018 9036 (:export 9019 9037 #:*asdf-verbose* … … 9023 9041 #:enable-asdf-binary-locations-compatibility 9024 9042 #:operation-forced 9025 #:operation-on-failure 9026 #:operation-on-warnings 9043 #:operation-on-failure #:operation-on-warnings #:on-failure #:on-warnings 9027 9044 #:component-property 9028 9045 #:run-shell-command
Note: See TracChangeset
for help on using the changeset viewer.