From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 42666 invoked by alias); 5 Dec 2016 20:01:15 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 41711 invoked by uid 89); 5 Dec 2016 20:01:14 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.3 required=5.0 tests=AWL,BAYES_20,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=ham version=3.3.2 spammy=senkevich, U*andrew.n.senkevich, Senkevich, andrewnsenkevichgmailcom X-HELO: mail-qt0-f195.google.com X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=zGQgy2GGw4cDIGmZPZy/75j7sdWCurdVlze9gJwZN+0=; b=MX6MBHDVVJ7aUKR4LdmGWhfudOJcFIsCHQMwRUbLQEE8dEaHFiE7mu5HuLQigvo2Ou ptKxtttmg8kRaMnqt8Bu+9IFnXG9MOmv+fB3YY8MFi7F2uUf9it3tXJ3iskdPZewzUEo Ql1fI2WdqdK/WmzXwdX9y09v0JHaAU4L2yLWGR4UCMtQacN0ImSL8WAqDS+LRXBuWgbB bO/wlthUrDhxJyYlOUj7Z/ZCrJqFQdLCYCynax/3MSYpQHAY3pF9TCTFCo+sY6RfwPSj YyrAake3Lr0qTTDbd1l3LnoFRQm2z9G8BV24fQwDEpWAm3eUCc+kBJWhQk7Vi1A7+dWo K3Bg== X-Gm-Message-State: AKaTC02YbVasaExb1pyEeiCrye23QcKroVZel5cyXUgybOThaPvKWVlnJ0/yVTPoyyKKJ8P+9hsBtkEFje/+ng== X-Received: by 10.200.39.230 with SMTP id x35mr51596391qtx.259.1480968071872; Mon, 05 Dec 2016 12:01:11 -0800 (PST) MIME-Version: 1.0 In-Reply-To: References: From: "H.J. Lu" Date: Mon, 05 Dec 2016 20:01:00 -0000 Message-ID: Subject: Re: [PATCH] Install libm.a as linker script [BZ #20539] To: Andrew Senkevich Cc: libc-alpha Content-Type: text/plain; charset=UTF-8 X-SW-Source: 2016-12/txt/msg00118.txt.bz2 On Mon, Dec 5, 2016 at 11:39 AM, Andrew Senkevich wrote: > 2016-10-25 1:02 GMT+03:00 H.J. Lu : > . . . >> >> Do you need to update rules for building static math tests with >> libmvec.a? > > Currently where are no static tests linked with libmvec. > Should we add such tests? It is probably OK without it for now. > Current patch is: > > diff --git a/Makerules b/Makerules > index e865782..a670f81 100644 > --- a/Makerules > +++ b/Makerules > @@ -1190,7 +1190,10 @@ $(addprefix $(inst_sbindir)/,$(install-sbin)): \ > $(do-install-program) > endif > ifdef install-lib > -install-lib.a := $(filter lib%.a,$(install-lib)) > +ifeq ($(build-mathvec),yes) > +install-lib.a := $(filter-out libm.a,$(filter lib%.a,$(install-lib))) > +install-lib.a := $(filter-out $(install-lib-ldscripts),$(install-lib.a)) > +endif Will just ++ b/Makerules @@ -1191,6 +1191,7 @@ $(addprefix $(inst_sbindir)/,$(install-sbin)): \ endif ifdef install-lib install-lib.a := $(filter lib%.a,$(install-lib)) +install-lib.a := $(filter-out $(install-lib-ldscripts),$(install-lib.a)) install-lib-non.a := $(filter-out lib%.a,$(install-lib)) ifdef install-lib-non.a $(addprefix $(inst_libdir)/$(libprefix),$(install-lib-non.a)): \ work? > install-lib-non.a := $(filter-out lib%.a,$(install-lib)) > ifdef install-lib-non.a > $(addprefix $(inst_libdir)/$(libprefix),$(install-lib-non.a)): \ > diff --git a/math/Makefile b/math/Makefile > index 848b093..77031b1 100644 > --- a/math/Makefile > +++ b/math/Makefile > @@ -128,10 +128,10 @@ generated += $(foreach s,.c .S,$(call > type-foreach, $(calls:s_%=m_%$(s)))) > routines = $(call type-foreach, $(calls)) > > ifeq ($(build-mathvec),yes) > -# We need to install libm.so as linker script > -# for more comfortable use of vector math library. > -install-lib-ldscripts := libm.so > -install_subdir: $(inst_libdir)/libm.so > +# We need to install libm.so and libm.a as linker scripts > +# for transparent use of vector math library. > +install-lib-ldscripts := libm.so libm.a > +install-others: $(inst_libdir)/libm.so $(inst_libdir)/libm.a > $(inst_libdir)/libm.so: $(common-objpfx)format.lds \ > $(libm) \ > $(libmvec) \ > @@ -142,6 +142,18 @@ $(inst_libdir)/libm.so: $(common-objpfx)format.lds \ > 'AS_NEEDED ( $(libdir)/libmvec_nonshared.a > $(slibdir)/libmvec.so$(libmvec.so-version) ) )' \ > ) > $@.new > mv -f $@.new $@ > + > +install-others = $(inst_libdir)/libm.a > +$(inst_libdir)/libm.a: $(common-objpfx)format.lds \ > + $(libm) \ > + $(libmvec) \ > + $(+force) > + (echo '/* GNU ld script'; echo '*/';\ > + cat $<; \ > + echo 'GROUP ( $(libdir)/libm-$(lib-version).a $(libdir)/libmvec.a )' \ > + ) > $@.new > + cp $(objpfx)libm.a $(inst_libdir)/libm-$(lib-version).a > + mv -f $@.new $@ > endif > > # Rules for the test suite. > > > -- > WBR, > Andrew -- H.J.