SYMBOLS { __STACKSIZE__: type = weak, value = $0600; } MEMORY { # Zero Page ZP: file = "", start = $0040, size = $00C0, type = rw, define = yes; # Cartridge Header HEADER: file = %O, start = $0000, size = $0080, fill = yes; # ROM Bank PRG: file = %O, start = $4000, size = $BFFA, fill = yes, define = yes; # CPU Vectors VECTORS: file = %O, start = $FFFA, size = $0006, fill = yes; # standard 2k SRAM (-zeropage) # $0140-$0200 cpu stack # $0500-$0800 3 pages for cc65 parameter stack RAM: file = "", start = $2200, size = __STACKSIZE__, define = yes; } SEGMENTS { ZEROPAGE: load = ZP, type = zp; HEADER: load = HEADER, type = ro; STARTUP: load = PRG, type = ro, define = yes; RODATA: load = PRG, type = ro, define = yes; ONCE: load = PRG, type = ro, optional = yes; CODE: load = PRG, type = ro, define = yes; DATA: load = PRG, run = RAM, type = rw, define = yes; VECTORS: load = VECTORS, type = ro; BSS: load = RAM, type = bss, define = yes; } FEATURES { CONDES: type = constructor, label = __CONSTRUCTOR_TABLE__, count = __CONSTRUCTOR_COUNT__, segment = ONCE; CONDES: type = destructor, label = __DESTRUCTOR_TABLE__, count = __DESTRUCTOR_COUNT__, segment = RODATA; CONDES: type = interruptor, label = __INTERRUPTOR_TABLE__, count = __INTERRUPTOR_COUNT__, segment = RODATA, import = __CALLIRQ__; }