exec_aout.h File Reference

Back to the index.

Classes | Macros
exec_aout.h File Reference

Go to the source code of this file.

Classes

struct  exec
 

Macros

#define N_PAGSIZ(ex)   (__LDPGSZ)
 
#define OMAGIC   0407 /* old impure format */
 
#define NMAGIC   0410 /* read-only text */
 
#define ZMAGIC   0413 /* demand load format */
 
#define QMAGIC   0314 /* "compact" demand load format; deprecated */
 
#define MID_ZERO   0 /* unknown - implementation dependent */
 
#define MID_SUN010   1 /* sun 68010/68020 binary */
 
#define MID_SUN020   2 /* sun 68020-only binary */
 
#define MID_PC386   100 /* 386 PC binary. (so quoth BFD) */
 
#define MID_ROMPAOS   104 /* old IBM RT */
 
#define MID_I386   134 /* i386 BSD binary */
 
#define MID_M68K   135 /* m68k BSD binary with 8K page sizes */
 
#define MID_M68K4K   136 /* DO NOT USE: m68k BSD binary with 4K page sizes */
 
#define MID_NS32532   137 /* ns32532 */
 
#define MID_SPARC   138 /* sparc */
 
#define MID_PMAX   139 /* pmax */
 
#define MID_VAX   140 /* vax */
 
#define MID_ALPHA   141 /* Alpha BSD binary */
 
#define MID_MIPS   142 /* big-endian MIPS */
 
#define MID_ARM6   143 /* ARM6 */
 
#define MID_ROMP   149 /* IBM RT */
 
#define MID_M88K   151 /* m88k BSD binary */
 
#define MID_HP200   200 /* hp200 (68010) BSD binary */
 
#define MID_HP300   300 /* hp300 (68020+68881) BSD binary */
 
#define MID_HPUX   0x20C /* hp200/300 HP-UX binary */
 
#define MID_HPUX800   0x20B /* hp800 HP-UX binary */
 
#define EX_DYNAMIC   0x20
 
#define EX_PIC   0x10
 
#define EX_DPMASK   0x30
 
#define N_GETMAGIC(ex)   ( (((ex).a_midmag)&0xffff0000) ? (ntohl(((ex).a_midmag))&0xffff) : ((ex).a_midmag))
 
#define N_GETMAGIC2(ex)
 
#define N_GETMID(ex)   ( (((ex).a_midmag)&0xffff0000) ? ((ntohl(((ex).a_midmag))>>16)&0x03ff) : MID_ZERO )
 
#define N_GETFLAG(ex)   ( (((ex).a_midmag)&0xffff0000) ? ((ntohl(((ex).a_midmag))>>26)&0x3f) : 0 )
 
#define N_SETMAGIC(ex, mag, mid, flag)
 
#define N_ALIGN(ex, x)
 
#define N_BADMAG(ex)
 
#define N_TXTADDR(ex)   (N_GETMAGIC2(ex) == (ZMAGIC|0x10000) ? 0 : __LDPGSZ)
 
#define N_DATADDR(ex)
 
#define N_BSSADDR(ex)   (N_DATADDR(ex) + (ex).a_data)
 
#define N_TXTOFF(ex)
 
#define N_DATOFF(ex)   N_ALIGN(ex, N_TXTOFF(ex) + (ex).a_text)
 
#define N_TRELOFF(ex)   (N_DATOFF(ex) + (ex).a_data)
 
#define N_DRELOFF(ex)   (N_TRELOFF(ex) + (ex).a_trsize)
 
#define N_SYMOFF(ex)   (N_DRELOFF(ex) + (ex).a_drsize)
 
#define N_STROFF(ex)   (N_SYMOFF(ex) + (ex).a_syms)
 

Macro Definition Documentation

◆ EX_DPMASK

#define EX_DPMASK   0x30

Definition at line 96 of file exec_aout.h.

◆ EX_DYNAMIC

#define EX_DYNAMIC   0x20

Definition at line 94 of file exec_aout.h.

◆ EX_PIC

#define EX_PIC   0x10

Definition at line 95 of file exec_aout.h.

◆ MID_ALPHA

#define MID_ALPHA   141 /* Alpha BSD binary */

Definition at line 81 of file exec_aout.h.

◆ MID_ARM6

#define MID_ARM6   143 /* ARM6 */

