0.7.1.23:
[sbcl.git] / build-order.lisp-expr
1 ;;;; -*- Lisp -*-
2
3 ;;;; This software is part of the SBCL system. See the README file for
4 ;;;; more information.
5 ;;;;
6 ;;;; This software is derived from the CMU CL system, which was
7 ;;;; written at Carnegie Mellon University and released into the
8 ;;;; public domain. The software is in the public domain and is
9 ;;;; provided with absolutely no warranty. See the COPYING and CREDITS
10 ;;;; files for more information.
11
12 ;;; a linear ordering of system sources which works both to compile/load
13 ;;; the cross-compiler under the host Common Lisp and then to cross-compile
14 ;;; the complete system into the under-construction target SBCL
15 ;;;
16 ;;; Of course, it'd be very nice to have this be a dependency DAG
17 ;;; instead, so that we could do automated incremental recompilation.
18 ;;; But the dependencies are varied and subtle, and it'd be extremely
19 ;;; difficult to extract them automatically, and it'd be extremely
20 ;;; tedious and error-prone to extract them manually, so we don't 
21 ;;; extract them. (It would be nice to fix this someday. The most
22 ;;; feasible approach that I can think of would be to make the
23 ;;; dependencies work on a package level, not an individual file
24 ;;; level. Doing it at the package level would make the granularity
25 ;;; coarse enough that it would probably be pretty easy to maintain
26 ;;; the dependency information manually, and the brittleness of the
27 ;;; package system would help make most violations of the declared
28 ;;; dependencies obvious at build time. -- WHN 20000803
29 (
30  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
31  ;;; miscellaneous
32
33  ;; This comes early because it's useful for debugging everywhere.
34  ("src/code/show")
35
36  ;; This comes early because the cross-compilation host's backquote
37  ;; logic can expand into something which can't be executed on the
38  ;; target Lisp (e.g. in CMU CL where it expands into internal
39  ;; functions like BACKQ-LIST), and by replacing the host backquote
40  ;; logic with our own as early as possible, we minimize the chance of
41  ;; any forms referring to cross-compilation host internal functions
42  ;; leaking into target SBCL code.
43  ("src/code/backq")
44
45  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
46  ;; various DEFSETFs and/or other DEFMACROish things, defined as early as
47  ;; possible so we don't need to fiddle with any subtleties of defining them
48  ;; before any possible use
49
50  ;; KLUDGE: It would be nice to reimplement most or all of these as
51  ;; functions (possibly inlined functions) so that we wouldn't need to
52  ;; worry so much about forcing them all to be defined before any possible
53  ;; use. It might be pretty tedious, though, working through any
54  ;; transforms and translators and optimizers and so forth to make sure
55  ;; that they can handle the change. -- WHN 19990919
56  ("src/code/defsetfs")
57
58  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
59  ;;; cross-compiler-only replacements for stuff which in target Lisp would be
60  ;;; supplied by basic machinery
61
62  ("src/code/cross-misc"  :not-target)
63  ("src/code/cross-float" :not-target)
64  ("src/code/cross-io"    :not-target)
65  ("src/code/cross-sap"   :not-target)
66
67  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
68  ;;; stuff needed early both in cross-compilation host and in target Lisp
69
70  ("src/code/uncross")
71  ("src/code/early-defbangmethod")
72
73  ("src/code/defbangtype")
74  ("src/code/defbangmacro")
75
76  ("src/code/primordial-extensions")
77
78  ;; for various constants e.g. SB!VM:*TARGET-MOST-POSITIVE-FIXNUM* and
79  ;; SB!VM:N-LOWTAG-BITS, needed by "early-objdef" and others
80  ("src/compiler/generic/early-vm")
81  ("src/compiler/generic/early-objdef")
82  ("src/compiler/target/parms")
83  ("src/code/early-array") ; needs "early-vm" numbers
84
85  ("src/code/parse-body")       ; on host for PARSE-BODY
86  ("src/code/parse-defmacro")   ; on host for PARSE-DEFMACRO
87  ("src/code/early-extensions") ; on host for COLLECT, SYMBOLICATE, etc.
88  ("src/compiler/deftype")      ; on host for SB!XC:DEFTYPE
89  ("src/code/early-alieneval")  ; for vars needed both at build and run time
90
91  ("src/code/specializable-array")
92
93  ("src/code/early-cl")
94  ("src/code/early-fasl")
95
96  ;; mostly needed by stuff from comcom, but also used by "x86-vm"
97  ("src/code/debug-var-io")
98
99  ("src/code/cold-init-helper-macros")
100
101  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
102  ;;; basic machinery for the target Lisp. Note that although most of these
103  ;;; files are flagged :NOT-HOST, a few might not be.
104
105  ("src/code/target-defbangmethod" :not-host)
106
107  ("src/code/early-print" :not-host)
108  ("src/code/early-pprint" :not-host)
109  ("src/code/early-impl" :not-host)
110
111  ("src/code/target-extensions" :not-host)
112
113  ("src/code/early-defstructs" :not-host) ; gotta-be-first DEFSTRUCTs
114
115  ("src/code/defbangstruct")
116
117  ("src/code/funutils" :not-host)
118
119  ;; This needs DEF!STRUCT, and is itself needed early so that structure
120  ;; accessors and inline functions defined here can be compiled inline
121  ;; later. (Avoiding full calls not only increases efficiency, but also
122  ;; avoids some cold init issues involving full calls to structure
123  ;; accessors.)
124  ("src/code/type-class")
125
126  ("src/code/pcounter" :not-host)
127
128  ("src/code/ansi-stream" :not-host)
129
130  ("src/code/sysmacs" :not-host)
131
132  ;; "assembly/assemfile" was here in the sequence inherited from
133  ;; CMU CL worldcom.lisp, but also appears later in the sequence
134  ;; inherited from CMU CL comcom.lisp. We shouldn't need two versions,
135  ;; so I've deleted the one here. -- WHN 19990620
136
137  ("src/code/target-error" :not-host)
138
139  ;; a comment from classic CMU CL:
140  ;;   "These guys can supposedly come in any order, but not really.
141  ;;    Some are put at the end so that macros don't run interpreted
142  ;;    and stuff."
143  ;; Dunno exactly what this meant or whether it still holds. -- WHN 19990803
144  ;; FIXME: more informative and up-to-date comment?
145  ("src/code/globals"     :not-host)
146  ("src/code/kernel"      :not-host)
147  ("src/code/toplevel"    :not-host)
148  ("src/code/cold-error"  :not-host)
149  ("src/code/fdefinition" :not-host)
150  ;; FIXME: Figure out some way to make the compiler macro for INFO 
151  ;; available for compilation of "code/fdefinition".
152
153  ;; In classic CMU CL, code/type was here. I've since split that into
154  ;; lots of smaller pieces, some of which are here and some of which
155  ;; are handled later in the sequence, when the cross-compiler is
156  ;; built. -- WHN 19990620
157  ("src/code/target-type" :not-host)
158
159  ("src/code/pred" :not-host)
160
161  ("src/code/target-alieneval" :not-host)
162  ("src/code/target-c-call"    :not-host)
163  ("src/code/target-allocate"  :not-host)
164
165  ;; This needs DEFINE-ALIEN-ROUTINE from target-alieneval.
166  ("src/code/misc-aliens" :not-host)
167
168  ("src/code/array"         :not-host)
169  ("src/code/target-sxhash" :not-host)
170
171  ("src/code/list"   :not-host)
172  ("src/code/seq"    :not-host) ; "code/seq" should come after "code/list".
173  ("src/code/coerce" :not-host)
174
175  ("src/code/string"     :not-host)
176  ("src/code/mipsstrops" :not-host)
177
178  ;; "src/code/unix.lisp" needs this. It's generated automatically by
179  ;; grovel_headers.c, i.e. it's not in CVS.
180  ("output/stuff-groveled-from-headers" :not-host)
181
182  ("src/code/unix" :not-host)
183
184  #!+mach  ("src/code/mach"     :not-host)
185  #!+mach  ("src/code/mach-os"  :not-host)
186  #!+sunos ("src/code/sunos-os" :not-host)
187  #!+hpux  ("src/code/hpux-os"  :not-host)
188  #!+osf1  ("src/code/osf1-os"  :not-host)
189  #!+irix  ("src/code/irix-os"  :not-host)
190  #!+bsd   ("src/code/bsd-os"   :not-host)
191  #!+linux ("src/code/linux-os" :not-host)
192
193  ;; sparc-vm and ppc-vm need sc-offset defined to get at internal
194  ;; error args. This file contains stuff previously in
195  ;; debug-info.lisp.  Should it therefore be :not-host?  -- CSR,
196  ;; 2002-02-05
197  ("src/code/sc-offset")
198  
199  ;; KLUDGE: I'd prefer to have this done with a "code/target" softlink
200  ;; instead of a bunch of reader macros. -- WHN 19990308
201  #!+pmax ("src/code/pmax-vm" :not-host)
202  #!+(and sparc svr4) ("src/code/sparc-svr4-vm" :not-host)
203  #!+(and sparc (not svr4)) ("src/code/sparc-vm" :not-host)
204  #!+rt    ("src/code/rt-vm"    :not-host)
205  #!+hppa  ("src/code/hppa-vm"  :not-host)
206  #!+x86   ("src/code/x86-vm"   :not-host)
207  #!+ppc   ("src/code/ppc-vm"   :not-host)
208  #!+alpha ("src/code/alpha-vm" :not-host)
209  #!+sgi   ("src/code/sgi-vm"   :not-host)
210
211  ("src/code/target-signal" :not-host) ; needs OS-CONTEXT-T from x86-vm
212
213  ("src/code/symbol"     :not-host)
214  ("src/code/bignum"     :not-host)
215  ("src/code/numbers"    :not-host)
216  ("src/code/float-trap" :not-host)
217  ("src/code/float"      :not-host)
218  ("src/code/irrat"      :not-host)
219
220  ("src/code/char")
221  ("src/code/target-char" :not-host)
222  ("src/code/target-misc" :not-host)
223  ("src/code/misc")
224
225  ("src/code/room"   :not-host)
226  ("src/code/gc"     :not-host)
227  ("src/code/purify" :not-host)
228
229  ("src/code/stream"        :not-host)
230  ("src/code/print"         :not-host)
231  ("src/code/pprint"        :not-host)
232  ("src/code/early-format")
233  ("src/code/target-format" :not-host)
234  ("src/code/defpackage"    :not-host)
235  ("src/code/pp-backq"      :not-host)
236
237  ("src/code/error-error" :not-host) ; needs WITH-STANDARD-IO-SYNTAX macro
238
239  ("src/code/serve-event" :not-host)
240  ("src/code/fd-stream"   :not-host)
241
242  ("src/code/module" :not-host)
243
244  ("src/code/interr" :not-host)
245
246  ("src/code/query"  :not-host)
247
248  ("src/code/sort"  :not-host)
249  ("src/code/time"  :not-host)
250  ("src/code/weak"  :not-host)
251  ("src/code/final" :not-host)
252
253  #!+mp ("src/code/multi-proc" :not-host)
254
255  ("src/code/setf-funs" :not-host)
256
257  ("src/code/stubs" :not-host)
258
259  ("src/code/exhaust" :not-host)
260
261  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
262  ;;; compiler (and a few miscellaneous files whose dependencies make it
263  ;;; convenient to stick them here)
264
265  ("src/compiler/early-c")
266  ("src/compiler/policy")
267  ("src/code/typedefs")
268
269  ;; ("src/code/defbangmacro" was here until sbcl-0.6.7.3.)
270
271  ("src/compiler/macros")
272  ("src/compiler/generic/vm-macs")
273
274  ;; needed by "compiler/vop"
275  ("src/compiler/sset")
276
277  ;; for e.g. BLOCK-ANNOTATION, needed by "compiler/vop"
278  ("src/compiler/node")
279
280  ;; for e.g. PRIMITIVE-TYPE, needed by "vmdef"
281  ("src/compiler/vop")
282
283  ;; needed by "vm" and "primtype"
284  ("src/compiler/backend")
285
286  ;; for e.g. MAX-VOP-TN-REFS, needed by "meta-vmdef"
287  ("src/compiler/vmdef")
288
289  ;; needs "backend"
290  ("src/compiler/target/backend-parms")
291
292  ;; for INFO and SB!XC:MACRO-FUNCTION, needed by defmacro.lisp
293  ("src/compiler/globaldb")
294  ("src/compiler/info-functions")
295
296  ("src/code/defmacro")
297  ("src/code/force-delayed-defbangmacros")
298
299  ("src/compiler/late-macros")
300
301  ;; for e.g. !DEF-PRIMITIVE-TYPE, needed by primtype.lisp, and
302  ;; DEFINE-STORAGE-CLASS, needed by target/vm.lisp
303  ("src/compiler/meta-vmdef")
304
305  ;; for e.g. DESCRIPTOR-REG, needed by primtype.lisp
306  ("src/compiler/target/vm")
307
308  ;; for e.g. SPECIFIER-TYPE, needed by primtype.lisp
309  ("src/code/early-type")
310
311  ;; FIXME: Classic CMU CL had (OPTIMIZE (SAFETY 2) (DEBUG 2) declared
312  ;; around the compilation of "code/class". Why?
313  ("src/code/class")
314
315  ;; The definition of CONDITION-CLASS depends on SLOT-CLASS, defined
316  ;; in class.lisp.
317  ("src/code/condition" :not-host)
318
319  ("src/compiler/generic/primtype")
320
321  ;; the implementation of the compiler-affecting part of forms like
322  ;; DEFMACRO and DEFTYPE; must be loaded before we can start
323  ;; defining types
324  ("src/compiler/parse-lambda-list")
325
326  ;; for DEFSTRUCT ALIEN-TYPE, needed by host-type.lisp
327  ("src/code/host-alieneval")
328
329  ;; can't be done until definition of e.g. DEFINE-ALIEN-TYPE-CLASS in
330  ;; host-alieneval.lisp
331  ("src/code/host-c-call")
332
333  ;; SB!XC:DEFTYPE is needed in order to compile late-type
334  ;; in the host Common Lisp, and in order to run, it needs
335  ;; %COMPILER-DEFTYPE.
336  ("src/compiler/compiler-deftype")
337
338  ;; These appear here in the build sequence because they require
339  ;;   * the macro INFO, defined in globaldb.lisp, and
340  ;;   * the function PARSE-DEFMACRO, defined in parse-defmacro.lisp,
341  ;; and because they define
342  ;;   * the function SPECIFIER-TYPE, which is used in fndb.lisp.
343  ("src/code/late-type")
344  ("src/code/deftypes-for-target")
345
346  ;; defines IR1-ATTRIBUTES macro, needed by proclaim.lisp
347  ("src/compiler/knownfun")
348
349  ;; needs FUN-INFO structure slot setters, defined in knownfun.lisp
350  ("src/compiler/fun-info-funs")
351
352  ;; stuff needed by "code/defstruct"
353  ("src/code/cross-type" :not-target)
354  ("src/compiler/generic/vm-type")
355  ("src/compiler/proclaim")
356  ("src/code/typecheckfuns")
357
358  ;; The DEFSTRUCT machinery needs SB!XC:SUBTYPEP, defined in 
359  ;; "code/late-type", and SB!XC:TYPEP, defined in "code/cross-type",
360  ;; and SPECIALIZE-ARRAY-TYPE, defined in "compiler/generic/vm-type",
361  ;; and SB!XC:PROCLAIM, defined in "src/compiler/proclaim"
362  ("src/code/defstruct")
363  ("src/code/target-defstruct" :not-host)
364
365  ;; ALIEN-VALUE has to be defined as a class (done by DEFSTRUCT
366  ;; machinery) before we can set its superclasses here.
367  ("src/code/alien-type")
368
369  ;; This needs not just the SB!XC:DEFSTRUCT machinery, but also
370  ;; the TYPE= stuff defined in late-type.lisp, and the
371  ;; CHECK-FUN-NAME defined in proclaim.lisp.
372  ("src/code/force-delayed-defbangstructs")
373
374  ("src/code/typep" :not-host)
375
376  ("src/compiler/compiler-error")
377
378  ("src/code/type-init")
379
380  ;; These define target types needed by fndb.lisp.
381  ("src/code/package")
382  ("src/code/random")
383  ("src/code/hash-table")
384  ("src/code/readtable")
385  ("src/code/pathname")
386  ("src/compiler/lexenv")
387
388  ;; KLUDGE: Much stuff above here is the type system and/or the INFO
389  ;; system, not really the compiler proper. It might be easier to
390  ;; understand the system if those things were split off into packages
391  ;; SB-TYPE and SB-INFO and built in their own sections. -- WHN 20000124
392
393  ;; In classic CMU CL (re)build order, these were done later, but
394  ;; in building from scratch, these must be loaded before
395  ;; "compiler/generic/objdef" in order to allow forms like
396  ;; (DEFINE-PRIMITIVE-OBJECT (..) (CAR ..) ..) to work.
397  ("src/compiler/fndb")
398  ("src/compiler/generic/vm-fndb")
399
400  ("src/compiler/generic/objdef")
401
402  ("src/compiler/generic/interr")
403
404  ("src/compiler/bit-util")
405
406  ;; This has ASSEMBLY-UNIT-related stuff needed by core.lisp.
407  ("src/compiler/early-assem") 
408
409  ;; core.lisp contains DEFSTRUCT CORE-OBJECT, and "compiler/main.lisp"
410  ;; does lots of (TYPEP FOO 'CORE-OBJECT), so it's nice to compile this
411  ;; before "compiler/main.lisp" so that those can be coded efficiently
412  ;; (and so that they don't cause lots of annoying compiler warnings
413  ;; about undefined types). 
414  ("src/compiler/generic/core")
415
416  ("src/code/load")
417
418  ("src/code/fop") ; needs macros from code/load.lisp
419
420  ("src/compiler/ctype")
421  ("src/compiler/disassem")
422  ("src/compiler/assem")
423
424  ("src/compiler/trace-table") ; needs EMIT-LABEL macro from compiler/assem.lisp
425
426  ;; Compiling this requires fop definitions from code/fop.lisp and
427  ;; trace table definitions from compiler/trace-table.lisp.
428  ("src/compiler/dump"
429   ;; FIXME: When building sbcl-0.pre7.14.flaky4.5 under sbcl-0.6.12.1
430   ;; with :SB-SHOW on the target *FEATURES* list, cross-compilation of
431   ;; this file gives a WARNING in HEXSTR,
432   ;;   Lisp error during constant folding:
433   ;;   Argument X is not a REAL: NIL
434   ;; This seems to come from DEF!MACRO %WITH-ARRAY-DATA-MACRO code
435   ;; which looks like
436   ;;     (cond (,end
437   ;;            (unless (or ,unsafe? (<= ,end ,size))
438   ;;              ..))
439   ;;           ..)
440   ;; where the system is trying to constant-fold the <= form when the
441   ;; ,END binding is known to be NIL at compile time. Since the <= form 
442   ;; is unreachable in that case, this shouldn't be signalling a WARNING;
443   ;; but as long as it is, we have to ignore it in order to go on.
444   :ignore-failure-p)
445
446  ("src/compiler/main") ; needs DEFSTRUCT FASL-OUTPUT from dump.lisp
447  ("src/compiler/target-main" :not-host)
448  ("src/compiler/ir1tran")
449  ("src/compiler/ir1-translators")
450  ("src/compiler/ir1util")
451  ("src/compiler/ir1report")
452  ("src/compiler/ir1opt")
453
454  ;; Compiling this file requires the macros SB!ASSEM:EMIT-LABEL and
455  ;; SB!ASSEM:EMIT-POST-IT, defined in assem.lisp.
456  ("src/compiler/late-vmdef")
457
458  ("src/compiler/ir1final")
459  ("src/compiler/array-tran")
460  ("src/compiler/seqtran")
461  ("src/compiler/typetran")
462  ("src/compiler/generic/vm-typetran")
463  ("src/compiler/float-tran")
464  ("src/compiler/saptran")
465  ("src/compiler/srctran")
466  ("src/compiler/locall")
467  ("src/compiler/dfo")
468  ("src/compiler/checkgen")
469  ("src/compiler/constraint")
470  ("src/compiler/physenvanal")
471
472  ("src/compiler/tn")
473  ("src/compiler/life")
474
475  ("src/code/debug-info")
476
477  ("src/compiler/debug-dump")
478  ("src/compiler/generic/utils")
479  ("src/assembly/assemfile")
480
481  ("src/compiler/fixup") ; for DEFSTRUCT FIXUP, used by insts.lisp
482
483  ("src/compiler/target/insts")
484  ("src/compiler/target/macros")
485
486  ("src/assembly/target/support")
487
488  ("src/compiler/target/move")
489  ("src/compiler/target/float")
490  ("src/compiler/target/sap")
491  ("src/compiler/target/system")
492  ("src/compiler/target/char")
493  ("src/compiler/target/memory")
494  ("src/compiler/target/static-fn")
495  ("src/compiler/target/arith"
496   ;; KLUDGE: for ppc and sparc this appears to be necessary -- see the
497   ;; comment below regarding src/compiler/target/array -- CSR,
498   ;; 2002-05-05
499   :ignore-failure-p) 
500  ("src/compiler/target/subprim")
501
502  ("src/compiler/target/debug")
503  ;; src/compiler/sparc/c-call contains a deftransform for
504  ;; %ALIEN-FUNCALL -- CSR
505  ("src/compiler/early-aliencomp")
506  ("src/compiler/target/c-call")
507  ("src/compiler/target/cell")
508  ("src/compiler/target/values")
509  ("src/compiler/target/alloc")
510  ("src/compiler/target/call")
511  ("src/compiler/target/nlx")
512  ("src/compiler/target/show")
513  ("src/compiler/target/array"
514   ;; KLUDGE: Compiling this file raises alarming warnings of the form
515   ;;    Argument FOO to VOP CHECK-BOUND has SC restriction
516   ;;    DESCRIPTOR-REG which is not allowed by the operand type:
517   ;;      (:OR POSITIVE-FIXNUM)
518   ;; This seems not to be something that I broke, but rather a "feature"
519   ;; inherited from classic CMU CL. (Debian cmucl_2.4.8.deb compiling
520   ;; Debian cmucl_2.4.8.tar.gz raises the same warning). Thus, even though
521   ;; these warnings are severe enough that they would ordinarily abort
522   ;; compilation, for now we blithely ignore them and press on to more
523   ;; pressing problems. Someday, though, it would be nice to figure out
524   ;; what the problem is and fix it.. -- WHN 19990323
525   :ignore-failure-p)
526  ("src/compiler/target/pred")
527  ("src/compiler/target/type-vops")
528
529  ("src/assembly/target/assem-rtns" :assem)
530  ("src/assembly/target/array"      :assem)
531  ("src/assembly/target/arith"      :assem)
532  ("src/assembly/target/alloc"      :assem)
533
534  ("src/compiler/pseudo-vops")
535
536  ("src/compiler/aliencomp")
537
538  ("src/compiler/ltv")
539  ("src/compiler/gtn")
540  ("src/compiler/ltn")
541  ("src/compiler/stack")
542  ("src/compiler/control")
543  ("src/compiler/entry")
544  ("src/compiler/ir2tran")
545
546  ("src/compiler/generic/vm-ir2tran")
547
548  ("src/compiler/copyprop")
549  ("src/compiler/represent")
550  ("src/compiler/generic/vm-tran")
551  ("src/compiler/pack")
552  ("src/compiler/codegen")
553  ("src/compiler/debug")
554
555  #!+sb-dyncount ("src/compiler/dyncount")
556  #!+sb-dyncount ("src/code/dyncount")
557
558  ;; needed by OPEN-FASL-OUTPUT, which is called by COMPILE-FILE
559  ("src/code/format-time")
560
561  ;; needed by various unhappy-path cases in the cross-compiler
562  ("src/code/error")
563
564  ;; This wasn't in classic CMU CL "comcom.lisp", but it has some stuff
565  ;; that Python-as-cross-compiler has turned out to need.
566  ("src/code/macroexpand")
567
568  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
569  ;; files which depend in some way (directly or indirectly) on stuff
570  ;; compiled as part of the compiler
571
572  ("src/code/late-extensions") ; needs condition system
573  ("src/compiler/generic/target-core" :not-host) ; uses stuff from
574                                                 ;   "compiler/generic/core"
575
576  ("src/code/eval"              :not-host) ; uses INFO, wants compiler macro
577  ("src/code/target-sap"        :not-host) ; uses SAP-INT-TYPE
578  ("src/code/target-package"    :not-host) ; needs "code/package"
579  ("src/code/target-random"     :not-host) ; needs "code/random"
580  ("src/code/target-hash-table" :not-host) ; needs "code/hash-table"
581  ("src/code/reader"            :not-host) ; needs "code/readtable"
582  ("src/code/target-pathname"   :not-host) ; needs "code/pathname"
583  ("src/code/filesys"           :not-host) ; needs HOST from "code/pathname"
584  ("src/code/save"              :not-host) ; uses the definition of PATHNAME
585                                           ;   from "code/pathname"
586  ("src/code/sharpm"            :not-host) ; uses stuff from "code/reader"
587
588  ;; defines SB!DI:DO-DEBUG-FUN-BLOCKS, needed by target-disassem.lisp
589  ("src/code/debug-int" :not-host)
590
591  ;; target-only assemblerish stuff
592  ("src/compiler/target-disassem"     :not-host)
593  ("src/compiler/target/target-insts" :not-host)
594
595  ("src/code/debug" :not-host)
596
597  ;; The code here can't be compiled until CONDITION and
598  ;; DEFINE-CONDITION are defined and SB!DEBUG:*STACK-TOP-HINT* is
599  ;; declared special.
600  ("src/code/parse-defmacro-errors")
601
602  ("src/code/bit-bash"    :not-host) ; needs %NEGATE from assembly/target/arith
603
604  ("src/code/target-load" :not-host) ; needs special vars from code/load.lisp
605
606  ;; FIXME: Does this really need stuff from compiler/dump.lisp?
607  ("src/compiler/target-dump" :not-host) ; needs stuff from compiler/dump.lisp
608
609  ("src/code/cold-init" :not-host ; needs (SETF EXTERN-ALIEN) macroexpansion
610   ;; FIXME: When building sbcl-0.pre7.14.flaky4.5 under sbcl-0.6.12.1
611   ;; with :SB-SHOW on the target *FEATURES* list, cross-compilation of
612   ;; this file gives a WARNING in HEXSTR,
613   ;;   Lisp error during constant folding:
614   ;;   Argument X is not a REAL: NIL
615   ;; This seems to come from DEF!MACRO %WITH-ARRAY-DATA-MACRO code
616   ;; which looks like
617   ;;     (cond (,end
618   ;;            (unless (or ,unsafe? (<= ,end ,size))
619   ;;              ..))
620   ;;           ..)
621   ;; where the system is trying to constant-fold the <= form when the
622   ;; ,END binding is known to be NIL at compile time. Since the <= form 
623   ;; is unreachable in that case, this shouldn't be signalling a WARNING;
624   ;; but as long as it is, we have to ignore it in order to go on.
625   :ignore-failure-p)
626
627  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
628  ;; target macros and DECLAIMs installed at build-the-cross-compiler time
629
630  ;; Declare all target special variables defined by ANSI now, so that
631  ;; we don't have to worry about any of them being bound incorrectly
632  ;; when the compiler processes code which appears before the appropriate
633  ;; DEFVAR or DEFPARAMETER.
634  ("src/code/cl-specials")
635
636  ;; fundamental target macros (e.g. CL:DO and CL:DEFUN) and support
637  ;; for them
638  ("src/code/defboot")
639  ("src/code/destructuring-bind")
640  ("src/code/early-setf")
641  ("src/code/macros")
642  ("src/code/loop")
643  ("src/code/late-setf")
644
645  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
646
647  ;; other target-code-building stuff which can't be processed until
648  ;; machinery like SB!XC:DEFMACRO exists
649
650  ("src/code/late-format") ; needs SB!XC:DEFMACRO
651  ("src/code/sxhash") ; needs SB!XC:DEFINE-MODIFY-MACRO
652  ("src/code/signal")
653  ("src/code/late-defbangmethod"))