SuSE Support Database

Title: Developing aout programmes on an ELF system

---

Mainpage ---- Searchform ---- History ---- Versions ---- Categories ---- Contents
Deutsch
---

Developing aout programmes on an ELF system

It is necessary under certain circumstances, to produce on an ELF system the older aout format, e.g. if libraries, that are only available in the old aout format, are needed.

The gcc2.7.2 compiles by default in (new) ELF format. Libraries are now thus linked in (older) aout format, so they cannot be erased when linking the references.

In this occasion all object files must be translated into aout format . For doing so, set the following compiler switch:

When compiling:

        -b i486-linuxaout
When linking:
    -mi386linux
If the link call to gcc is done, declare
    -b i486-linuxaout
as well. Makefile example: The aout library libsql.a is thus linked. prog_elf goes wrong, prog_aout works. all: prog_aout prog_elf prog_elf: yardtest.c Makefile gcc -c -I/usr/lib/YARD/include yardtest.c -o yardtest.o gcc -L/lib yardtest.o /usr/lib/YARD/lib/libsql.a \ /usr/lib/YARD/lib/libbasic.a /usr/lib/YARD/lib/sqlnetd.a -o $@ file $@ ldd $@ prog_aout: yardtest.c Makefile gcc -b i486-linuxaout -c -I/usr/lib/YARD/include yardtest.c \ -o yardtest.o gcc -b i486-linuxaout -L/lib yardtest.o /usr/lib/YARD/lib/libsql.a \ /usr/lib/YARD/lib/libbasic.a \ /usr/lib/YARD/lib/sqlnetd.a -o $@ file $@ ldd $@

---

Keywords: GCC, LINK, AOUT, ELF, LINUXAOUT, COMPILE

---

Feedback welcome: Send Mail to kfr@suse.de (Please give the following subject: SDB-kfr_29)

---

Mainpage ---- Searchform ---- History ---- Versions ---- Categories ---- Contents
Deutsch
---

SDB-kfr_29, Copyright SuSE GmbH, Nuremberg, Germany - Version:
Impressum - Last generated: 24. Feb 1999 14:54:47 by maddin with sdb_gen 1.00.0