Skip to content

Commit a084842

Browse files
committed
Initial commit
1 parent b97667b commit a084842

3 files changed

Lines changed: 812 additions & 0 deletions

File tree

Vector-Doubles-Screenshot.jpg

11.8 KB
Loading

atari-xex.cfg

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
# Sample linker configuration for C programs using the Atari binary file support.
2+
# Use with: cl65 -tatari -Catari-xex.cfg prog.c -o prog.xex
3+
FEATURES {
4+
STARTADDRESS: default = $2000;
5+
}
6+
SYMBOLS {
7+
__SYSTEM_CHECK__: type = import; # force inclusion of "system check" load chunk
8+
__STACKSIZE__: type = weak, value = $0800; # 2k stack
9+
__STARTADDRESS__: type = export, value = %S;
10+
__RESERVED_MEMORY__: type = weak, value = $0000;
11+
__SYSCHKHDR__: type = export, value = 0; # Disable system check header
12+
__SYSCHKTRL__: type = export, value = 0; # Disable system check trailer
13+
}
14+
MEMORY {
15+
ZP: file = "", define = yes, start = $0082, size = $007E;
16+
# "system check" load chunk
17+
SYSCHKCHNK: file = %O, start = $2E00, size = $0300;
18+
# "main program" load chunk
19+
MAIN: file = %O, define = yes, start = %S, size = $BC20 - __STACKSIZE__ - __RESERVED_MEMORY__ - %S;
20+
# jlh
21+
ROW_REGION: file = "", define = yes, start = $8400, size = $0400;
22+
}
23+
FILES {
24+
%O: format = atari;
25+
}
26+
FORMATS {
27+
atari: runad = start,
28+
initad = SYSCHKCHNK: __SYSTEM_CHECK__;
29+
}
30+
31+
SEGMENTS {
32+
ZEROPAGE: load = ZP, type = zp;
33+
EXTZP: load = ZP, type = zp, optional = yes;
34+
SYSCHK: load = SYSCHKCHNK, type = rw, define = yes, optional = yes;
35+
ROW_SEGMENT: load = ROW_REGION, type = rw, define = yes, optional = yes;
36+
STARTUP: load = MAIN, type = ro, define = yes;
37+
LOWBSS: load = MAIN, type = rw, optional = yes; # not zero initialized
38+
LOWCODE: load = MAIN, type = ro, define = yes, optional = yes;
39+
ONCE: load = MAIN, type = ro, optional = yes;
40+
CODE: load = MAIN, type = ro, define = yes;
41+
RODATA: load = MAIN, type = ro;
42+
DATA: load = MAIN, type = rw;
43+
INIT: load = MAIN, type = rw, optional = yes;
44+
BSS: load = MAIN, type = bss, define = yes;
45+
}
46+
FEATURES {
47+
CONDES: type = constructor,
48+
label = __CONSTRUCTOR_TABLE__,
49+
count = __CONSTRUCTOR_COUNT__,
50+
segment = ONCE;
51+
CONDES: type = destructor,
52+
label = __DESTRUCTOR_TABLE__,
53+
count = __DESTRUCTOR_COUNT__,
54+
segment = RODATA;
55+
CONDES: type = interruptor,
56+
label = __INTERRUPTOR_TABLE__,
57+
count = __INTERRUPTOR_COUNT__,
58+
segment = RODATA,
59+
import = __CALLIRQ__;
60+
}

0 commit comments

Comments
 (0)