Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src Retire USE_COMPILERCRTSTUFF=yes.



details:   https://anonhg.NetBSD.org/src/rev/97756cfee5b3
branches:  trunk
changeset: 795640:97756cfee5b3
user:      joerg <joerg%NetBSD.org@localhost>
date:      Tue Apr 22 13:20:58 2014 +0000

description:
Retire USE_COMPILERCRTSTUFF=yes.

diffstat:

 lib/Makefile                    |    8 +--
 lib/csu/Makefile                |   31 +----------
 lib/csu/README                  |    4 +-
 lib/csu/common_elf/Makefile.inc |   74 -----------------------------
 lib/csu/common_elf/common.c     |   77 ------------------------------
 lib/csu/common_elf/common.h     |   94 ------------------------------------
 lib/csu/common_elf/crti.c       |   40 ---------------
 lib/csu/common_elf/crtn.c       |   35 -------------
 lib/csu/common_elf/dot_init.h   |   48 ------------------
 lib/csu/common_elf/dwarf2_eh.h  |   70 ---------------------------
 lib/csu/ia64/Makefile           |    8 ---
 lib/csu/ia64/crt0.c             |   99 --------------------------------------
 lib/csu/ia64/dot_init.h         |   74 -----------------------------
 lib/csu/m68k_elf/Makefile       |    6 --
 lib/csu/m68k_elf/crt0.c         |  102 ----------------------------------------
 lib/csu/m68k_elf/dot_init.h     |   60 -----------------------
 share/mk/bsd.own.mk             |    8 +--
 tools/gcc/README.mknative       |   18 ++----
 18 files changed, 13 insertions(+), 843 deletions(-)

diffs (truncated from 993 to 300 lines):

diff -r fb4372d88313 -r 97756cfee5b3 lib/Makefile
--- a/lib/Makefile      Tue Apr 22 12:13:09 2014 +0000
+++ b/lib/Makefile      Tue Apr 22 13:20:58 2014 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: Makefile,v 1.212 2014/03/09 17:09:20 christos Exp $
+#      $NetBSD: Makefile,v 1.213 2014/04/22 13:20:58 joerg Exp $
 #      from: @(#)Makefile      5.25.1.1 (Berkeley) 5/7/91
 
 .include <bsd.own.mk>
@@ -7,14 +7,8 @@
 
 .if (${MKGCC} != "no")
 . if ${HAVE_GCC} == 4
-.  if (${USE_COMPILERCRTSTUFF} == "yes")
-SUBDIR+=       ../gnu/lib/crtstuff4 .WAIT
-.  endif
 SUBDIR+=       ../gnu/lib/libgcc4 .WAIT
 . else
-.  if (${USE_COMPILERCRTSTUFF} == "yes")
-SUBDIR+=       ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/crtstuff .WAIT
-.  endif
 SUBDIR+=       ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libgcc .WAIT
 . endif
 .endif
diff -r fb4372d88313 -r 97756cfee5b3 lib/csu/Makefile
--- a/lib/csu/Makefile  Tue Apr 22 12:13:09 2014 +0000
+++ b/lib/csu/Makefile  Tue Apr 22 13:20:58 2014 +0000
@@ -1,9 +1,7 @@
-#      $NetBSD: Makefile,v 1.33 2013/09/10 16:45:33 matt Exp $
+#      $NetBSD: Makefile,v 1.34 2014/04/22 13:20:58 joerg Exp $
 
 .include <bsd.own.mk>
 
-.if ${USE_COMPILERCRTSTUFF} != "yes"
-
 CSU_MACHINE_ARCH?=     ${MACHINE_ARCH}
 
 .if !empty(CSU_MACHINE_ARCH:Mearm*)
@@ -18,28 +16,5 @@
 
 
 .PATH: ${ARCHDIR}
