Source-Changes-HG archive

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

[src/trunk]: src/share/mk Revert poor change



details:   https://anonhg.NetBSD.org/src/rev/d5a55b8ebd51
branches:  trunk
changeset: 783202:d5a55b8ebd51
user:      pooka <pooka%NetBSD.org@localhost>
date:      Mon Dec 10 23:48:38 2012 +0000

description:
Revert poor change

diffstat:

 share/mk/bsd.gcc.mk |  30 +++++++++++-------------------
 1 files changed, 11 insertions(+), 19 deletions(-)

diffs (45 lines):

diff -r a0ec3ac75194 -r d5a55b8ebd51 share/mk/bsd.gcc.mk
--- a/share/mk/bsd.gcc.mk       Mon Dec 10 20:58:55 2012 +0000
+++ b/share/mk/bsd.gcc.mk       Mon Dec 10 23:48:38 2012 +0000
@@ -1,30 +1,22 @@
-#      $NetBSD: bsd.gcc.mk,v 1.8 2012/12/10 20:58:55 pooka Exp $
+#      $NetBSD: bsd.gcc.mk,v 1.9 2012/12/10 23:48:38 pooka Exp $
 
 .if !defined(_BSD_GCC_MK_)
 _BSD_GCC_MK_=1
 
 .if defined(EXTERNAL_TOOLCHAIN)
 _GCC_CRTBEGIN!=                ${CC} --print-file-name=crtbegin.o
+.ifndef _GCC_CRTBEGINS
+_GCC_CRTBEGINS!=       ${CC} --print-file-name=crtbeginS.o
+.endif
 _GCC_CRTEND!=          ${CC} --print-file-name=crtend.o
-
-# If the toolchain does not know about a file, --print-file-name echoes
-# the input file name (why??).  In that case we want an empty string for
-# dependencies to work correctly.  Note: do _not_ use TOOL_SED here because
-# this file is used before TOOL_SED is built.
-_GCC_CRTBEGINS!=       ${CC} --print-file-name=crtbeginS.o             \
-                           | sed 's|^crtbeginS.o$$||'
-_GCC_CRTENDS!=         ${CC} --print-file-name=crtendS.o               \
-                           | sed 's|^crtendS.o$$||'
-_GCC_CRTI!=            ${CC} --print-file-name=crti.o                  \
-                           | sed 's|^crti.o$$||'
-_GCC_CRTN!=            ${CC} --print-file-name=crtn.o                  \
-                           | sed 's|^crtn.o$$||'
-
-_GCC_CRTDIR!=          dirname ${_GCC_CRTBEGIN}
-_GCC_LIBGCCDIR!=       dirname `${CC} --print-libgcc-file-name`
-
+.ifndef _GCC_CRTENDS
+_GCC_CRTENDS!=         ${CC} --print-file-name=crtendS.o
+.endif
+_GCC_CRTI!=            ${CC} --print-file-name=crti.o
+_GCC_CRTN!=            ${CC} --print-file-name=crtn.o
+_GCC_CRTDIR!=          dirname ${_GCC_CRTBEGIN}
+_GCC_LIBGCCDIR!=       dirname `${CC} --print-libgcc-file-name`
 .else
-
 _GCC_CRTBEGIN?=                ${DESTDIR}/usr/lib/crtbegin.o
 _GCC_CRTBEGINS?=       ${DESTDIR}/usr/lib/crtbeginS.o
 _GCC_CRTEND?=          ${DESTDIR}/usr/lib/crtend.o



Home | Main Index | Thread Index | Old Index