/[cl-xml]/trunk/sysdcl.lisp
ViewVC logotype

Contents of /trunk/sysdcl.lisp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 4 - (show annotations)
Mon Feb 13 17:05:21 2006 UTC (8 years, 2 months ago) by banderson
File size: 14948 byte(s)
commit of release 0.949, and all patches, through 20040211
1 ;;; -*- Mode: lisp; Syntax: ansi-common-lisp; Base: 10; Package: cl-user; -*-
2
3 #|
4 <DOCUMENTATION>
5 <DESCRIPTION>
6 implementation packages for
7 <ul>
8 <li> XQDM: an xml document model which follows the xml-query document
9 model.</li>
10 <li> XQ: a serializer (parser/reader and writer functions) for the document
11 aspects of xml-query algebra expressions based on the XQDM.</li>
12 <li> XPATH: a parser/reader and interpreter for xpath expressions.</li>
13 <li> XMLP: a parser for xml expressions based onthe XQDM.</li>
14 <!-- <li> XMLP: a compatibility package downwards compatible to the older XMLP
15 package.</li> was considered, but not implemented -->
16 </ul>
17 </DESCRIPTION>
18 <COPYRIGHT YEAR='2001' AUTHOR='james adam anderson' MARK='(C)'
19 mailto='james.anderson@setf.de' />
20 <LICENSE href='file://xml/LGPL.txt' >
21 This library is free software;
22 With the exceptions noted below, you can redistribute it and/or
23 modify it under the terms of the GNU Lesser General Public
24 License as published by the Free Software Foundation; either
25 version 2.1 of the License, or (at your option) any later version,
26 as ammended below.
27
28 This library is distributed in the hope that it will be useful,
29 but WITHOUT ANY WARRANTY; without even the implied warranty of
30 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
31 Lesser General Public License for more details.
32
33 You should have received a copy of the GNU Lesser General Public
34 License along with this library; if not, write to the Free Software
35 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
36
37 The terms of the GNU Lesser General Public License are ammended to include
38 the stipulation, as paragraph 2.e, that any modifications to the library for
39 the purpose of correcting bugs must be returned to the copyright holder
40 for inclusion in future versions of the library.
41 </LICENSE>
42 <LICENSE href='file://xml/base/tokenizer.lisp'>
43 the license terms for tokenizer implementation are described in the
44 respective source file.
45 </LICENSE>
46 <LICENSE href='file://xml/bnf/xml-grammar.bnf'>
47 the www-consortium retains license rights to the respective bnf.
48 it is distributed herewith under the terms of their software license.</LICENSE>
49 <LICENSE href='file://xml/bnf/xpath-grammar.bnf'>
50 the www-consortium retains license rights to the respective bnf.
51 it is distributed herewith under the terms of their software license.</LICENSE>
52 <LICENSE href='file://xml/bnf/xql-grammar.bnf'>
53 the www-consortium retains license rights to the respective bnf.
54 it is distributed herewith under the terms of their software license.</LICENSE>
55 <LICENSE href='file://xml/demos/saxandsoap/*.lisp'>
56 <COPYRIGHT YEAR='2001' AUTHOR='Stanley Knutson' MARK='(C)'
57 mailto='knewt@alum.mit.edu' />
58 for information on this module, please contact the author.</LICENSE>
59 <CHRONOLOGY>
60 <!-- nb. this version number tracks that of the 'parser' module.
61 the others vary independently. -->
62 <DELTA DATE='20010605' AUTHOR='MS' VERSION='0.907'>
63 lispworks/ansi conformance</DELTA>
64 <DELTA DATE='20010608' VERSION='0.908'>
65 CL-HTTP in ALLEGRO</DELTA>
66 <DELTA DATE='20010621'>xml-writer</DELTA>
67 <DELTA DATE='20010702'>vector-stream moved to utils for data-url support</DELTA>
68 <DELTA DATE='20010910' VERSION='0.912'>xparser tokenizers</DELTA>
69 <DELTA DATE='20010910' VERSION='0.914'>0.912+lw/allegro tests</DELTA>
70 <DELTA DATE='20010918' VERSION='0.915'>first-level tokenization</DELTA>
71 <DELTA DATE='20011203' VERSION='0.916'>fixes for instance name compilation;<br />
72 lispworks comm package(including conditionalization 20020115)</DELTA>
73 <DELTA DATE='20020117'>lispworks charachter element set for two-byte characters</DELTA>
74 <DELTA DATE='20030408' VERSION='0.949'>
75 </CHRONOLOGY>
76 </DOCUMENTATION>
77 |#
78
79 (in-package "CL-USER")
80
81 (eval-when (:load-toplevel :compile-toplevel :execute)
82 (let* ((defaults
83 #+allegro (or *load-truename* *load-pathname* *compile-file-truename*)
84 #+ccl *load-truename*
85 #+cmu *load-truename*
86 #+cormanlisp #p"d:\\Source\\Lisp\\XML-0-918\\sysdcl.lisp"
87 #+lispWorks (truename (lw:current-pathname))
88 #+sbcl (or *load-truename* *load-pathname*)
89 )
90 (bin-target nil)
91 (root-target (make-pathname :name :wild :type :wild :version :newest
92 :directory (append (pathname-directory defaults)
93 '(:wild-inferiors))
94 :defaults defaults)))
95 ;; w/o bootstrap lispworks collapsed the bin target to host and type
96 (setf (logical-pathname-translations "xml")
97 `(("root;**;*.*.*" ,root-target)))
98 (setf bin-target
99 (make-pathname :name :wild
100 :type (pathname-type (compile-file-pathname "xml:name.lisp"))
101 :version :newest
102 :defaults
103 #+digitool "xml:root;bin;digifasl;**;*.*.*"
104 #+(and mcl m68k) "xml:root;bin;digim68kfasl;**;*.*.*"
105 #+(and allegro allegro-version>= (not (version>= 6 0))) "xml:root;bin;acl5fasl;**;*.*.*"
106 #+(and allegro allegro-version>= (version>= 6 0)) "xml:root;bin;acl6fasl;**;*.*.*"
107 #+(and lispworks (not mac)) "xml:root;bin;lwfasl;**;*.*.*"
108 #+(and lispworks mac) "xml:root;bin;lwppcfasl;**;*.*.*"
109 #+cormanlisp "xml:root;bin;corfasl;**;*.*.*"
110 #+openmcl "xml:root;bin;omclfasl;**;*.*.*"
111 #+cmu "xml:root;bin;cmuclfasl;**;*.*.*"
112 #+sbcl "xml:root;bin;sbclfasl;**;*.*.*"
113 ))
114 (when *load-verbose*
115 (format *trace-output* "~%load defaults: ~s.~%compile target: ~s."
116 defaults bin-target))
117 (setf (logical-pathname-translations "xml")
118 `(("**;*.bin.*" ,bin-target)
119 ("**;*.BIN.*" ,bin-target)
120 ("code;**;*.*.*" "xml:root;code;**;*.*.*")
121 ("root;**;*.*.*" ,root-target)
122 ("**;*.bnf.*" "xml:root;bnf;*.*.*")
123 ("**;*.BNF.*" "xml:root;bnf;*.*.*")
124 ("**;*.*.*" "xml:root;**;*.*.*")))
125
126 (unless (ignore-errors (LOGICAL-PATHNAME-TRANSLATIONS "Packages"))
127 (setf (logical-pathname-translations "Packages")
128 `(("**;*.bin.*" ,bin-target)
129 ("**;*.BIN.*" ,bin-target)
130 ("**;*.*.*" "xml:Library;**;*.*")
131 ("*.*.*" "xml:Library;**;*.*"))))
132 ))
133
134 ;; configuration
135 ;;
136
137 #+CL-HTTP ;; nb. this check is effective in the fasl only
138 (unless (find :cl-http *features*)
139 (warn "CL-HTTP not present."))
140
141 ;;
142 ;; network access
143 #+(and MCL (not CL-HTTP) (not openmcl))
144 (eval-when (:compile-toplevel :load-toplevel :execute)
145 (define-declaration values nil)
146 (define-declaration arglist nil)
147 (require "OPENTRANSPORT"))
148
149 #+openmcl
150 (progn
151 (define-declaration values nil)
152 (define-declaration arglist nil))
153
154 #+(and ALLEGRO (not CL-HTTP))
155 (eval-when (:compile-toplevel :load-toplevel :execute)
156 (require "SOCK"))
157 #+LispWorks
158 (eval-when (:compile-toplevel :load-toplevel :execute)
159 (require "comm"))
160
161 ;; to indicate whether or not to model names as symbols or as instances
162 ;; (pushnew :xml-symbols *features*)
163
164 ;; to specify the instance names should use tokenizers
165 (pushnew :nameset-tokenizer *features*)
166
167 ;; to indicate that all name and string characters are to be checked for legality
168 ;; (pushnew :xml-check-char-codes *features*)
169 #+Allegro
170 (when (< excl:real-char-code-limit 65535)
171 (pushnew :xml-check-char-codes *features*))
172
173 #-Allegro
174 (when (< char-code-limit 65535)
175 (pushnew :xml-check-char-codes *features*))
176
177 #|
178 ;; 20020410.jaa setting the value globally turns out to be inappropriate.
179 ;; the alternative, dynamical binding, is said to be insufficient to affect internal
180 ;; state.
181 #+LispWorks
182 (lw:set-default-character-element-type 'lw:simple-char)
183
184 ;; should that change, the alternative would have been
185 #+LispWorks ; cause lispworks to use wide-character strings
186 (lw:*default-character-element-type* 'lw:simple-char)
187 |#
188
189 #+cmu
190 (progn
191 (require :gray-streams)
192 (setq extensions:*inline-expansion-limit* 2)
193 )
194
195 #+sbcl
196 (progn
197 (require :gray-streams)
198 (setq *inline-expansion-limit* 2)
199 )
200
201 #+ccl-5-0-and-0-918
202 (setq CCL::*CHECK-SLOT-TYPE* nil)
203 ;; the atn-bnf parser must be loaded in order to translate grammars,
204 ;; for regular expressions, and for validation. this is reflected in it presence
205 ;; in the :xparser definition below.
206 ;; nb. this should be refined to load only the minimum for runtime use
207
208 (eval-when (:compile-toplevel :execute :load-toplevel)
209
210 (define-system
211 (:base)
212 ()
213 "xml:code;patch;cmucl"
214 "xml:library;de;setf;utility;package"
215 "xml:library;de;setf;utility;string"
216 "xml:library;de;setf;utility;conditions"
217 "xml:library;de;setf;utility;test"
218 "xml:code;base;package"
219 )
220
221 (define-system
222 (:bnfp)
223 ()
224 :base
225 ; merged into common package file "xml:code;packages;atn-package"
226 "xml:code;atn-parser;clifs;inference-system-classes"
227 "xml:code;atn-parser;clifs;inference-units"
228 "xml:code;atn-parser;atn-parameters"
229 "xml:code;atn-parser;atn-classes"
230 "xml:code;atn-parser;atn-macros"
231 "xml:code;atn-parser;ebnf-tokenizer"
232 "xml:code;atn-parser;ebnf-to-atn-translator"
233 "xml:code;atn-parser;atn-macro-to-canonic-form"
234 "xml:code;atn-parser;ebnf-grammar.atn" ;; the bnf grammar is coded in a "atn" syntax lisp file.
235 "xml:code;atn-parser;atn-runtime"
236 "xml:code;atn-parser;conditions"
237 "xml:code;atn-parser;atn-lisp-compiler"
238 "xml:code;atn-parser;atn-regex"
239 ;; the java translator is present here as documentation, as of 20010208 it has
240 ;; not been reintegrated with the changes to compile to lisp.
241 #+bnfp-java "xml:code;atn-parser;atn-java-compiler"
242 )
243
244 (define-system
245 (:xutil :description "xml base utilities")
246 ()
247 :bnfp
248 "xml:code;base;parameters"
249 "xml:code;base;cllib"
250 #+CL-HTTP "xml:code;base;cl-http-utils"
251 "xml:code;base;utils"
252 "xml:code;base;parsetable"
253 "xml:code;base;vector-stream"
254 #-CL-HTTP "xml:code;base;www-utils-ersatz"
255 #-CL-HTTP "xml:code;base;tokenizer"
256 "xml:code;base;conditions")
257
258 (define-system
259 (xqdm :description "model from the x-query data model")
260 ()
261 :xutil
262 ;; for 0.918 namespaces operations must be defined first
263 "xml:code;xquerydatamodel;xqdm-namespaces"
264 "xml:code;xquerydatamodel;xqdm-parameters"
265 "xml:code;xquerydatamodel;xqdm-character-classes"
266 "xml:code;xquerydatamodel;xqdm-classes"
267 "xml:code;xquerydatamodel;xsd-types"
268 "xml:code;xquerydatamodel;conditions;names;conditions"
269 "xml:code;xquerydatamodel;conditions;node;conditions"
270 "xml:code;xquerydatamodel;conditions;model;conditions"
271 "xml:code;xquerydatamodel;xqdm-operators"
272 ;; "xml:code;xquerydatamodel;xqdm-qnames"
273 "xml:code;xquerydatamodel;xqdm-validation"
274 "xml:code;xquerydatamodel;qname-resolution"
275 "xml:code;xquerydatamodel;xqdm-graph"
276 "xml:code;xquerydatamodel;node-path-walk"
277 "xml:code;xquerydatamodel;xqdm-walk"
278 "xml:code;xquerydatamodel;xqdm-walk-accessors")
279
280 (define-system
281 (xparser :description "xml processor: parsing/serialization for xqdm with standard encoding")
282 ()
283 :xutil :xqdm
284 "xml:code;xparser;xml-parameters"
285 "xml:code;xparser;conditions;codec;conditions"
286 "xml:code;xparser;xml-stream-coding"
287 "xml:code;xparser;xml-operators"
288 "xml:code;xparser;xml-readers"
289 "xml:code;xparser;xml-tokenizer"
290 "xml:code;xparser;xml-processing-instruction"
291 "xml:code;xparser;xml-constructors"
292 "xml:code;xparser;xml-parser"
293 "xml:code;xparser;xml-printer"
294 "xml:code;xparser;xml-writer")
295
296 (define-system
297 (:xpath :description "xml path model and encoding to extend the processor")
298 ()
299 :xparser
300 "xml:code;xpath;xpath-parameters"
301 "xml:code;xpath;xpath-tokenizer"
302 "xml:code;xpath;xpath-classes"
303 "xml:code;xpath;xpath-operators"
304 "xml:code;xpath;xpath-constructors"
305 "xml:code;xpath;xpath-parser"
306 "xml:code;xpath;xpath-printer"
307 "xml:code;xpath;xpath-library")
308
309 (define-system
310 (:xquery :description "xml query processor based on xml processor and xml path")
311 ()
312 :xparser :xpath
313 "xml:code;xquery;xq-parameters"
314 "xml:code;xquery;xqa-classes"
315 "xml:code;xquery;xqa-operators"
316 "xml:code;xquery;xql-operators"
317 "xml:code;xquery;xqa-library"
318 "xml:code;xquery;xql-library"
319 "xml:code;xquery;xql-tokenizer"
320 "xml:code;xquery;xql-constructors"
321 "xml:code;xquery;xql-parser"
322 "xml:code;xquery;xq-printer"
323 )
324
325 (define-system
326 (:xtests
327 :description
328 "loads test files")
329 ()
330 :xparser
331
332 "xml:tests;xquerydatamodel;model"
333
334 "xml:tests;parser;bom"
335 "xml:tests;parser;document-internal"
336 "xml:tests;parser;document-external"
337 "xml:tests;parser;document-specialized"
338 "xml:tests;parser;qnames.lisp"
339 "xml:tests;parser;validation.lisp"
340 "xml:tests;parser;namespaces.lisp"
341 "xml:tests;parser;oasis.lisp"
342 )
343
344 (define-system
345 (:xrelease
346 :description
347 "loads test files")
348 ()
349 :xtests
350 "xml:code;base;release"
351 "xml:*.lisp"
352 "xml:demos;**;*.*"
353 "xml:library;define-system.lisp"
354 "xml:**;*.bnf"
355 "xml:**;*.htm"
356 "xml:**;*.gif"
357 "xml:**;*.xql"
358 "xml:**;*.xml*"
359 "xml:**;*.dtd"
360 "xml:**;*.xmlq"
361 "xml:**;*.txt"
362 )
363
364 (define-system
365 (:xconformance
366 :description
367 "incorporates conformance data files")
368 ()
369 "xml:standards;XML;XMLConf;**;*.xml"
370 "xml:standards;XML;XMLConf;**;*.mod"
371 "xml:standards;XML;XMLConf;**;*.dtd"
372 "xml:standards;XML;XMLConf;**;*.ent"
373 "xml:standards;XML;REC-xml-20001006.xml"
374 "xml:standards;XML;xmlspec-v21.dtd"
375 "xml:standards;XML;W3CSchema;*.xsd"
376 "xml:standards;XML;W3CSchema;*.dtd"
377 "xml:standards;XML;XHTML-MODULAR;**;*.*"
378 )
379 )
380
381
382 ;; see also xml:tests;test.lisp
383 ;; (load "entwicklung@paz:sourceServer:lisp:xml:define-system.lisp")
384 ;; (register-system-definition :xparser "entwicklung@paz:sourceServer:lisp:xml:sysdcl.lisp")
385 ;; (execute-system-operations :xutil '(:load))
386 ;; (execute-system-operations :xparser '(:load))
387
388 ;; to test if the pathnames are ok.
389 ;; (execute-system-operations :xparser '(:probe))
390
391 ;; to load
392 ;; (execute-system-operations :xparser '(:load))
393 ;; (execute-system-operations :xquery '(:load))
394
395 ;; to compile / load
396 ;; (execute-system-operations :xparser '(:compile))
397 ;; (execute-system-operations :xparser '(:compile :load))
398 ;; (execute-system-operations :xquery '(:compile :load))
399
400 ;; (execute-system-operations :xquery #'print)
401
402 ;; (translate-logical-pathname "xml:xxx;yyy;xml-grammar.bnf")
403 ;; (translate-logical-pathname "xml:bnfp;sysdcl")
404 ;; (translate-logical-pathname "xml:code;xquery;xq-printer.lisp")
405 ;; (translate-logical-pathname "xml:code;xquery;xq-printer.bin")
406 ;; (translate-logical-pathname "xml:demo;xq-printer.lisp")
407 ;; (translate-logical-pathname "xml:demo;xq-printer.bin")
408
409 :EOF

  ViewVC Help
Powered by ViewVC 1.1.5