source: freewrt/target/linux/generic-2.4/patches/108-optional_aout_support.patch@ a3abab6

freewrt_1_0 freewrt_2_0
Last change on this file since a3abab6 was 475ad56, checked in by Waldemar Brodkorb <wbx@…>, 20 years ago

add OpenWrt trunk revision 3830.

git-svn-id: svn://www.freewrt.org/trunk/freewrt@1 afb5a338-a214-0410-bd46-81f09a774fd1

  • Property mode set to 100644
File size: 24.7 KB
  • Documentation/Configure.help

    diff -urPX nopatch linux-2.4.26/Documentation/Configure.help linux/Documentation/Configure.help
    old new  
    46224622  will be called binfmt_elf.o. Saying M or N here is dangerous because
    46234623  some crucial programs on your system might be in ELF format.
    46244624
     4625ELF binaries with a.out format interpreters or a.out libraries
     4626CONFIG_BINFMT_ELF_AOUT
     4627  The kernel may support ELF executables which use an a.out format
     4628  interpreter (dynamic linker) and/or a.out shared libraries, in
     4629  addition to the usual ELF-ELF setups. You shouldn't need this.
     4630
    46254631Kernel support for a.out binaries
    46264632CONFIG_BINFMT_AOUT
    46274633  A.out (Assembler.OUTput) is a set of formats for libraries and
     
    46354641  warrant removing support. However its removal is a good idea if you
    46364642  wish to ensure that absolutely none of your programs will use this
    46374643  older executable format. If you don't know what to answer at this
    4638   point then answer Y. If someone told you "You need a kernel with
     4644  point then answer N. If someone told you "You need a kernel with
    46394645  QMAGIC support" then you'll have to say Y here. You may answer M to
    46404646  compile a.out support as a module and later load the module when you
    46414647  want to use a program or library in a.out format. The module will be
    4642   called binfmt_aout.o. Saying M or N here is dangerous though,
    4643   because some crucial programs on your system might still be in A.OUT
    4644   format.
     4648  called binfmt_aout.o.
    46454649
    46464650OSF/1 v4 readv/writev compatibility
    46474651CONFIG_OSF4_COMPAT
  • arch/alpha/config.in

    diff -urPX nopatch linux-2.4.26/arch/alpha/config.in linux/arch/alpha/config.in
    old new  
    315315fi
    316316
    317317bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     318if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     319   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     320fi
    318321tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    319322tristate 'Kernel support for Linux/Intel ELF binaries' CONFIG_BINFMT_EM86
    320323source drivers/parport/Config.in
  • arch/alpha/defconfig

    diff -urPX nopatch linux-2.4.26/arch/alpha/defconfig linux/arch/alpha/defconfig
    old new  
    7272# CONFIG_KCORE_AOUT is not set
    7373# CONFIG_BINFMT_AOUT is not set
    7474CONFIG_BINFMT_ELF=y
     75# CONFIG_BINFMT_ELF_AOUT is not set
    7576# CONFIG_BINFMT_MISC is not set
    7677# CONFIG_BINFMT_EM86 is not set
    7778
  • arch/arm/config.in

    diff -urPX nopatch linux-2.4.26/arch/arm/config.in linux/arch/arm/config.in
    old new  
    499499         A.OUT          CONFIG_KCORE_AOUT" ELF
    500500tristate 'Kernel support for a.out binaries' CONFIG_BINFMT_AOUT
    501501bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     502if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     503   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     504fi
    502505tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    503506dep_bool 'Power Management support (experimental)' CONFIG_PM $CONFIG_EXPERIMENTAL
    504507dep_tristate 'RISC OS personality' CONFIG_ARTHUR $CONFIG_CPU_32
  • arch/arm/defconfig

    diff -urPX nopatch linux-2.4.26/arch/arm/defconfig linux/arch/arm/defconfig
    old new  
    8383CONFIG_NWFPE=y
    8484CONFIG_KCORE_ELF=y
    8585# CONFIG_KCORE_AOUT is not set
    86 CONFIG_BINFMT_AOUT=y
     86# CONFIG_BINFMT_AOUT is not set
    8787CONFIG_BINFMT_ELF=y
     88# CONFIG_BINFMT_ELF_AOUT is not set
    8889# CONFIG_BINFMT_MISC is not set
    8990# CONFIG_PM is not set
    9091# CONFIG_ARTHUR is not set
  • arch/cris/config.in

    diff -urPX nopatch linux-2.4.26/arch/cris/config.in linux/arch/cris/config.in
    old new  
    3131bool 'Sysctl support' CONFIG_SYSCTL
    3232
    3333bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     34if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     35   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     36fi
    3437
    3538string 'Kernel command line' CONFIG_ETRAX_CMDLINE "root=/dev/mtdblock3"
    3639
  • arch/cris/defconfig

    diff -urPX nopatch linux-2.4.26/arch/cris/defconfig linux/arch/cris/defconfig
    old new  
    1818# CONFIG_BSD_PROCESS_ACCT is not set
    1919# CONFIG_SYSCTL is not set
    2020CONFIG_BINFMT_ELF=y
     21# CONFIG_BINFMT_ELF_AOUT is not set
    2122# CONFIG_ETRAX_KGDB is not set
    2223# CONFIG_ETRAX_WATCHDOG is not set
    2324
  • arch/i386/config.in

    diff -urPX nopatch linux-2.4.26/arch/i386/config.in linux/arch/i386/config.in
    old new  
    327327fi
    328328tristate 'Kernel support for a.out binaries' CONFIG_BINFMT_AOUT
    329329bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     330if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     331   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     332fi
    330333tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    331334bool 'Select task to kill on out of memory condition' CONFIG_OOM_KILLER
    332335
  • arch/i386/defconfig

    diff -urPX nopatch linux-2.4.26/arch/i386/defconfig linux/arch/i386/defconfig
    old new  
    110110CONFIG_SYSCTL=y
    111111CONFIG_KCORE_ELF=y
    112112# CONFIG_KCORE_AOUT is not set
    113 CONFIG_BINFMT_AOUT=y
     113# CONFIG_BINFMT_AOUT is not set
    114114CONFIG_BINFMT_ELF=y
    115 CONFIG_BINFMT_MISC=y
     115# CONFIG_BINFMT_ELF_AOUT is not set
     116# CONFIG_BINFMT_MISC is not set
    116117# CONFIG_OOM_KILLER is not set
    117118CONFIG_PM=y
    118119# CONFIG_APM is not set
  • arch/ia64/config.in

    diff -urPX nopatch linux-2.4.26/arch/ia64/config.in linux/arch/ia64/config.in
    old new  
    124124bool 'BSD Process Accounting' CONFIG_BSD_PROCESS_ACCT
    125125bool 'Sysctl support' CONFIG_SYSCTL
    126126bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     127if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     128   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     129fi
    127130tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    128131
    129132if [ "$CONFIG_IA64_HP_SIM" = "n" ]; then
  • arch/ia64/defconfig

    diff -urPX nopatch linux-2.4.26/arch/ia64/defconfig linux/arch/ia64/defconfig
    old new  
    6060# CONFIG_BSD_PROCESS_ACCT is not set
    6161CONFIG_SYSCTL=y
    6262CONFIG_BINFMT_ELF=y
     63# CONFIG_BINFMT_ELF_AOUT is not set
    6364# CONFIG_BINFMT_MISC is not set
    6465CONFIG_ACPI=y
    6566CONFIG_ACPI_EFI=y
  • arch/m68k/config.in

    diff -urPX nopatch linux-2.4.26/arch/m68k/config.in linux/arch/m68k/config.in
    old new  
    9999fi
    100100tristate 'Kernel support for a.out binaries' CONFIG_BINFMT_AOUT
    101101bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     102if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     103   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     104fi
    102105tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    103106
    104107if [ "$CONFIG_AMIGA" = "y" ]; then
  • arch/m68k/defconfig

    diff -urPX nopatch linux-2.4.26/arch/m68k/defconfig linux/arch/m68k/defconfig
    old new  
    4444CONFIG_SYSCTL=y
    4545CONFIG_KCORE_ELF=y
    4646# CONFIG_KCORE_AOUT is not set
    47 CONFIG_BINFMT_AOUT=y
     47# CONFIG_BINFMT_AOUT is not set
    4848CONFIG_BINFMT_ELF=y
     49# CONFIG_BINFMT_ELF_AOUT is not set
    4950# CONFIG_BINFMT_MISC is not set
    5051CONFIG_ZORRO=y
    5152# CONFIG_AMIGA_PCMCIA is not set
  • arch/mips/config-shared.in

    diff -urPX nopatch linux-2.4.26/arch/mips/config-shared.in linux/arch/mips/config-shared.in
    old new  
    944944define_bool CONFIG_KCORE_AOUT n
    945945define_bool CONFIG_BINFMT_AOUT n
    946946bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     947if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     948   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     949fi
    947950dep_bool 'Kernel support for Linux/MIPS 32-bit binary compatibility' CONFIG_MIPS32_COMPAT $CONFIG_MIPS64
    948951dep_bool 'Kernel support for o32 binaries' CONFIG_MIPS32_O32 $CONFIG_MIPS32_COMPAT
    949952dep_bool 'Kernel support for n32 binaries' CONFIG_MIPS32_N32 $CONFIG_MIPS32_COMPAT
  • arch/mips/defconfig

    diff -urPX nopatch linux-2.4.26/arch/mips/defconfig linux/arch/mips/defconfig
    old new  
    139139# CONFIG_KCORE_AOUT is not set
    140140# CONFIG_BINFMT_AOUT is not set
    141141CONFIG_BINFMT_ELF=y
     142# CONFIG_BINFMT_ELF_AOUT is not set
    142143# CONFIG_MIPS32_COMPAT is not set
    143144# CONFIG_MIPS32_O32 is not set
    144145# CONFIG_MIPS32_N32 is not set
  • arch/mips/kernel/irixelf.c

    diff -urPX nopatch linux-2.4.26/arch/mips/kernel/irixelf.c linux/arch/mips/kernel/irixelf.c
    old new  
    88 * Copyright 1993, 1994: Eric Youngdale (ericy@cais.com).
    99 */
    1010
     11#include <linux/config.h>
    1112#include <linux/module.h>
    1213
    1314#include <linux/fs.h>
     
    4849extern int dump_fpu (elf_fpregset_t *);
    4950
    5051static struct linux_binfmt irix_format = {
    51         NULL, THIS_MODULE, load_irix_binary, load_irix_library,
     52        NULL, THIS_MODULE, load_irix_binary,
     53#ifdef CONFIG_BINFMT_ELF_AOUT
     54        load_irix_library,
     55#else
     56        NULL,
     57#endif
    5258        irix_core_dump, PAGE_SIZE
    5359};
    5460
     
    787793        goto out;
    788794}
    789795
     796#ifdef CONFIG_BINFMT_ELF_AOUT
    790797/* This is really simpleminded and specialized - we are loading an
    791798 * a.out library that is given an ELF header.
    792799 */
     
    863870        kfree(elf_phdata);
    864871        return 0;
    865872}
     873#endif
    866874
    867875/* Called through irix_syssgi() to map an elf image given an FD,
    868876 * a phdr ptr USER_PHDRP in userspace, and a count CNT telling how many
  • arch/mips64/defconfig

    diff -urPX nopatch linux-2.4.26/arch/mips64/defconfig linux/arch/mips64/defconfig
    old new  
    137137# CONFIG_KCORE_AOUT is not set
    138138# CONFIG_BINFMT_AOUT is not set
    139139CONFIG_BINFMT_ELF=y
     140# CONFIG_BINFMT_ELF_AOUT is not set
    140141CONFIG_MIPS32_COMPAT=y
    141142CONFIG_MIPS32_O32=y
    142143# CONFIG_MIPS32_N32 is not set
  • arch/parisc/config.in

    diff -urPX nopatch linux-2.4.26/arch/parisc/config.in linux/arch/parisc/config.in
    old new  
    8989bool 'Sysctl support' CONFIG_SYSCTL
    9090define_bool CONFIG_KCORE_ELF y
    9191bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     92if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     93   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     94fi
    9295tristate 'Kernel support for SOM binaries' CONFIG_BINFMT_SOM
    9396tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    9497
  • arch/parisc/defconfig

    diff -urPX nopatch linux-2.4.26/arch/parisc/defconfig linux/arch/parisc/defconfig
    old new  
    5656CONFIG_SYSCTL=y
    5757CONFIG_KCORE_ELF=y
    5858CONFIG_BINFMT_ELF=y
     59# CONFIG_BINFMT_ELF_AOUT is not set
    5960CONFIG_BINFMT_SOM=y
    6061# CONFIG_BINFMT_MISC is not set
    6162# CONFIG_PM is not set
  • arch/ppc/config.in

    diff -urPX nopatch linux-2.4.26/arch/ppc/config.in linux/arch/ppc/config.in
    old new  
    384384fi
    385385define_bool CONFIG_BINFMT_ELF y
    386386define_bool CONFIG_KERNEL_ELF y
     387bool 'ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
    387388tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    388389bool 'Select task to kill on out of memory condition' CONFIG_OOM_KILLER
    389390
  • arch/ppc/defconfig

    diff -urPX nopatch linux-2.4.26/arch/ppc/defconfig linux/arch/ppc/defconfig
    old new  
    5959CONFIG_KCORE_ELF=y
    6060CONFIG_BINFMT_ELF=y
    6161CONFIG_KERNEL_ELF=y
    62 CONFIG_BINFMT_MISC=m
     62# CONFIG_BINFMT_ELF_AOUT is not set
     63# CONFIG_BINFMT_MISC is not set
    6364# CONFIG_OOM_KILLER is not set
    6465CONFIG_PCI_NAMES=y
    6566CONFIG_HOTPLUG=y
  • arch/ppc64/config.in

    diff -urPX nopatch linux-2.4.26/arch/ppc64/config.in linux/arch/ppc64/config.in
    old new  
    8282fi
    8383
    8484bool 'Kernel support for 64 bit ELF binaries' CONFIG_BINFMT_ELF
     85if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     86   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     87fi
    8588
    8689tristate 'Kernel support for 32 bit ELF binaries' CONFIG_BINFMT_ELF32
    8790
  • arch/ppc64/defconfig

    diff -urPX nopatch linux-2.4.26/arch/ppc64/defconfig linux/arch/ppc64/defconfig
    old new  
    5656# CONFIG_BSD_PROCESS_ACCT is not set
    5757CONFIG_KCORE_ELF=y
    5858CONFIG_BINFMT_ELF=y
     59# CONFIG_BINFMT_ELF_AOUT is not set
    5960CONFIG_BINFMT_ELF32=y
    6061# CONFIG_BINFMT_MISC is not set
    6162CONFIG_PCI_NAMES=y
  • arch/s390/config.in

    diff -urPX nopatch linux-2.4.26/arch/s390/config.in linux/arch/s390/config.in
    old new  
    5858bool 'Sysctl support' CONFIG_SYSCTL
    5959define_bool CONFIG_KCORE_ELF y
    6060bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     61if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     62   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     63fi
    6164tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    6265bool 'Show crashed user process info' CONFIG_PROCESS_DEBUG
    6366bool 'Pseudo page fault support' CONFIG_PFAULT
  • arch/s390/defconfig

    diff -urPX nopatch linux-2.4.26/arch/s390/defconfig linux/arch/s390/defconfig
    old new  
    4646CONFIG_SYSCTL=y
    4747CONFIG_KCORE_ELF=y
    4848CONFIG_BINFMT_ELF=y
     49# CONFIG_BINFMT_ELF_AOUT is not set
    4950# CONFIG_BINFMT_MISC is not set
    5051# CONFIG_PROCESS_DEBUG is not set
    5152CONFIG_PFAULT=y
  • arch/s390x/config.in

    diff -urPX nopatch linux-2.4.26/arch/s390x/config.in linux/arch/s390x/config.in
    old new  
    6161bool 'Sysctl support' CONFIG_SYSCTL
    6262define_bool CONFIG_KCORE_ELF y
    6363bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     64if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     65   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     66fi
    6467tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    6568bool 'Show crashed user process info' CONFIG_PROCESS_DEBUG
    6669bool 'Pseudo page fault support' CONFIG_PFAULT
  • arch/s390x/defconfig

    diff -urPX nopatch linux-2.4.26/arch/s390x/defconfig linux/arch/s390x/defconfig
    old new  
    4747CONFIG_SYSCTL=y
    4848CONFIG_KCORE_ELF=y
    4949CONFIG_BINFMT_ELF=y
     50# CONFIG_BINFMT_ELF_AOUT is not set
    5051# CONFIG_BINFMT_MISC is not set
    5152# CONFIG_PROCESS_DEBUG is not set
    5253CONFIG_PFAULT=y
  • arch/sh/config.in

    diff -urPX nopatch linux-2.4.26/arch/sh/config.in linux/arch/sh/config.in
    old new  
    283283         A.OUT          CONFIG_KCORE_AOUT" ELF
    284284fi
    285285bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     286if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     287   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     288fi
    286289tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    287290
    288291bool 'Select task to kill on out of memory condition' CONFIG_OOM_KILLER
  • arch/sh/defconfig

    diff -urPX nopatch linux-2.4.26/arch/sh/defconfig linux/arch/sh/defconfig
    old new  
    4848CONFIG_KCORE_ELF=y
    4949# CONFIG_KCORE_AOUT is not set
    5050CONFIG_BINFMT_ELF=y
     51# CONFIG_BINFMT_ELF_AOUT is not set
    5152# CONFIG_BINFMT_MISC is not set
    5253
    5354#
  • arch/sparc/config.in

    diff -urPX nopatch linux-2.4.26/arch/sparc/config.in linux/arch/sparc/config.in
    old new  
    7474fi
    7575tristate 'Kernel support for a.out binaries' CONFIG_BINFMT_AOUT
    7676bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     77if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     78   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     79fi
    7780tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    7881bool 'SunOS binary emulation' CONFIG_SUNOS_EMUL
    7982bool 'Select task to kill on out of memory condition' CONFIG_OOM_KILLER
  • arch/sparc/defconfig

    diff -urPX nopatch linux-2.4.26/arch/sparc/defconfig linux/arch/sparc/defconfig
    old new  
    4949# CONFIG_BSD_PROCESS_ACCT is not set
    5050CONFIG_SYSCTL=y
    5151CONFIG_KCORE_ELF=y
    52 CONFIG_BINFMT_AOUT=y
     52# CONFIG_BINFMT_AOUT is not set
    5353CONFIG_BINFMT_ELF=y
    54 CONFIG_BINFMT_MISC=m
     54# CONFIG_BINFMT_ELF_AOUT is not set
     55# CONFIG_BINFMT_MISC is not set
    5556CONFIG_SUNOS_EMUL=y
    5657# CONFIG_OOM_KILLER is not set
    5758
  • arch/sparc64/config.in

    diff -urPX nopatch linux-2.4.26/arch/sparc64/config.in linux/arch/sparc64/config.in
    old new  
    7777   bool '  Kernel support for 32-bit (ie. SunOS) a.out binaries' CONFIG_BINFMT_AOUT32
    7878fi
    7979bool 'Kernel support for 64-bit ELF binaries' CONFIG_BINFMT_ELF
     80if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     81   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     82fi
    8083tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    8184bool 'SunOS binary emulation' CONFIG_SUNOS_EMUL
    8285if [ "$CONFIG_EXPERIMENTAL" = "y" ]; then
  • arch/sparc64/defconfig

    diff -urPX nopatch linux-2.4.26/arch/sparc64/defconfig linux/arch/sparc64/defconfig
    old new  
    5656CONFIG_BINFMT_ELF32=y
    5757# CONFIG_BINFMT_AOUT32 is not set
    5858CONFIG_BINFMT_ELF=y
    59 CONFIG_BINFMT_MISC=m
     59# CONFIG_BINFMT_ELF_AOUT is not set
     60# CONFIG_BINFMT_MISC is not set
    6061# CONFIG_SUNOS_EMUL is not set
    6162CONFIG_SOLARIS_EMUL=m
    6263# CONFIG_OOM_KILLER is not set
  • arch/x86_64/config.in

    diff -urPX nopatch linux-2.4.26/arch/x86_64/config.in linux/arch/x86_64/config.in
    old new  
    118118fi
    119119#tristate 'Kernel support for a.out binaries' CONFIG_BINFMT_AOUT
    120120bool 'Kernel support for ELF binaries' CONFIG_BINFMT_ELF
     121if [ "$CONFIG_BINFMT_ELF" != "n" ]; then
     122   bool '  ELF binaries with a.out format interpreters or a.out libraries' CONFIG_BINFMT_ELF_AOUT
     123fi
    121124tristate 'Kernel support for MISC binaries' CONFIG_BINFMT_MISC
    122125
    123126bool 'Power Management support' CONFIG_PM
  • arch/x86_64/defconfig

    diff -urPX nopatch linux-2.4.26/arch/x86_64/defconfig linux/arch/x86_64/defconfig
    old new  
    6767CONFIG_SYSCTL=y
    6868CONFIG_KCORE_ELF=y
    6969CONFIG_BINFMT_ELF=y
     70# CONFIG_BINFMT_ELF_AOUT is not set
    7071# CONFIG_BINFMT_MISC is not set
    7172CONFIG_PM=y
    7273CONFIG_IA32_EMULATION=y
  • fs/binfmt_elf.c

    diff -urPX nopatch linux-2.4.26/fs/binfmt_elf.c linux/fs/binfmt_elf.c
    old new  
    99 * Copyright 1993, 1994: Eric Youngdale (ericy@cais.com).
    1010 */
    1111
     12#include <linux/config.h>
    1213#include <linux/module.h>
    1314
    1415#include <linux/fs.h>
     
    4344#include <linux/elf.h>
    4445
    4546static int load_elf_binary(struct linux_binprm * bprm, struct pt_regs * regs);
     47#ifdef CONFIG_BINFMT_ELF_AOUT
    4648static int load_elf_library(struct file*);
     49#endif
    4750static unsigned long elf_map (struct file *, unsigned long, struct elf_phdr *, int, int);
    4851extern int dump_fpu (struct pt_regs *, elf_fpregset_t *);
    4952extern void dump_thread(struct pt_regs *, struct user *);
     
    7376#define ELF_PAGEOFFSET(_v) ((_v) & (ELF_MIN_ALIGN-1))
    7477#define ELF_PAGEALIGN(_v) (((_v) + ELF_MIN_ALIGN - 1) & ~(ELF_MIN_ALIGN - 1))
    7578
    76 static struct linux_binfmt elf_format = {
    77         NULL, THIS_MODULE, load_elf_binary, load_elf_library, elf_core_dump, ELF_EXEC_PAGESIZE
     79static struct linux_binfmt elf_format = {
     80        NULL, THIS_MODULE, load_elf_binary,
     81#ifdef CONFIG_BINFMT_ELF_AOUT
     82        load_elf_library,
     83#else
     84        NULL,
     85#endif
     86        elf_core_dump, ELF_EXEC_PAGESIZE
    7887};
    7988
    8089#define BAD_ADDR(x)     ((unsigned long)(x) > TASK_SIZE)
     
    369378        return error;
    370379}
    371380
     381#ifdef CONFIG_BINFMT_ELF_AOUT
    372382static unsigned long load_aout_interp(struct exec * interp_ex,
    373383                             struct file * interpreter)
    374384{
     
    413423out:
    414424        return elf_entry;
    415425}
     426#endif
    416427
    417428/*
    418429 * These are the functions used to load ELF style executables and shared
     
    420431 */
    421432
    422433#define INTERPRETER_NONE 0
     434#ifdef CONFIG_BINFMT_ELF_AOUT
    423435#define INTERPRETER_AOUT 1
     436#endif
    424437#define INTERPRETER_ELF 2
    425438
    426439
     
    444457        struct elfhdr elf_ex;
    445458        struct elfhdr interp_elf_ex;
    446459        struct exec interp_ex;
     460#ifdef CONFIG_BINFMT_ELF_AOUT
    447461        char passed_fileno[6];
     462#endif
    448463        struct files_struct *files;
    449464       
    450465        /* Get the exec-header */
     
    556571
    557572        /* Some simple consistency checks for the interpreter */
    558573        if (elf_interpreter) {
     574#ifdef CONFIG_BINFMT_ELF_AOUT
    559575                interpreter_type = INTERPRETER_ELF | INTERPRETER_AOUT;
    560576
    561577                /* Now figure out which format our binary is */
     
    563579                    (N_MAGIC(interp_ex) != ZMAGIC) &&
    564580                    (N_MAGIC(interp_ex) != QMAGIC))
    565581                        interpreter_type = INTERPRETER_ELF;
     582#else
     583                interpreter_type = INTERPRETER_ELF;
     584#endif
    566585
    567586                if (memcmp(interp_elf_ex.e_ident, ELFMAG, SELFMAG) != 0)
    568587                        interpreter_type &= ~INTERPRETER_ELF;
     
    571590                if (!interpreter_type)
    572591                        goto out_free_dentry;
    573592
     593#ifdef CONFIG_BINFMT_ELF_AOUT
    574594                /* Make sure only one type was selected */
    575595                if ((interpreter_type & INTERPRETER_ELF) &&
    576596                     interpreter_type != INTERPRETER_ELF) {
     
    578598                        // printk(KERN_WARNING "ELF: Ambiguous type, using ELF\n");
    579599                        interpreter_type = INTERPRETER_ELF;
    580600                }
     601#endif
    581602                /* Verify the interpreter has a valid arch */
    582603                if ((interpreter_type == INTERPRETER_ELF) &&
    583604                    !elf_check_arch(&interp_elf_ex))
     
    590611        /* OK, we are done with that, now set up the arg stuff,
    591612           and then start this sucker up */
    592613
     614#ifdef CONFIG_BINFMT_ELF_AOUT
    593615        if (!bprm->sh_bang) {
    594616                char * passed_p;
    595617
     
    605627                  }
    606628                }
    607629        }
     630#endif
    608631
    609632        /* Flush all traces of the currently running executable */
    610633        retval = flush_old_exec(bprm);
     
    721744        end_data += load_bias;
    722745
    723746        if (elf_interpreter) {
     747#ifdef CONFIG_BINFMT_ELF_AOUT
    724748                if (interpreter_type == INTERPRETER_AOUT)
    725749                        elf_entry = load_aout_interp(&interp_ex,
    726750                                                     interpreter);
    727751                else
     752#endif
    728753                        elf_entry = load_elf_interp(&interp_elf_ex,
    729754                                                    interpreter,
    730755                                                    &interp_load_addr);
     
    743768
    744769        kfree(elf_phdata);
    745770
     771#ifdef CONFIG_BINFMT_ELF_AOUT
    746772        if (interpreter_type != INTERPRETER_AOUT)
     773#endif
    747774                sys_close(elf_exec_fileno);
    748775
    749776        set_binfmt(&elf_format);
     
    757784                        &elf_ex,
    758785                        load_addr, load_bias,
    759786                        interp_load_addr,
     787#ifdef CONFIG_BINFMT_ELF_AOUT
    760788                        (interpreter_type == INTERPRETER_AOUT ? 0 : 1));
    761789        /* N.B. passed_fileno might not be initialized? */
    762790        if (interpreter_type == INTERPRETER_AOUT)
    763791                current->mm->arg_start += strlen(passed_fileno) + 1;
     792#else
     793                        1);
     794#endif
    764795        current->mm->start_brk = current->mm->brk = elf_brk;
    765796        current->mm->end_code = end_code;
    766797        current->mm->start_code = start_code;
     
    838869        goto out;
    839870}
    840871
     872#ifdef CONFIG_BINFMT_ELF_AOUT
    841873/* This is really simpleminded and specialized - we are loading an
    842874   a.out library that is given an ELF header. */
    843 
    844875static int load_elf_library(struct file *file)
    845876{
    846877        struct elf_phdr *elf_phdata;
     
    911942out:
    912943        return error;
    913944}
     945#endif
    914946
    915947/*
    916948 * Note that some platforms still use traditional core dumps and not
  • fs/exec.c

    diff -urPX nopatch linux-2.4.26/fs/exec.c linux/fs/exec.c
    old new  
    109109 */
    110110asmlinkage long sys_uselib(const char * library)
    111111{
     112#if defined(CONFIG_BINFMT_AOUT) || defined(CONFIG_BINFMT_ELF_AOUT)
    112113        struct file * file;
    113114        struct nameidata nd;
    114115        int error;
     
    155156exit:
    156157        path_release(&nd);
    157158        goto out;
     159#else
     160        return -ENOSYS;
     161#endif
    158162}
    159163
    160164/*
Note: See TracBrowser for help on using the repository browser.