| 1 | ASDF-JAR | 
|---|
| 2 | ======== | 
|---|
| 3 |  | 
|---|
| 4 | ASDF-JAR provides a system for packaging ASDF systems into jar | 
|---|
| 5 | archives for ABCL.  Given a running ABCL image with loadable ASDF | 
|---|
| 6 | systems the code in this package will recursively package all the | 
|---|
| 7 | required source and fasls in a jar archive . | 
|---|
| 8 |  | 
|---|
| 9 | To install ASDF systems, [Quicklisp]() is probably the best | 
|---|
| 10 | contemporary solution, although a version of ASDF-INSTALL is also | 
|---|
| 11 | packaged in ABCL contribs. | 
|---|
| 12 |  | 
|---|
| 13 | [Quicklisp]: http://www.quicklisp.org | 
|---|
| 14 |  | 
|---|
| 15 | Once the requisite ASDF systems have been installed, ensure that this | 
|---|
| 16 | contrib is loaded via | 
|---|
| 17 |  | 
|---|
| 18 |     CL-USER) (require :abcl-contrib) | 
|---|
| 19 |     CL-USER> (require :asdf-jar) | 
|---|
| 20 |  | 
|---|
| 21 | Then, to say package the Perl regular expression system ("CL-PPCRE"), | 
|---|
| 22 | one uses the ASDF-JAR:PACKAGE as follows: | 
|---|
| 23 |  | 
|---|
| 24 |     CL-USER> (asdf-jar:package :cl-ppcre) | 
|---|
| 25 |     ;  Loading #P"/home/evenson/quicklisp/dists/quicklisp/software/cl-ppcre-2.0.3/cl-ppcre.asd" ... | 
|---|
| 26 |     ;  Loaded #P"/home/evenson/quicklisp/dists/quicklisp/software/cl-ppcre-2.0.3/cl-ppcre.asd" (0.029 seconds) | 
|---|
| 27 |     Packaging ASDF definition of #<ASDF:SYSTEM "cl-ppcre"> | 
|---|
| 28 |      as /var/tmp/cl-ppcre-all-2.0.3.jar. | 
|---|
| 29 |     Packaging contents in /var/tmp/cl-ppcre-all-2.0.3.jar | 
|---|
| 30 |      with recursive dependencies. | 
|---|
| 31 |     #P"/var/tmp/cl-ppcre-all-2.0.3.jar" | 
|---|
| 32 |  | 
|---|
| 33 | The resulting jar contains all source and fasls required to run the | 
|---|
| 34 | ASDF system including any transitive ASDF dependencies.  Each asdf | 
|---|
| 35 | system is packaged under its own top level directory within the jar | 
|---|
| 36 | archive.  The jar archive itself is numbered with the version of the | 
|---|
| 37 | system that was specified in the packaging. | 
|---|
| 38 |  | 
|---|
| 39 | To load the system from the jar one needs to add the ASDF file | 
|---|
| 40 | locations to the ASDF *CENTRAL-REGISTRY*.  If one wishes to load the | 
|---|
| 41 | fasls from the jar alone, one needs to tell ASDF not to override its | 
|---|
| 42 | output translation rules.  The function ASDF-JAR:ADD-TO-JAR does both | 
|---|
| 43 | of these options serving as the basis for customized load strategies | 
|---|
| 44 | tailored to end-user deployment needs.  So, after | 
|---|
| 45 |  | 
|---|
| 46 |     CL-USER> (asdf-jar:add-to-asdf "/var/tmp/cl-ppcre-all-2.0.3.jar") | 
|---|
| 47 |  | 
|---|
| 48 | a subsequent | 
|---|
| 49 |  | 
|---|
| 50 |     CL-USER> (asdf:load-system :cl-ppcre) | 
|---|
| 51 |  | 
|---|
| 52 | should load the ASDF system from the jar. | 
|---|
| 53 |  | 
|---|
| 54 | Setting CL:*LOAD-VERBOSE* will allow one to verify that the subsequent | 
|---|
| 55 | load is indeed coming from the jar. | 
|---|
| 56 |  | 
|---|
| 57 | # Colophon | 
|---|
| 58 |  | 
|---|
| 59 | Mark Evenson | 
|---|
| 60 | Created: 20-JUN-2011 | 
|---|
| 61 | Modified: 20-JUN-2011 | 
|---|
| 62 | <> abcl:documents <release#asdf-jar> . | 
|---|