Definition at line 83 of file exec_aout.h.

◆ MID_HP200

#define MID_HP200   200 /* hp200 (68010) BSD binary */

Definition at line 86 of file exec_aout.h.

◆ MID_HP300

#define MID_HP300   300 /* hp300 (68020+68881) BSD binary */

Definition at line 87 of file exec_aout.h.

◆ MID_HPUX

#define MID_HPUX   0x20C /* hp200/300 HP-UX binary */

Definition at line 88 of file exec_aout.h.

◆ MID_HPUX800

#define MID_HPUX800   0x20B /* hp800 HP-UX binary */

Definition at line 89 of file exec_aout.h.

◆ MID_I386

#define MID_I386   134 /* i386 BSD binary */

Definition at line 74 of file exec_aout.h.

◆ MID_M68K

#define MID_M68K   135 /* m68k BSD binary with 8K page sizes */

Definition at line 75 of file exec_aout.h.

◆ MID_M68K4K

#define MID_M68K4K   136 /* DO NOT USE: m68k BSD binary with 4K page sizes */

Definition at line 76 of file exec_aout.h.

◆ MID_M88K

#define MID_M88K   151 /* m88k BSD binary */

Definition at line 85 of file exec_aout.h.

◆ MID_MIPS

#define MID_MIPS   142 /* big-endian MIPS */

Definition at line 82 of file exec_aout.h.

◆ MID_NS32532

#define MID_NS32532   137 /* ns32532 */

Definition at line 77 of file exec_aout.h.

◆ MID_PC386

#define MID_PC386   100 /* 386 PC binary. (so quoth BFD) */

Definition at line 72 of file exec_aout.h.

◆ MID_PMAX

#define MID_PMAX   139 /* pmax */

Definition at line 79 of file exec_aout.h.

◆ MID_ROMP

#define MID_ROMP   149 /* IBM RT */

Definition at line 84 of file exec_aout.h.

◆ MID_ROMPAOS

#define MID_ROMPAOS   104 /* old IBM RT */

Definition at line 73 of file exec_aout.h.

◆ MID_SPARC

#define MID_SPARC   138 /* sparc */

Definition at line 78 of file exec_aout.h.

◆ MID_SUN010

#define MID_SUN010   1 /* sun 68010/68020 binary */

Definition at line 70 of file exec_aout.h.

◆ MID_SUN020

#define MID_SUN020   2 /* sun 68020-only binary */

Definition at line 71 of file exec_aout.h.

◆ MID_VAX

#define MID_VAX   140 /* vax */

Definition at line 80 of file exec_aout.h.

◆ MID_ZERO

#define MID_ZERO   0 /* unknown - implementation dependent */

Definition at line 69 of file exec_aout.h.

◆ N_ALIGN

#define N_ALIGN (   ex,
 
)
Value:
(N_GETMAGIC(ex) == ZMAGIC || N_GETMAGIC(ex) == QMAGIC ? \
((x) + __LDPGSZ - 1) & ~(__LDPGSZ - 1) : (x))
#define ZMAGIC
Definition: exec_aout.h:62
#define QMAGIC
Definition: exec_aout.h:63
#define N_GETMAGIC(ex)
Definition: exec_aout.h:117

Definition at line 130 of file exec_aout.h.

◆ N_BADMAG

#define N_BADMAG (   ex)
Value:
(N_GETMAGIC(ex) != NMAGIC && N_GETMAGIC(ex) != OMAGIC && \
N_GETMAGIC(ex) != ZMAGIC && N_GETMAGIC(ex) != QMAGIC)
#define ZMAGIC
Definition: exec_aout.h:62
#define QMAGIC
Definition: exec_aout.h:63
#define NMAGIC
Definition: exec_aout.h:61
#define N_GETMAGIC(ex)
Definition: exec_aout.h:117
#define OMAGIC
Definition: exec_aout.h:60

Definition at line 135 of file exec_aout.h.

◆ N_BSSADDR

#define N_BSSADDR (   ex)    (N_DATADDR(ex) + (ex).a_data)

Definition at line 148 of file exec_aout.h.

◆ N_DATADDR

