From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1521) id 62C473858D20; Fri, 18 Feb 2022 01:54:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 62C473858D20 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Michael Frysinger To: newlib-cvs@sourceware.org Subject: [newlib-cygwin] newlib: separate out libg from libc X-Act-Checkin: newlib-cygwin X-Git-Author: Mike Frysinger X-Git-Refname: refs/heads/master X-Git-Oldrev: c75bb30fc10bb68a087995ce7f4bf16fd8b0a4b0 X-Git-Newrev: f2b053f49ed2bd7b4da8cf4ed3a608dc2f425c2b Message-Id: <20220218015439.62C473858D20@sourceware.org> Date: Fri, 18 Feb 2022 01:54:39 +0000 (GMT) X-BeenThere: newlib-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Newlib GIT logs List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Feb 2022 01:54:39 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3Df2b053f49ed= 2bd7b4da8cf4ed3a608dc2f425c2b commit f2b053f49ed2bd7b4da8cf4ed3a608dc2f425c2b Author: Mike Frysinger Date: Sun Feb 13 03:03:12 2022 -0500 newlib: separate out libg from libc =20 Make this a separate target from libc so that we can migrate libc over to automake more easily. Having it integrated into the libc target is difficult to handle when using automake rules which expect a one-to-one mapping between names & inputs. Diff: --- newlib/Makefile.am | 12 +++++++++--- newlib/Makefile.in | 20 +++++++++++--------- 2 files changed, 20 insertions(+), 12 deletions(-) diff --git a/newlib/Makefile.am b/newlib/Makefile.am index 6d3b60b33..3e4b824d7 100644 --- a/newlib/Makefile.am +++ b/newlib/Makefile.am @@ -4,6 +4,7 @@ AUTOMAKE_OPTIONS =3D dejagnu ACLOCAL_AMFLAGS =3D -I . -I .. -I ../config =20 # Variables that will accumulate in subdirs. +CLEANFILES =3D PHONY =3D SUFFIXES =3D info_TEXINFOS =3D @@ -70,6 +71,7 @@ noinst_DATA +=3D stmp-targ-include =20 toollib_LIBRARIES =3D libm.a \ libc.a +noinst_DATA +=3D libg.a if HAVE_MULTISUBDIR BUILD_MULTISUBDIR =3D $(builddir)$(MULTISUBDIR) if HAVE_CRT0 @@ -80,6 +82,8 @@ endif =20 toollib_DATA =3D $(CRT0) $(CRT1) =20 +CLEANFILES +=3D libg.a + # The functions ldexp, frexp and modf are traditionally supplied in # both libc.a and libm.a. We build them in libm.a and copy them over, # along with some required supporting routines. @@ -99,18 +103,20 @@ MATHOBJS_IN_LIBC =3D \ $(lpfx)s_copysign.o $(lpfx)sf_copysign.o =20 libc.a: libc/libc.a libm.a - rm -rf libc.a libg.a tmp + rm -rf libc.a tmp mkdir tmp cd tmp; \ $(AR) x ../libm.a $(MATHOBJS_IN_LIBC) ; \ $(AR) x ../libc/libc.a ; \ $(AR) $(AR_FLAGS) ../$@ *.o $(RANLIB) libc.a - ln libc.a libg.a >/dev/null 2>/dev/null || cp libc.a libg.a rm -rf tmp =20 libc/libc.a: ; @true =20 +libg.a: libc.a + $(AM_V_GEN)ln libc.a libg.a >/dev/null 2>/dev/null || cp libc.a libg.a + libm.a: libm/libm.a rm -f $@ ln $< $@ >/dev/null 2>/dev/null || cp $< $@ @@ -247,7 +253,7 @@ stmp-targ-include: config.status $(MAKE) targ-include/newlib.h touch $@ =20 -CLEANFILES =3D stmp-targ-include +CLEANFILES +=3D stmp-targ-include =20 ## We hook install-multi because this Makefile doesn't have any exec targe= ts, ## only data targets. If that ever changes, this should be removed and the diff --git a/newlib/Makefile.in b/newlib/Makefile.in index c952082bf..f26bb68b5 100644 --- a/newlib/Makefile.in +++ b/newlib/Makefile.in @@ -442,10 +442,16 @@ AUTOMAKE_OPTIONS =3D dejagnu ACLOCAL_AMFLAGS =3D -I . -I .. -I ../config =20 # Variables that will accumulate in subdirs. +CLEANFILES =3D libg.a stmp-targ-include libc/targetdep.tex \ + libc/targetdep.tex.stamp $(LIBC_CHEWOUT_FILES) \ + $(LIBC_DOCBOOK_OUT_FILES) libc/*.xml libc/*.xml.stamp libc/*.3 \ + libm/targetdep.tex libm/targetdep.tex.stamp \ + $(LIBM_CHEWOUT_FILES) $(LIBM_DOCBOOK_OUT_FILES) libm/*.xml \ + libm/*.xml.stamp libm/*.3 PHONY =3D $(am__append_4) SUFFIXES =3D $(am__append_5) info_TEXINFOS =3D libc/libc.texi libm/libm.texi -noinst_DATA =3D stmp-targ-include $(am__append_1) $(am__append_2) \ +noinst_DATA =3D stmp-targ-include libg.a $(am__append_1) $(am__append_2) \ $(am__append_3) @NEWLIB_HW_FP_FALSE@MATHDIR =3D math =20 @@ -522,12 +528,6 @@ MATHOBJS_IN_LIBC =3D \ $(lpfx)s_finite.o $(lpfx)sf_finite.o \ $(lpfx)s_copysign.o $(lpfx)sf_copysign.o =20 -CLEANFILES =3D stmp-targ-include libc/targetdep.tex \ - libc/targetdep.tex.stamp $(LIBC_CHEWOUT_FILES) \ - $(LIBC_DOCBOOK_OUT_FILES) libc/*.xml libc/*.xml.stamp libc/*.3 \ - libm/targetdep.tex libm/targetdep.tex.stamp \ - $(LIBM_CHEWOUT_FILES) $(LIBM_DOCBOOK_OUT_FILES) libm/*.xml \ - libm/*.xml.stamp libm/*.3 CONFIG_STATUS_DEPENDENCIES =3D $(newlib_basedir)/configure.host MULTISRCTOP =3D=20 MULTIBUILDTOP =3D=20 @@ -1396,18 +1396,20 @@ uninstall-am: uninstall-dvi-am uninstall-html-am un= install-info-am \ =20 =20 libc.a: libc/libc.a libm.a - rm -rf libc.a libg.a tmp + rm -rf libc.a tmp mkdir tmp cd tmp; \ $(AR) x ../libm.a $(MATHOBJS_IN_LIBC) ; \ $(AR) x ../libc/libc.a ; \ $(AR) $(AR_FLAGS) ../$@ *.o $(RANLIB) libc.a - ln libc.a libg.a >/dev/null 2>/dev/null || cp libc.a libg.a rm -rf tmp =20 libc/libc.a: ; @true =20 +libg.a: libc.a + $(AM_V_GEN)ln libc.a libg.a >/dev/null 2>/dev/null || cp libc.a libg.a + libm.a: libm/libm.a rm -f $@ ln $< $@ >/dev/null 2>/dev/null || cp $< $@