From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) by sourceware.org (Postfix) with ESMTP id 16B4E3858429 for ; Sun, 23 Jan 2022 06:04:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 16B4E3858429 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org Received: by smtp.gentoo.org (Postfix, from userid 559) id 8B785343164; Sun, 23 Jan 2022 06:04:39 +0000 (UTC) From: Mike Frysinger To: newlib@sourceware.org Subject: [PATCH 5/7] newlib: libc: install CRT0 straight out of subdir Date: Sun, 23 Jan 2022 01:04:27 -0500 Message-Id: <20220123060429.16293-6-vapier@gentoo.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220123060429.16293-1-vapier@gentoo.org> References: <20220123060429.16293-1-vapier@gentoo.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: newlib@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Newlib mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Jan 2022 06:04:41 -0000 There's no need to have a sys/ subdir just to copy the sys/$arch/crt0.o up to sys/crt0.o, and then have libc/ copy sys/crt0.o up again. Just have libc/ refer to sys/$arch/crt0.o directly and drop the intermediate makefile entirely. --- newlib/libc/Makefile.am | 10 +- newlib/libc/Makefile.in | 14 +- newlib/libc/configure | 5 +- newlib/libc/configure.ac | 4 +- newlib/libc/sys/Makefile.am | 16 -- newlib/libc/sys/Makefile.in | 452 ------------------------------------ 6 files changed, 10 insertions(+), 491 deletions(-) delete mode 100644 newlib/libc/sys/Makefile.am delete mode 100644 newlib/libc/sys/Makefile.in diff --git a/newlib/libc/Makefile.am b/newlib/libc/Makefile.am index a57c501b9d46..7807291ba3ad 100644 --- a/newlib/libc/Makefile.am +++ b/newlib/libc/Makefile.am @@ -38,7 +38,7 @@ endif # The order of SUBDIRS is important for the integrated documentation. # Do not change the order without considering the doc impact. -SUBDIRS = argz stdlib ctype search $(STDIO_SUBDIR) $(STDIO64_SUBDIR) string $(SIGNAL_SUBDIR) sys time locale reent \ +SUBDIRS = argz stdlib ctype search $(STDIO_SUBDIR) $(STDIO64_SUBDIR) string $(SIGNAL_SUBDIR) time locale reent \ errno misc $(UNIX_SUBDIR) $(POSIX_SUBDIR) $(SYSCALLS_SUBDIR) $(NEWLIB_ICONV_DIRS) \ $(XDR_SUBDIR) ssp if HAVE_SYS_DIR @@ -124,12 +124,6 @@ endif # USE_LIBTOOL $(SUBLIBS): ; @true -crt0.o: sys/crt0.o - rm -f $@ - ln sys/crt0.o $@ >/dev/null 2>/dev/null || cp sys/crt0.o $@ - -sys/crt0.o: ; @true - # This is a list of the stmp-def files in each subdirectory which # builds .def files. We don't list subdirectories which don't build # .def files; if the list of subdirectories changes, we must change @@ -242,7 +236,7 @@ install-man: man .PHONY: force force: -CLEANFILES = $(CRT0) \ +CLEANFILES = \ sigset.texi stmp-sigset \ stdio64.texi stmp-stdio64 targetdep.tex stmp-targetdep \ tmp-sigset.texi tmp-iconvset.texi \ diff --git a/newlib/libc/configure.ac b/newlib/libc/configure.ac index 290e259299af..8ca783d84a85 100644 --- a/newlib/libc/configure.ac +++ b/newlib/libc/configure.ac @@ -60,7 +60,7 @@ fi CRT0= if test "x${have_crt0}" = "xyes"; then - CRT0=crt0.o + CRT0=sys/${sys_dir}/crt0.o fi AC_SUBST(CRT0) @@ -293,5 +293,5 @@ AC_SUBST(LIBC_MACHINE_LIB) AC_SUBST(machine_dir) AC_SUBST(shared_machine_dir) -AC_CONFIG_FILES([Makefile argz/Makefile ctype/Makefile errno/Makefile locale/Makefile misc/Makefile reent/Makefile search/Makefile stdio/Makefile stdio64/Makefile stdlib/Makefile string/Makefile time/Makefile posix/Makefile signal/Makefile syscalls/Makefile unix/Makefile iconv/Makefile iconv/ces/Makefile iconv/ccs/Makefile iconv/ccs/binary/Makefile iconv/lib/Makefile ssp/Makefile sys/Makefile xdr/Makefile]) +AC_CONFIG_FILES([Makefile argz/Makefile ctype/Makefile errno/Makefile locale/Makefile misc/Makefile reent/Makefile search/Makefile stdio/Makefile stdio64/Makefile stdlib/Makefile string/Makefile time/Makefile posix/Makefile signal/Makefile syscalls/Makefile unix/Makefile iconv/Makefile iconv/ces/Makefile iconv/ccs/Makefile iconv/ccs/binary/Makefile iconv/lib/Makefile ssp/Makefile xdr/Makefile]) AC_OUTPUT -- 2.34.1