-.  include "${ARCHDIR}/Makefile.inc"
-
-.  include "${.CURDIR}/common/Makefile.inc"
-
-.else
-
-CSU_MACHINE_ARCH?=     ${MACHINE_ARCH}
-
-.  if exists(${CSU_MACHINE_ARCH}_elf/Makefile)
-SUBDIR=        ${CSU_MACHINE_ARCH}_elf
-.  elif exists(${CSU_MACHINE_ARCH}/Makefile)
-SUBDIR=        ${CSU_MACHINE_ARCH}
-.  elif exists(${MACHINE_CPU}_elf/Makefile)
-SUBDIR=        ${MACHINE_CPU}_elf
-.  elif exists(${MACHINE_CPU}/Makefile)
-SUBDIR=        ${MACHINE_CPU}
-.  else
-.BEGIN:
-       @echo no SUBDIR for ${MACHINE_ARCH}_elf, ${MACHINE_ARCH} nor \
-           ${MACHINE_CPU}
-       @false
-.  endif
-
-.  include <bsd.subdir.mk>
-.endif
+.include "${ARCHDIR}/Makefile.inc"
+.include "${.CURDIR}/common/Makefile.inc"
diff -r fb4372d88313 -r 97756cfee5b3 lib/csu/README
--- a/lib/csu/README    Tue Apr 22 12:13:09 2014 +0000
+++ b/lib/csu/README    Tue Apr 22 13:20:58 2014 +0000
@@ -1,8 +1,6 @@
 Introduction
 
-This document covers the native NetBSD compiler runtime. The full support
-for the native runtime is enabled by setting USE_COMPILERCRTSTUFF to no
-in bsd.own.mk.
+This document covers the native NetBSD compiler runtime.
 
 Machine independent sources can be found in common. The crtbegin.c in
 that directory is a useful template for deriving compact assembler
