]> git.sur5r.net Git - cc65/blob - libsrc/telemon24/sysuname.s
51af1d8fe87187c4d51fd4c2091a813128d6c94d
[cc65] / libsrc / telemon24 / sysuname.s
1 ;
2 ; Ullrich von Bassewitz, 2003-08-12
3 ;
4 ; unsigned char __fastcall__ _sysuname (struct utsname* buf);
5 ;
6
7         .export         __sysuname, utsdata
8
9         .import         utscopy
10
11         __sysuname = utscopy
12
13 ;--------------------------------------------------------------------------
14 ; Data. We define a fixed utsname struct here and just copy it.
15
16 .rodata
17
18 utsdata:
19         ; sysname
20         .asciiz         "cc65"
21
22         ; nodename
23         .asciiz         ""
24
25         ; release
26         .byte           ((.VERSION >> 8) & $0F) + '0'
27         .byte           '.'
28         .if             ((.VERSION >> 4) & $0F) > 9
29         .byte           ((.VERSION >> 4) & $0F) / 10 + '0'
30         .byte           ((.VERSION >> 4) & $0F) .MOD 10 + '0'
31         .else
32         .byte           ((.VERSION >> 4) & $0F) + '0'
33         .endif
34         .byte           $00
35
36         ; version
37         .if             (.VERSION & $0F) > 9
38         .byte           (.VERSION & $0F) / 10 + '0'
39         .byte           (.VERSION & $0F) .MOD 10 + '0'
40         .else
41         .byte           (.VERSION & $0F) + '0'
42         .endif
43         .byte           $00
44
45         ; machine
46         .asciiz         "Oric Telestrat"