#define N_DATADDR (   ex)
Value:
(N_GETMAGIC(ex) == OMAGIC ? N_TXTADDR(ex) + (ex).a_text : \
(N_TXTADDR(ex) + (ex).a_text + __LDPGSZ - 1) & ~(__LDPGSZ - 1))
#define N_GETMAGIC(ex)
Definition: exec_aout.h:117
#define N_TXTADDR(ex)
Definition: exec_aout.h:140
#define OMAGIC
Definition: exec_aout.h:60

Definition at line 143 of file exec_aout.h.

◆ N_DATOFF

#define N_DATOFF (   ex)    N_ALIGN(ex, N_TXTOFF(ex) + (ex).a_text)

Definition at line 158 of file exec_aout.h.

◆ N_DRELOFF

#define N_DRELOFF (   ex)    (N_TRELOFF(ex) + (ex).a_trsize)

Definition at line 166 of file exec_aout.h.

◆ N_GETFLAG

#define N_GETFLAG (   ex)    ( (((ex).a_midmag)&0xffff0000) ? ((ntohl(((ex).a_midmag))>>26)&0x3f) : 0 )

Definition at line 124 of file exec_aout.h.

◆ N_GETMAGIC

#define N_GETMAGIC (   ex)    ( (((ex).a_midmag)&0xffff0000) ? (ntohl(((ex).a_midmag))&0xffff) : ((ex).a_midmag))

Definition at line 117 of file exec_aout.h.

◆ N_GETMAGIC2

#define N_GETMAGIC2 (   ex)
Value:
( (((ex).a_midmag)&0xffff0000) ? (ntohl(((ex).a_midmag))&0xffff) : \
(((ex).a_midmag) | 0x10000) )

Definition at line 119 of file exec_aout.h.

◆ N_GETMID

#define N_GETMID (   ex)    ( (((ex).a_midmag)&0xffff0000) ? ((ntohl(((ex).a_midmag))>>16)&0x03ff) : MID_ZERO )

Definition at line 122 of file exec_aout.h.

◆ N_PAGSIZ

#define N_PAGSIZ (   ex)    (__LDPGSZ)

Definition at line 40 of file exec_aout.h.

◆ N_SETMAGIC

#define N_SETMAGIC (   ex,
  mag,
  mid,
  flag 
)
Value:
( (ex).a_midmag = htonl( (((flag)&0x3f)<<26) | (((mid)&0x03ff)<<16) | \
(((mag)&0xffff)) ) )

Definition at line 126 of file exec_aout.h.

◆ N_STROFF

#define N_STROFF (   ex)    (N_SYMOFF(ex) + (ex).a_syms)

Definition at line 174 of file exec_aout.h.

◆ N_SYMOFF

#define N_SYMOFF (   ex)    (N_DRELOFF(ex) + (ex).a_drsize)

Definition at line 170 of file exec_aout.h.

◆ N_TRELOFF

#define N_TRELOFF (   ex)    (N_DATOFF(ex) + (ex).a_data)

Definition at line 162 of file exec_aout.h.

◆ N_TXTADDR

#define N_TXTADDR (   ex)    (N_GETMAGIC2(ex) == (ZMAGIC|0x10000) ? 0 : __LDPGSZ)

Definition at line 140 of file exec_aout.h.

◆ N_TXTOFF

#define N_TXTOFF (   ex)
Value:
( N_GETMAGIC2(ex)==ZMAGIC || N_GETMAGIC2(ex)==(QMAGIC|0x10000) ? \
0 : (N_GETMAGIC2(ex)==(ZMAGIC|0x10000) ? __LDPGSZ : \
sizeof(struct exec)) )
#define ZMAGIC
Definition: exec_aout.h:62
#define QMAGIC
Definition: exec_aout.h:63
Definition: exec_aout.h:48
#define N_GETMAGIC2(ex)
Definition: exec_aout.h:119

Definition at line 152 of file exec_aout.h.

◆ NMAGIC

#define NMAGIC   0410 /* read-only text */

Definition at line 61 of file exec_aout.h.

◆ OMAGIC

#define OMAGIC   0407 /* old impure format */

Definition at line 60 of file exec_aout.h.

◆ QMAGIC

#define QMAGIC   0314 /* "compact" demand load format; deprecated */

Definition at line 63 of file exec_aout.h.

◆ ZMAGIC

#define ZMAGIC   0413 /* demand load format */

Definition at line 62 of file exec_aout.h.


Generated on Sun Sep 30 2018 16:05:18 for GXemul by doxygen 1.8.13