OpenBSD Journal

a.out emulation for dynamic binaries in 3.3-current

Contributed by jose on from the old-binaries-still-work dept.

Just another anonymous writes:

From: Marc Espie

Date: Tue, 24 Jun 2003 16:45:34 -0600 (MDT)
To: source-changes@cvs.openbsd.org
Subject: CVS: cvs.openbsd.org: src

CVSROOT:        /cvs
Module name:    src
Changes by:     espie@cvs.openbsd.org   2003/06/24 16:45:33

Modified files:
        sys/arch/i386/conf: GENERIC files.i386
        sys/arch/i386/i386: trap.c
        sys/compat/common: Makefile
        sys/kern       : exec_aout.c
Added files:
        sys/compat/aout: compat_aout.c files.aout

Log message:
a.out emulation for dynamic binaries: intercept the right system calls
so that they look in /emul/a.out first. This allows a.out's ld.so to
find its own libraries without interfering with ELF at all.

Many comments from various people. okay deraadt@

Marc's been testing this for a while, and its been tested on a variety of things. Originally this was needed for Mozilla, but now that runs on ELF and dynamically, well, so this is mainly for older, binary only packages. Thanks, Marc, nice work.

(Comments are closed)


Comments
  1. By Anonymous Coward () on

    Guess now i have no reason not to check out current.

    Comments
    1. By Anonymous Coward () on

      You had no reason before. :)

  2. By Isak Lyberth () ily@simpel-it.dk on http://www.simpel-it.dk

    What is the difference between a.out and and elf. Just a quick overview.

    Comments
    1. By Hans Insulander () hin@openbsd.org on mailto:hin@openbsd.org

      It makes it a lot easier to use modern gcc/binutils.

    2. By vincent () on

      executables are laid out differently. it doesn't make much of a difference from a user's point of view...

      of course, for the full story, read linkers and loaders.

      http://www.iecc.com/linker/

    3. By Anonymous Coward () on

      I found this overview . Original PPT URL is: http://www.csie.nctu.edu.tw/~shieyuan/course/spb/lectures/sp12.ppt

  3. By Anonymous Coward () on

    re downloading all your ports after upgrading sucks

    props to marc!

    Comments
    1. By Sam () on

      You sound like you shouldn't be running current then.

      Comments
      1. By Anonymous Coward () on

        why?

        im on dialup, downloading many things is a pain in the butt. who cares though? i knew id have to do it and i did it.this eases the pain for others.

Credits

Copyright © - Daniel Hartmeier. All rights reserved. Articles and comments are copyright their respective authors, submission implies license to publish on this web site. Contents of the archive prior to as well as images and HTML templates were copied from the fabulous original deadly.org with Jose's and Jim's kind permission. This journal runs as CGI with httpd(8) on OpenBSD, the source code is BSD licensed. undeadly \Un*dead"ly\, a. Not subject to death; immortal. [Obs.]