]> git.sur5r.net Git - cc65/blob - libsrc/cbm/exehdr.s
541d2e5839edb4dc84bd7d79f61cccb45d52a5d4
[cc65] / libsrc / cbm / exehdr.s
1 ;
2 ; Ullrich von Bassewitz, 2010-11-14
3 ;
4 ; This module supplies a small BASIC stub program that jumps to the machine
5 ; language code that follows it using SYS.
6 ;
7
8         ; The following symbol is used by linker config to force the module
9         ; to get included into the output file
10         .export         __EXEHDR__: absolute = 1
11
12 .segment        "EXEHDR"
13
14         .addr   Next
15         .word   .version        ; Line number
16         .byte   $9E             ; SYS token
17         .byte   <(((Start /  1000) .mod 10) + '0')
18         .byte   <(((Start /   100) .mod 10) + '0')
19         .byte   <(((Start /    10) .mod 10) + '0')
20         .byte   <(((Start /     1) .mod 10) + '0')
21         .byte   $00             ; End of BASIC line
22 Next:   .word   0               ; BASIC end marker
23 Start:
24
25
26
27