 pag

*
* Binary File Header
*
* Each executable binary file must have the following
* header associated with it.
*

* struct binhdr

 base 0

bhhdr rmb 1 header byte (BNHEAD)
bhdes rmb 1 descriptor byte * see below *
bhtxt rmb 2 size of text segment
bhdat rmb 2 size of initialized data
bhbss rmb 2 size of uninitialized data
bhrls rmb 2 size of relocation info
bhxfr rmb 2 transfer address
bhstk rmb 2 initial stack size
bhsym rmb 2 symbol table size
bhcom rmb 2 comments size
bhspr rmb 4 spare bytes
bhsrn rmb 2 binary serial number

BHDSIZ equ * size of binary header

BNHEAD equ $02 binary header byte

* descriptor bits

BHDRO equ %00000001 read only text
BHDAB equ %00000010 absolute file
BHDNM equ %00000100 no new memory (use old)


*
* Absolute file format
*
* Absolute files contain records which look
* like the following:
*

 base 0

absct rmb 2 record size in bytes (data only)
absad rmb 2 load address of data record

ABHDSZ equ *
