VirtualBox

source: kStuff/trunk/kLdr/kLdrExeStub-os2.asm@ 5

Last change on this file since 5 was 2, checked in by bird, 17 years ago

Imported http://svn.netlabs.org/repos/libc/trunk/kStuff, revision 3612.

  • Property svn:keywords set to Id Revision
File size: 2.1 KB
Line 
1; $Id: kLdrExeStub-os2.asm 2 2007-11-16 16:07:14Z bird $
2;; @file
3; kLdr - OS/2 Loader Stub.
4;
5; This file contains a 64kb code/data/stack segment which is used to kick off
6; the loader dll that loads the process.
7;
8
9;
10; Copyright (c) 2006-2007 knut st. osmundsen <[email protected]>
11;
12; This file is part of kStuff.
13;
14; kStuff is free software; you can redistribute it and/or
15; modify it under the terms of the GNU Lesser General Public
16; License as published by the Free Software Foundation; either
17; version 2.1 of the License, or (at your option) any later version.
18;
19; In addition to the permissions in the GNU Lesser General Public
20; License, you are granted unlimited permission to link the compiled
21; version of this file into combinations with other programs, and to
22; distribute those combinations without any restriction coming from
23; the use of this file.
24;
25; kStuff is distributed in the hope that it will be useful,
26; but WITHOUT ANY WARRANTY; without even the implied warranty of
27; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
28; Lesser General Public License for more details.
29;
30; You should have received a copy of the GNU Lesser General Public
31; License along with kStuff; if not, write to the Free Software
32; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
33; 02110-1301, USA
34;
35
36struc KLDRARGS
37 .fFlags resd 1
38 .enmSearch resd 1
39 .szExecutable resb 260
40 .szDefPrefix resb 16
41 .szDefSuffix resb 16
42 .szLibPath resb (4096 - (4 + 4 + 16 + 16 + 260))
43endstruc
44
45extern _kLdrDyldLoadExe
46
47
48segment DATA32 stack CLASS=DATA align=16 use32
49..start:
50 push args
51 jmp _kLdrDyldLoadExe
52
53;
54; Argument structure.
55;
56align 4
57args:
58istruc KLDRARGS
59 at KLDRARGS.fFlags, dd 0
60 at KLDRARGS.enmSearch, dd 2 ;KLDRDYLD_SEARCH_HOST
61 at KLDRARGS.szDefPrefix, db ''
62 at KLDRARGS.szDefSuffix, db '.dll'
63; at KLDRARGS.szExecutable, db 'tst-0.exe'
64 at KLDRARGS.szLibPath, db ''
65iend
66
67segment STACK32 stack CLASS=STACK align=16 use32
68; pad up to 64KB.
69resb 60*1024
70
71global WEAK$ZERO
72WEAK$ZERO EQU 0
73group DGROUP, DATA32 STACK32
74
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette