]> git.sur5r.net Git - cc65/blob - cfg/lunix.cfg
cfg/atari-xex.cfg: fix typo in comment
[cc65] / cfg / lunix.cfg
1 # ld65 Linker-configuration for LUnix, Next Generation.
2
3 SYMBOLS {
4     __HEAPSIZE__:  type = weak, value = $2000; # 8k heap [temporary, until LUnix malloc() exists]
5     __STACKSIZE__: type = weak, value = $0400; # 1k stack (do typical LUnix apps. need 2k?)
6 }
7 MEMORY {
8     ZP:   start = $0080, size = $0040;
9     MAIN: start = %S,    size = $7600 - __STACKSIZE__;
10 }
11 SEGMENTS {
12     ZEROPAGE: load = ZP,   type = zp,  define   = yes; # Pseudo-registers
13     STARTUP:  load = MAIN, type = ro;                  # First initialization code
14     LOWCODE:  load = MAIN, type = ro,  optional = yes; # Legacy from other platforms
15     ONCE:     load = MAIN, type = ro,  optional = yes; # Library initialization code
16     CODE:     load = MAIN, type = ro;                  # Program
17     RODATA:   load = MAIN, type = ro;                  # Literals, constants
18     DATA:     load = MAIN, type = rw;                  # Initialized variables
19     BSS:      load = MAIN, type = bss, define   = yes; # Uninitialized variables
20 }
21 FEATURES {
22     CONDES: type    = constructor,
23             label   = __CONSTRUCTOR_TABLE__,
24             count   = __CONSTRUCTOR_COUNT__,
25             segment = ONCE;
26     CONDES: type    = destructor,
27             label   = __DESTRUCTOR_TABLE__,
28             count   = __DESTRUCTOR_COUNT__,
29             segment = RODATA;
30     CONDES: type    = interruptor,
31             label   = __INTERRUPTOR_TABLE__,
32             count   = __INTERRUPTOR_COUNT__,
33             segment = RODATA,
34             import  = __CALLIRQ__;
35 }
36 FILES {
37     %O: format = o65;
38 }
39 FORMATS {
40     o65: os     = lunix,
41          type   = small,
42          export = main,         # Program entry-point
43          import = LUNIXKERNEL;  # Kernel entry-points
44 }