This chapter describes the a.out output module which can be selected with the -Faout option.

Legal
=====

This module is written in 2008-2016,2020,2021 by Frank Wille and is covered by the vasm copyright without modifications.

Additional options for this module
==================================

-mid=<machine id>
     Sets the MID field of the a.out header to the specified value. The MID defaults to 2 (Sun020 big-endian) for M68k and to 100 (PC386 little-endian) for x86.

General
=======

This output module emits the a.out (assembler output) format, which is an older 32-bit format for Unix-like operating systems, originally invented by AT&T.

Restrictions
============

The a.out output format, as implemented in vasm, currently supports the following architectures:

  - M68k

  - i386

The following standard relocations are supported by default:

  - absolute, 8, 16, 32 bits

  - pc-relative, 8, 16, 32 bits

  - base-relative

Standard relocation table entries occupy 8 bytes and don't include an addend, so they are not suitable for most RISC CPUs. The extended relocations format occupies 12 bytes and also allows more relocation types.

Known Problems
==============

Some known problems of this module at the moment:

  - The extended relocation format is not supported.

Error Messages
==============

This module has the following error messages:

  - 3004: section attributes <attr> not supported

  - 3008: output module doesn't allow multiple sections of the same type

  - 3010: section <%s>: alignment padding (%lu) not a multiple of %lu at 0x%llx