diff -r fb4372d88313 -r 97756cfee5b3 lib/csu/common_elf/Makefile.inc
--- a/lib/csu/common_elf/Makefile.inc   Tue Apr 22 12:13:09 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,74 +0,0 @@
-#      $NetBSD: Makefile.inc,v 1.35 2012/08/04 14:59:05 matt Exp $
-
-.if !defined(ELFSIZE)
-ELFSIZE=32
-.endif
-
-.include "../../Makefile.inc"
-
-CPPFLAGS+=     -DLIBC_SCCS -DPIC -DDYNAMIC -DELFSIZE=${ELFSIZE}
-CPPFLAGS+=     -I${NETBSDSRCDIR}/libexec/ld.elf_so
-CPPFLAGS+=     -I${.CURDIR}/../common_elf
-CPPFLAGS+=     -I${NETBSDSRCDIR}/lib/libc/dlfcn
-CPPFLAGS+=     -DDWARF2_EH
-CPPFLAGS+=     -DJCR
-CPPFLAGS+=     -DDSO_HANDLE
-
-.if defined(HAVE_GCC)
-COPTS+=                -fno-unit-at-a-time
-.endif
-
-.include <bsd.own.mk>
-
-.PATH:         ${.CURDIR}/../common_elf
-
-SRCS+=         crt0.c crti.c crtn.c
-OBJS+=         crt0.o gcrt0.o crti.o crtn.o
-.if ${MKPIC} != "no"
-COPTS+=                -fPIC
-.endif
-
-realall: ${OBJS}
-
-crt0.o: crt0.c
-       ${_MKTARGET_COMPILE}
-       ${COMPILE.c} -DCRT0 ${.IMPSRC} -o ${.TARGET}.o
-       ${LD} -x -r -o ${.TARGET} ${.TARGET}.o
-       rm -f ${.TARGET}.o
-.if ${MKSTRIPIDENT} != "no"
-       ${OBJCOPY} -R .ident ${.TARGET}
-.endif
-
-# dependent on crt0.o to pick up header dependencies
-gcrt0.o: ${.CURDIR}/crt0.c crt0.o
-       ${_MKTARGET_COMPILE}
-       ${COMPILE.c} -DMCRT0 ${.CURDIR}/crt0.c -o ${.TARGET}.o
-       ${LD} -x -r -o ${.TARGET} ${.TARGET}.o
-       rm -f ${.TARGET}.o
-.if ${MKSTRIPIDENT} != "no"
-       ${OBJCOPY} -R .ident ${.TARGET}
-.endif
-
-crti.o: crti.c
-       ${_MKTARGET_COMPILE}
-       ${COMPILE.c} -DCRTI ${.IMPSRC} -o ${.TARGET}.o
-       ${LD} -X -r -o ${.TARGET} ${.TARGET}.o
-       rm -f ${.TARGET}.o
-.if ${MKSTRIPIDENT} != "no"
-       ${OBJCOPY} -R .ident ${.TARGET}
-.endif
-
-crtn.o: crtn.c
-       ${_MKTARGET_COMPILE}
-       ${COMPILE.c} -DCRTN ${.IMPSRC} -o ${.TARGET}.o
-       ${LD} -X -r -o ${.TARGET} ${.TARGET}.o
-       rm -f ${.TARGET}.o
-.if ${MKSTRIPIDENT} != "no"
-       ${OBJCOPY} -R .ident ${.TARGET}
-.endif
-
-FILES=${OBJS}
-FILESDIR=${LIBDIR}
-CLEANFILES=${OBJS}
-
-.include <bsd.prog.mk>
diff -r fb4372d88313 -r 97756cfee5b3 lib/csu/common_elf/common.c
--- a/lib/csu/common_elf/common.c       Tue Apr 22 12:13:09 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,77 +0,0 @@
-/* $NetBSD: common.c,v 1.17 2005/12/24 22:53:15 perry Exp $ */
-
-/*
- * Copyright (c) 1995 Christopher G. Demetriou
- * All rights reserved.
- * 
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *          This product includes software developed for the
- *          NetBSD Project.  See http://www.NetBSD.org/ for
- *          information about NetBSD.
- * 4. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
- * 
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- * 
- * <<Id: LICENSE,v 1.2 2000/06/14 15:57:33 cgd Exp>>
- */
-
-/*
- * NOT A STANDALONE FILE!
- */
-
-static char *
-_strrchr(char *p, int ch)
-{
-       char *save;
-
-       for (save = NULL;; ++p) {
-               if (*p == ch)
-                       save = (char *)p;
-               if (!*p)
-                       return(save);
-       }
-       /* NOTREACHED */
-}
-
-#ifdef MCRT0
-__asm ("  .text");
-#ifdef EPROL_EXPORT
-EPROL_EXPORT;
-#endif
-__asm ("_eprol:");
-#endif
-
-#ifdef DYNAMIC
-
-void
-_rtld_setup(void (*cleanup)(void), const Obj_Entry *obj)
-{
-
-       if ((obj == NULL) || (obj->magic != RTLD_MAGIC))
-               _FATAL("Corrupt Obj_Entry pointer in GOT\n");
-       if (obj->version != RTLD_VERSION)
-               _FATAL("Dynamic linker version mismatch\n");
-
-       atexit(cleanup);
-}
-
-#endif /* DYNAMIC */
diff -r fb4372d88313 -r 97756cfee5b3 lib/csu/common_elf/common.h
--- a/lib/csu/common_elf/common.h       Tue Apr 22 12:13:09 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,94 +0,0 @@
-/* $NetBSD: common.h,v 1.16 2012/03/21 10:09:20 matt Exp $ */
-
-/*
- * Copyright (c) 1995 Christopher G. Demetriou
- * All rights reserved.
- * 
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *          This product includes software developed for the
- *          NetBSD Project.  See http://www.NetBSD.org/ for
- *          information about NetBSD.
- * 4. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
- * 
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- * 
- * <<Id: LICENSE,v 1.2 2000/06/14 15:57:33 cgd Exp>>
- */
-
-#include <sys/types.h>
-#include <sys/exec.h>
-#include <sys/syscall.h>
-
-#include <stdlib.h>
-#ifdef DYNAMIC
-#ifdef __weak_alias
-#define dlopen _dlopen
-#define dlclose        _dlclose
-#define dlsym  _dlsym
-#define dlerror        _dlerror
-#define dladdr _dladdr
-#endif
-#include <dlfcn.h>
-#include "rtld.h"
-#else
-typedef void Obj_Entry;
-#endif
-



Home | Main Index | Thread Index | Old Index