Indentation fix, cleanup.
[AROS.git] / rom / dos / include / loadseg.h
blobf30b59d7df54c0a2ddfb3f35a9b78a77df68c08b
1 /*
2 * Copyright (C) 2011, The AROS Development Team. All rights reserved.
3 * Author: Jason S. McMullan <jason.mcmullan@gmail.com>
5 * Licensed under the AROS PUBLIC LICENSE (APL) Version 1.1
6 */
8 #ifndef LOADSEG_LOADSEG_H
9 #define LOADSEG_LOADSEG_H
11 #include <aros/libcall.h>
12 #include <dos/elf.h>
14 /* This is called after ELF file is loaded. You may grab the debug info from it. */
15 void register_elf(BPTR file, BPTR hunks, struct elfheader *eh, struct sheader *sh, struct DosLibrary *DOSBase);
16 void register_hunk(BPTR file, BPTR hunks, APTR header, struct DosLibrary *DOSBase);
18 AROS_LD4(BPTR, InternalLoadSeg,
19 AROS_LDA(BPTR , fh , D0),
20 AROS_LDA(BPTR , table , A0),
21 AROS_LDA(LONG_FUNC *, funcarray , A1),
22 AROS_LDA(LONG * , stack , A2),
23 struct DosLibrary *, DOSBase, 126, Dos);
25 /*
26 * Use LoadSegment() to call the linklib's loader.
27 * There's no counterpart since the loaded seglist can be freed by
28 * conventional IntrernalUnloadSeg(), even on old AmigaOS.
30 #define LoadSegment(fh, table, funcarray, stack) \
31 AROS_CALL4(BPTR, AROS_SLIB_ENTRY(InternalLoadSeg, Dos, 126), \
32 AROS_LCA(BPTR , fh , D0), \
33 AROS_LDA(BPTR , table , A0), \
34 AROS_LDA(LONG_FUNC *, funcarray , A1), \
35 AROS_LDA(LONG * , stack , A2), \
36 struct DosLibrary *, DOSBase)
38 #endif /* LOADSEG_LOADSEG_H */