]> git.sur5r.net Git - cc65/blobdiff - cfg/gamate.cfg
some more fiddling
[cc65] / cfg / gamate.cfg
index 5eac46c4be73373ce66af979527560f308001bff..c6f2eed7d1d4ca0a6ffcc10aab078292a8d50e3f 100644 (file)
@@ -4,20 +4,29 @@
 # ld65 config file
 # ld65 --config gamate.cfg -o <prog>.bin <prog>.o
 
+SYMBOLS {
+    __STARTUP__:    type = import;
+    __STACKSIZE__: type = weak, value = $0300; # 3 pages stack
+}
+
 MEMORY {
     ZP: start = $0000, size = $100;
     CPUSTACK: start = $0100, size =$100;
     RAM: start = $0200, size = $200, define = yes;
 #    ROM: start = $6000, size = $8000, fill = yes, fillval = $ff, file = %O, define = yes;
+#    STARTUP:   file = %O, define = yes, start = $6000, size = $29, fill = yes;
+#    ROM: start = $6000 + __STARTUP_SIZE__, size = $8000 - __STARTUP_SIZE__, fill = yes, fillval = $ff, file = %O, define = yes;
+# WARNING: fill value must be $00 else it will no more work
     ROM: start = $6000, size = $8000, fill = yes, fillval = $00, file = %O, define = yes;
 }
 
 SEGMENTS {
+    ZEROPAGE: load = ZP, type = zp, define = yes;
+    STARTUP:   load = ROM,           type = ro, define=yes;
     CODE: load = ROM, type = ro, define=yes;
     RODATA: load = ROM, type = ro, define=yes;
     DATA: load = ROM, run=RAM, type = rw, define = yes;
     BSS: load = RAM, type = bss, define = yes;
-    ZEROPAGE: load = ZP, type = zp, define = yes;
 }
 
 FEATURES {