2 REM $NetBSD: resutil,v 1.2 2002/02/11 19:02:38 reinoud Exp $
4 REM Copyright (c) 1995 Mark Brinicombe
5 REM All rights reserved
7 REM Redistribution and use in source and binary forms, with or without
8 REM modification, are permitted provided that the following conditions
10 REM 1. Redistributions of source code must retain the above copyright
11 REM notice, this list of conditions and the following disclaimer.
12 REM 2. Redistributions in binary form must reproduce the above copyright
13 REM notice, this list of conditions and the following disclaimer in the
14 REM documentation and/or other materials provided with the distribution.
15 REM 3. All advertising materials mentioning features or use of this software
16 REM must display the following acknowledgement:
17 REM This product includes software developed by Mark Brinicombe.
18 REM 4. The name of the company nor the name of the author may be used to
19 REM endorse or promote products derived from this software without specific
20 REM prior written permission.
22 REM THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
23 REM IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
24 REM OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
25 REM IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
26 REM INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
27 REM BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
28 REM OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
29 REM ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
30 REM OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
31 REM THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
34 REM RiscBSD kernel project
38 REM Assembly code for resource handling utils.
40 REM Created : 10/08/93
41 REM Last updated : 12/07/95
58 swi "XResourceFS_RegisterFiles"
64 swi "XResourceFS_DeregisterFiles"
68 stmfd r13!, {r0-r1, r14}
72 ldmfd r13!, {r0-r1, pc}
76 IF (pass% AND %10) <> 0 THEN
77 PRINT "resourceutils";TAB(25);"Start : ";~start%;TAB(40);"Length : ";~P%-start%
82 DEF PROCresourcefile(filename$, rfilename$)
84 LOCAL start%, file, load%, exec%, length%, attrib%
88 IF (filename$ = "") THEN
95 SYS "OS_File", 5, filename$ TO ,,load%, exec%, length%, attrib%
103 equd attrib% \AND &7f
110 SYS "OS_File", 255, filename$, O%, 0
120 IF (pass% AND %10) <> 0 THEN
121 PRINT filename$;TAB(25);"Start : ";~start%;TAB(40);"Length : ";~P%-start%