Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src remove almost all the ability to build netbsd with an a.out ...
details: https://anonhg.NetBSD.org/src/rev/043e4cc35698
branches: trunk
changeset: 756073:043e4cc35698
user: mrg <mrg%NetBSD.org@localhost>
date: Tue Jul 06 05:59:50 2010 +0000
description:
remove almost all the ability to build netbsd with an a.out target.
we're ELF now, and there are many missing checks against OBJECT_FMT.
if we ever consider switching, the we can figure out what new ones
we need but for now it's just clutter.
this doesn't remove any of the support for exec_aout or any actually
required-for-boot a.out support, only the ability to build a netbsd
release in a.out format. ie, most of this code has been dead for
over a decade.
i've tested builds on vax, amd64, i386, mac68k, macppc, sparc, atari,
amiga, shark, cats, dreamcast, landisk, mmeye and x68k. this covers
the 5 MACHINE_ARCH's affected, and all the other arch code touched.
it also includes some actual run-time testing of sparc, i386 and
shark, and i performed binary comparison upon amiga and x68k as well.
some minor details relevant:
- move shlib.[ch] from ld.aout_so into ldconfig proper, and cut them
down to only the parts ldconfig needs
- remove various unused source files
- switch amiga bootblocks to using elf2bb.h instead of aout2bb.h
diffstat:
Makefile | 7 +-
crypto/external/bsd/openssl/lib/libcrypto/Makefile | 12 +-
crypto/external/bsd/openssl/lib/libcrypto_idea/Makefile | 7 +-
crypto/external/bsd/openssl/lib/libcrypto_mdc2/Makefile | 7 +-
crypto/external/bsd/openssl/lib/libcrypto_rc5/Makefile | 7 +-
crypto/external/bsd/openssl/lib/libssl/Makefile | 7 +-
gnu/lib/crtstuff4/Makefile | 6 +-
gnu/lib/libstdc++-v3_4/Makefile | 7 +-
gnu/lib/libsupc++4/Makefile | 7 +-
gnu/usr.bin/Makefile | 3 +-
lib/libc/arch/arm/Makefile.inc | 8 +-
lib/libc/arch/vax/Makefile.inc | 4 +-
lib/libc/arch/vax/gen/Makefile.inc | 6 +-
lib/libc/compat/arch/vax/Makefile.inc | 3 +-
lib/libc/compat/arch/vax/gen/Makefile.inc | 6 -
lib/libc/dlfcn/Makefile.inc | 4 +-
lib/libcrypto_idea/Makefile | 7 +-
lib/libcrypto_mdc2/Makefile | 7 +-
lib/libcrypto_rc5/Makefile | 7 +-
lib/libroken/Makefile | 7 +-
lib/libterminfo/Makefile | 6 +-
libexec/ld.aout_so/Makefile | 49 +-
libexec/ld.aout_so/arch/arm32/md-static-funcs.c | 71 -
libexec/ld.aout_so/arch/arm32/md.c | 486 ---
libexec/ld.aout_so/arch/arm32/md.h | 261 --
libexec/ld.aout_so/arch/arm32/mdprologue.S | 92 -
libexec/ld.aout_so/arch/i386/md-static-funcs.c | 17 -
libexec/ld.aout_so/arch/i386/md.c | 364 --
libexec/ld.aout_so/arch/i386/md.h | 225 -
libexec/ld.aout_so/arch/i386/mdprologue.S | 92 -
libexec/ld.aout_so/arch/m68k/md-static-funcs.c | 18 -
libexec/ld.aout_so/arch/m68k/md.c | 377 --
libexec/ld.aout_so/arch/m68k/md.h | 188 -
libexec/ld.aout_so/arch/m68k/mdprologue.S | 81 -
libexec/ld.aout_so/arch/powerpc/md-static-funcs.c | 17 -
libexec/ld.aout_so/arch/powerpc/md.c | 290 --
libexec/ld.aout_so/arch/powerpc/md.h | 224 -
libexec/ld.aout_so/arch/powerpc/mdprologue.S | 21 -
libexec/ld.aout_so/arch/sparc/md-static-funcs.c | 38 -
libexec/ld.aout_so/arch/sparc/md.c | 354 --
libexec/ld.aout_so/arch/sparc/md.h | 301 --
libexec/ld.aout_so/arch/sparc/mdprologue.S | 117 -
libexec/ld.aout_so/arch/vax/md-static-funcs.c | 17 -
libexec/ld.aout_so/arch/vax/md.c | 406 ---
libexec/ld.aout_so/arch/vax/md.h | 232 -
libexec/ld.aout_so/arch/vax/mdprologue.S | 104 -
libexec/ld.aout_so/ld.h | 152 -
libexec/ld.aout_so/malloc.c | 479 ---
libexec/ld.aout_so/md-prologue.c | 40 -
libexec/ld.aout_so/rtld.c | 1910 ---------------
libexec/ld.aout_so/shlib.c | 413 ---
libexec/ld.aout_so/shlib.h | 50 -
libexec/ld.elf_so/Makefile | 6 +-
regress/lib/csu/initfini/Makefile | 6 +-
regress/sys/arch/arm/Makefile | 5 +-
sbin/ldconfig/Makefile | 11 +-
sbin/ldconfig/shlib.c | 224 +
sbin/ldconfig/shlib.h | 45 +
share/mk/bsd.lib.mk | 17 +-
share/mk/bsd.own.mk | 5 +-
share/mk/bsd.prog.mk | 12 +-
sys/arch/amiga/stand/bootblock/Makefile | 6 +-
sys/arch/amiga/stand/bootblock/Makefile.booters | 11 +-
sys/arch/amiga/stand/bootblock/aout2bb/Makefile | 7 -
sys/arch/amiga/stand/bootblock/aout2bb/aout2bb.c | 353 --
sys/arch/amiga/stand/bootblock/aout2bb/aout2bb.h | 67 -
sys/arch/amiga/stand/bootblock/aout2bb/chksum.c | 83 -
sys/arch/amiga/stand/bootblock/aout2bb/chksum.h | 35 -
sys/arch/amiga/stand/bootblock/boot/bbstart.s | 8 +-
sys/arch/atari/stand/bootxx/Makefile.bootxx | 7 +-
sys/arch/atari/stand/bootxx/milan/Makefile | 3 +-
sys/arch/atari/stand/bootxx/std/Makefile | 3 +-
sys/arch/atari/stand/bootxxx/Makefile.bootxxx | 7 +-
sys/arch/atari/stand/bootxxx/milan/Makefile | 3 +-
sys/arch/atari/stand/bootxxx/std/Makefile | 3 +-
sys/arch/cats/conf/Makefile.cats.inc | 5 +-
sys/arch/dreamcast/conf/Makefile.dreamcast.inc | 4 +-
sys/arch/i386/bioscall/Makefile | 14 +-
sys/arch/i386/bioscall/rmaouthdr | 4 -
sys/arch/i386/conf/Makefile.i386 | 6 +-
sys/arch/i386/stand/Makefile.booters | 6 +-
sys/arch/landisk/conf/Makefile.landisk.inc | 4 +-
sys/arch/mmeye/conf/Makefile.mmeye.inc | 4 +-
sys/arch/shark/conf/Makefile.shark.inc | 5 +-
sys/arch/sparc/conf/Makefile.sparc | 6 +-
sys/arch/x68k/stand/boot/Makefile | 6 +-
sys/arch/x68k/stand/boot_ufs/Makefile | 13 +-
sys/arch/x68k/stand/boot_ustar/Makefile | 29 +-
sys/arch/xen/conf/Makefile.xen | 6 +-
tools/amiga-aout2bb/Makefile | 8 -
tools/amiga-aout2bb/machine/aout_machdep.h | 58 -
tools/amiga-aout2bb/sys/exec_aout.h | 214 -
usr.bin/xlint/lint1/Makefile | 12 +-
93 files changed, 336 insertions(+), 8616 deletions(-)
diffs (truncated from 9938 to 300 lines):
diff -r 436d04db0fd0 -r 043e4cc35698 Makefile
--- a/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.277 2010/06/10 22:41:41 pooka Exp $
+# $NetBSD: Makefile,v 1.278 2010/07/06 05:59:50 mrg Exp $
#
# This is the top-level makefile for building NetBSD. For an outline of
@@ -467,12 +467,7 @@
do-ld.so: .PHONY .MAKE
.for targ in dependall install
-.if (${OBJECT_FMT} == "a.out")
- ${MAKEDIRTARGET} libexec/ld.aout_so ${targ}
-.endif
-.if (${OBJECT_FMT} == "ELF")
${MAKEDIRTARGET} libexec/ld.elf_so ${targ}
-.endif
.endfor
do-build: .PHONY .MAKE
diff -r 436d04db0fd0 -r 043e4cc35698 crypto/external/bsd/openssl/lib/libcrypto/Makefile
--- a/crypto/external/bsd/openssl/lib/libcrypto/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/crypto/external/bsd/openssl/lib/libcrypto/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2009/07/19 23:30:42 christos Exp $
+# $NetBSD: Makefile,v 1.2 2010/07/06 05:59:50 mrg Exp $
# RCSid:
# Id: Makefile,v 1.33 1998/11/11 11:53:53 sjg Exp
@@ -38,18 +38,8 @@
.include "srcs.inc"
-# XXX
-.if ${OBJECT_FMT} == "ELF"
AFLAGS+=-DELF
LIBDPLIBS+= crypt ${NETBSDSRCDIR}/lib/libcrypt
-.else
-AFLAGS+=-DOUT
-# XXX: This is broken because we compile with the wrong des headers.
-# NetBSD's crypt(3) library, in lieu of the one included with OpenSSL,
-# since NetBSD's also supports MD5, SHA1 and Blowfish passwords.
-.PATH: ${NETBSDSRCDIR}/lib/libcrypt
-SRCS+= crypt.c md5crypt.c bcrypt.c crypt-sha1.c util.c
-.endif
OS_VERSION!= ${HOST_SH} ${NETBSDSRCDIR}/sys/conf/osrelease.sh
diff -r 436d04db0fd0 -r 043e4cc35698 crypto/external/bsd/openssl/lib/libcrypto_idea/Makefile
--- a/crypto/external/bsd/openssl/lib/libcrypto_idea/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/crypto/external/bsd/openssl/lib/libcrypto_idea/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2009/07/19 23:30:56 christos Exp $
+# $NetBSD: Makefile,v 1.2 2010/07/06 05:59:50 mrg Exp $
# RCSid:
# Id: Makefile,v 1.33 1998/11/11 11:53:53 sjg Exp
@@ -37,11 +37,6 @@
CPPFLAGS+= -I${OPENSSLSRC}/crypto/idea
SRCS+= i_cbc.c i_skey.c e_idea.c c_allc.c
-# XXX
-.if ${OBJECT_FMT} == "ELF"
AFLAGS+= -DELF
-.else
-AFLAGS+= -DOUT
-.endif
.include <bsd.lib.mk>
diff -r 436d04db0fd0 -r 043e4cc35698 crypto/external/bsd/openssl/lib/libcrypto_mdc2/Makefile
--- a/crypto/external/bsd/openssl/lib/libcrypto_mdc2/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/crypto/external/bsd/openssl/lib/libcrypto_mdc2/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2009/07/19 23:30:56 christos Exp $
+# $NetBSD: Makefile,v 1.2 2010/07/06 05:59:50 mrg Exp $
# RCSid:
# Id: Makefile,v 1.33 1998/11/11 11:53:53 sjg Exp
@@ -37,11 +37,6 @@
CPPFLAGS+= -I${OPENSSLSRC}/crypto/mdc2
SRCS+= mdc2dgst.c
-# XXX
-.if ${OBJECT_FMT} == "ELF"
AFLAGS+= -DELF
-.else
-AFLAGS+= -DOUT
-.endif
.include <bsd.lib.mk>
diff -r 436d04db0fd0 -r 043e4cc35698 crypto/external/bsd/openssl/lib/libcrypto_rc5/Makefile
--- a/crypto/external/bsd/openssl/lib/libcrypto_rc5/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/crypto/external/bsd/openssl/lib/libcrypto_rc5/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2009/07/19 23:30:57 christos Exp $
+# $NetBSD: Makefile,v 1.2 2010/07/06 05:59:51 mrg Exp $
# RCSid:
# Id: Makefile,v 1.33 1998/11/11 11:53:53 sjg Exp
@@ -37,11 +37,6 @@
CPPFLAGS+= -I${OPENSSLSRC}/crypto/rc5
SRCS+= rc5_skey.c rc5_enc.c e_rc5.c c_allc.c
-# XXX
-.if ${OBJECT_FMT} == "ELF"
AFLAGS+= -DELF
-.else
-AFLAGS+= -DOUT
-.endif
.include <bsd.lib.mk>
diff -r 436d04db0fd0 -r 043e4cc35698 crypto/external/bsd/openssl/lib/libssl/Makefile
--- a/crypto/external/bsd/openssl/lib/libssl/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/crypto/external/bsd/openssl/lib/libssl/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.1 2009/07/19 23:30:58 christos Exp $
+# $NetBSD: Makefile,v 1.2 2010/07/06 05:59:51 mrg Exp $
# RCSid:
# Id: Makefile,v 1.33 1998/11/11 11:53:53 sjg Exp
@@ -35,12 +35,7 @@
LIBDPLIBS+=crypto ${.CURDIR}/../libcrypto
-# XXX
-.if ${OBJECT_FMT} == "ELF"
AFLAGS+=-DELF
-.else
-AFLAGS+=-DOUT
-.endif
# This is from the include/openssl directory; see ../libcrypto/Makefile
INCS= dtls1.h ssl.h ssl2.h ssl3.h ssl23.h tls1.h kssl.h
diff -r 436d04db0fd0 -r 043e4cc35698 gnu/lib/crtstuff4/Makefile
--- a/gnu/lib/crtstuff4/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/gnu/lib/crtstuff4/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.4 2009/12/17 07:24:06 mrg Exp $
+# $NetBSD: Makefile,v 1.5 2010/07/06 05:59:51 mrg Exp $
REQUIRETOOLS= yes
NOLINT= # defined
@@ -7,7 +7,7 @@
# If using an external toolchain, we expect crtbegin/crtend to be
# supplied by that toolchain's run-time support.
-.if !defined(EXTERNAL_TOOLCHAIN) && ${MKGCC} != "no" && ${OBJECT_FMT} == "ELF"
+.if !defined(EXTERNAL_TOOLCHAIN) && ${MKGCC} != "no"
DIST= ${NETBSDSRCDIR}/gnu/dist/gcc4
GNUHOSTDIST= ${DIST}
@@ -79,4 +79,4 @@
.include <bsd.prog.mk> # do nothing
-.endif # ! EXTERNAL_TOOLCHAIN && MKGCC != no && OBJECT_FMT == ELF
+.endif # ! EXTERNAL_TOOLCHAIN && MKGCC != no
diff -r 436d04db0fd0 -r 043e4cc35698 gnu/lib/libstdc++-v3_4/Makefile
--- a/gnu/lib/libstdc++-v3_4/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/gnu/lib/libstdc++-v3_4/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.5 2010/06/25 16:54:25 joerg Exp $
+# $NetBSD: Makefile,v 1.6 2010/07/06 05:59:51 mrg Exp $
REQUIRETOOLS= yes
NOLINT= # defined
@@ -129,8 +129,3 @@
.else
.include <bsd.prog.mk> # do nothing
.endif
-
-.if (${OBJECT_FMT} == "a.out")
-LDADD= ${DESTDIR}/usr/lib/c++rt0.o
-DPADD= ${DESTDIR}/usr/lib/c++rt0.o
-.endif
diff -r 436d04db0fd0 -r 043e4cc35698 gnu/lib/libsupc++4/Makefile
--- a/gnu/lib/libsupc++4/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/gnu/lib/libsupc++4/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.3 2009/01/11 03:09:35 christos Exp $
+# $NetBSD: Makefile,v 1.4 2010/07/06 05:59:51 mrg Exp $
REQUIRETOOLS= yes
NOLINT= # defined
@@ -41,8 +41,3 @@
.else
.include <bsd.prog.mk> # do nothing
.endif
-
-.if (${OBJECT_FMT} == "a.out")
-LDADD= ${DESTDIR}/usr/lib/c++rt0.o
-DPADD= ${DESTDIR}/usr/lib/c++rt0.o
-.endif
diff -r 436d04db0fd0 -r 043e4cc35698 gnu/usr.bin/Makefile
--- a/gnu/usr.bin/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/gnu/usr.bin/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,6 +1,5 @@
-# $NetBSD: Makefile,v 1.132 2009/12/14 13:39:33 uebayasi Exp $
+# $NetBSD: Makefile,v 1.133 2010/07/06 05:59:51 mrg Exp $
-# for OBJECT_FMT
.include <bsd.own.mk>
SUBDIR+= bc
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/arch/arm/Makefile.inc
--- a/lib/libc/arch/arm/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libc/arch/arm/Makefile.inc Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.8 2006/06/17 18:04:23 uwe Exp $
+# $NetBSD: Makefile.inc,v 1.9 2010/07/06 05:59:52 mrg Exp $
.include <bsd.own.mk>
@@ -6,11 +6,5 @@
CPPFLAGS += -DSOFTFLOAT
-.if ${OBJECT_FMT} != "ELF"
-# arm32 a.out libc contained __fixunssfsi() and __fixunsdfsi(). Be
-# compatible.
-CPPFLAGS+= -DSOFTFLOAT_NEED_FIXUNS
-.endif
-
SOFTFLOAT_BITS=32
.include <softfloat/Makefile.inc>
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/arch/vax/Makefile.inc
--- a/lib/libc/arch/vax/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libc/arch/vax/Makefile.inc Tue Jul 06 05:59:50 2010 +0000
@@ -1,8 +1,6 @@
-# $NetBSD: Makefile.inc,v 1.8 2006/02/18 22:54:51 matt Exp $
+# $NetBSD: Makefile.inc,v 1.9 2010/07/06 05:59:52 mrg Exp $
-.if ${OBJECT_FMT} == "ELF"
SRCS+= __longjmp14.c
-.endif
SRCS+= __sigaction14_sigtramp.c __sigtramp3.S
CPPFLAGS+= -I.
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/arch/vax/gen/Makefile.inc
--- a/lib/libc/arch/vax/gen/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libc/arch/vax/gen/Makefile.inc Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.16 2009/12/06 07:12:18 uebayasi Exp $
+# $NetBSD: Makefile.inc,v 1.17 2010/07/06 05:59:52 mrg Exp $
SRCS+= byte_swap_2.S byte_swap_4.S bswap64.S \
fabs.S frexp.c \
@@ -16,10 +16,6 @@
# ABI compatibility for libc.so.12
SRCS+= isinf.c isnan.c
-.if ${OBJECT_FMT} != "ELF"
-SRCS+= setjmp.S sigsetjmp.S
-.endif
-
LSRCS.vax.gen= Lint_bswap16.c Lint_bswap32.c Lint_bswap64.c
LSRCS+= ${LSRCS.vax.gen}
DPSRCS+= ${LSRCS.vax.gen}
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/compat/arch/vax/Makefile.inc
--- a/lib/libc/compat/arch/vax/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libc/compat/arch/vax/Makefile.inc Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,3 @@
-# $NetBSD: Makefile.inc,v 1.2 2006/03/11 23:04:04 christos Exp $
+# $NetBSD: Makefile.inc,v 1.3 2010/07/06 05:59:52 mrg Exp $
-.include "${COMPATARCHDIR}/gen/Makefile.inc"
.include "${COMPATARCHDIR}/sys/Makefile.inc"
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/compat/arch/vax/gen/Makefile.inc
--- a/lib/libc/compat/arch/vax/gen/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,6 +0,0 @@
-# $NetBSD: Makefile.inc,v 1.1 2006/02/18 22:54:51 matt Exp $
-
-# objects built from assembler sources (need lint stubs)
-.if ${OBJECT_FMT} != "ELF"
-SRCS+= compat_setjmp.S compat_sigsetjmp.S
-.endif
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libc/dlfcn/Makefile.inc
--- a/lib/libc/dlfcn/Makefile.inc Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libc/dlfcn/Makefile.inc Tue Jul 06 05:59:50 2010 +0000
@@ -1,9 +1,7 @@
-# $NetBSD: Makefile.inc,v 1.2 2002/08/19 09:41:28 lukem Exp $
+# $NetBSD: Makefile.inc,v 1.3 2010/07/06 05:59:52 mrg Exp $
.PATH: ${.CURDIR}/dlfcn
-.if ${OBJECT_FMT} == "ELF"
CPPFLAGS+= -I${NETBSDSRCDIR}/libexec/ld.elf_so
CPPFLAGS+= -I${.CURDIR}/dlfcn
SRCS+= dlfcn_elf.c
-.endif
diff -r 436d04db0fd0 -r 043e4cc35698 lib/libcrypto_idea/Makefile
--- a/lib/libcrypto_idea/Makefile Tue Jul 06 04:15:44 2010 +0000
+++ b/lib/libcrypto_idea/Makefile Tue Jul 06 05:59:50 2010 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.6 2002/09/01 06:01:13 onoe Exp $
+# $NetBSD: Makefile,v 1.7 2010/07/06 05:59:52 mrg Exp $
Home |
Main Index |
Thread Index |
Old Index