Wanderer/Info: fix compilation
[AROS.git] / tools / flexcat / src / sd / AztecAs_asm.sd
blob747e5b50c7c5ad6b3f953cbde492e58ea9dfaa09
1 ##rem $Id: AztecAs_asm.sd 253 2014-02-18 11:15:58Z damato $
2 ##stringtype assembler
3 ##shortstrings
5 *****************************************************************
7 *  This file was created automatically by `%fv'
8 *  from "%f0".
10 *  Do NOT edit by hand!
12 *****************************************************************
14 *   Includefiles
15         include "exec/types.i"
16         include "utility/tagitem.i"
17         include "libraries/locale.i"
19 *   Function declarations
20         xdef    Open%bCatalog
21         xdef    Close%bCatalog
22         xdef    Get%bString
24 *   Referenced data
25         xref    _LocaleBase
27 *   Referenced functions
28         xref    _LVOOpenCatalogA
29         xref    _LVOCloseCatalog
30         xref    _LVOGetCatalogStr
32 *   Data definitions
33         dseg
34 OpenCatalogTags:
35         even
36         dc.l    OC_Language,0
37         dc.l    OC_BuiltInLanguage,%b_BuiltInLanguage
38         dc.l    OC_Version,%v
39         dc.l    TAG_DONE,0
41         bss.l   %b_Catalog,4
43 %b_BuiltInLanguage:
44         %l,0
46 CatalogName:
47         dc.b    '%b.catalog',0
49 \teven\n\txdef\t%i\n%i:\tdc.l\t%d\n\t%s,0
52 *   Code definitions
53         cseg
55 Open%bCatalog:
56 *   a0 = Locale
57 *   a1 = Language
58         movem.l a2/a6,-(sp)             ;   Save Regs
60         lea     OpenCatalogTags,a2      ;   Store Language
61         move.l  a1,4(a2)
62         bne     Open%bCatalog1
63         lea     8(a2),a2
64 Open%bCatalog1:
65         move.l  _LocaleBase,a6          ;   Call locale.OpenCatalog
66         move.l  a6,d0                   ;   Locale opened?
67         beq     Open%bCatalogEnd        ;   No, skip
68         tst.l   %b_Catalog              ;   Catalog opened?
69         bne     Open%bCatalogEnd        ;   Yes, skip
70         lea     CatalogName,a1
71         jsr     _LVOOpenCatalogA(a6)
72         move.l  d0,%b_Catalog
73 Open%bCatalogEnd:
74         movem.l (sp)+,a2/a6
75         rts
78 Close%bCatalog:
79         move.l  a6,-(sp)
80         move.l  %b_Catalog,a0           ;   Close the Catalog, if needed
81         move.l  #0,%b_Catalog
82         move.l  _LocaleBase,a6
83         move.l  a6,d0                   ;   Locale.library opened?
84         beq     Close%bCatalogEnd       ;   No, skip
85         jsr     _LVOCloseCatalog(a6)
86 Close%bCatalogEnd:
87         move.l  (sp)+,a6
88         rts
91 Get%bString:
92 *   a0 = pointer to structure (ID, string)
93         move.l  a6,-(sp)                ;   Save regs
95         move.l  (a0)+,d0                ;   Get string number
96         move.l  a0,a1                   ;   Get default string
98 Get%bString3:
99         move.l  _LocaleBase,a6          ;   Locale.library present?
100         move.l  a6,d1
101         beq     Get%bStringNoLoc        ;   No, skip
102         move.l  %b_Catalog,a0           ;   Catalog opened?
103         move.l  a0,d1
104         beq     Get%bStringNoLoc        ;   No, skip
106         jsr     _LVOGetCatalogStr(a6)   ;   Call locale.library
107 Get%bStringEnd:
108         move.l  (sp)+,a6
109         rts
111 Get%bStringNoLoc:
112         move.l  a1,d0
113         jmp     Get%bStringEnd
115         end