From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from vmicros1.altlinux.org (vmicros1.altlinux.org [194.107.17.57]) by sourceware.org (Postfix) with ESMTP id E42DE3892023 for ; Sun, 6 Dec 2020 13:54:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org E42DE3892023 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=altlinux.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=ldv@altlinux.org Received: from mua.local.altlinux.org (mua.local.altlinux.org [192.168.1.14]) by vmicros1.altlinux.org (Postfix) with ESMTP id 5F21E72C8B5; Sun, 6 Dec 2020 16:54:12 +0300 (MSK) Received: by mua.local.altlinux.org (Postfix, from userid 508) id 53E6A7CC8A3; Sun, 6 Dec 2020 16:54:12 +0300 (MSK) Date: Sun, 6 Dec 2020 16:54:12 +0300 From: "Dmitry V. Levin" To: elfutils-devel@sourceware.org Cc: Mark Wielaard , "Frank Ch. Eigler" Subject: [PATCH v2 2/3] debuginfod: create the fully versioned libdebuginfod file name during build Message-ID: <20201206135412.GB27807@altlinux.org> References: <20201130090000.GA30063@altlinux.org> <20201206122813.GA27041@altlinux.org> <20201206133243.GA30511@redhat.com> <20201206133423.GE27041@altlinux.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201206133423.GE27041@altlinux.org> X-Spam-Status: No, score=-12.5 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_DMARC_STATUS, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: elfutils-devel@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Elfutils-devel mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Dec 2020 13:54:14 -0000 When the fully versioned file name is available, the fall back to dlopen of "libdebuginfod.so" in __libdwfl_debuginfod_init is no longer needed. Signed-off-by: Dmitry V. Levin --- debuginfod/ChangeLog | 7 +++++++ debuginfod/Makefile.am | 10 ++++++---- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/debuginfod/ChangeLog b/debuginfod/ChangeLog index 07899289..27abdfda 100644 --- a/debuginfod/ChangeLog +++ b/debuginfod/ChangeLog @@ -1,3 +1,10 @@ +2020-12-06 Dmitry V. Levin + + * Makefile.am (LIBDEBUGINFOD_FULL_NAME): New variable. + (libdebuginfod.so): Use it to create the fully versioned file name. + (install, uninstall): Replace libdebuginfod-$(PACKAGE_VERSION).so with + $(LIBDEBUGINFOD_FULL_NAME). + 2020-11-30 Dmitry V. Levin * Makefile.am (libdebuginfod.so): Replace $@.$(VERSION) with diff --git a/debuginfod/Makefile.am b/debuginfod/Makefile.am index 34f34acf..7df66125 100644 --- a/debuginfod/Makefile.am +++ b/debuginfod/Makefile.am @@ -100,6 +100,7 @@ libdebuginfod_so_LDLIBS = else libdebuginfod_so_LDLIBS = $(libcurl_LIBS) $(fts_LIBS) endif +LIBDEBUGINFOD_FULL_NAME = libdebuginfod-$(PACKAGE_VERSION).so libdebuginfod.so: $(srcdir)/libdebuginfod.map $(libdebuginfod_so_LIBS) $(AM_V_CCLD)$(LINK) $(dso_LDFLAGS) -o $@ \ -Wl,--soname,$(LIBDEBUGINFOD_SONAME) \ @@ -107,18 +108,19 @@ libdebuginfod.so: $(srcdir)/libdebuginfod.map $(libdebuginfod_so_LIBS) -Wl,--whole-archive $(libdebuginfod_so_LIBS) -Wl,--no-whole-archive \ $(libdebuginfod_so_LDLIBS) @$(textrel_check) + $(AM_V_at)ln -fs $@ $(LIBDEBUGINFOD_FULL_NAME) $(AM_V_at)ln -fs $@ $(LIBDEBUGINFOD_SONAME) endif if LIBDEBUGINFOD install: install-am libdebuginfod.so $(mkinstalldirs) $(DESTDIR)$(libdir) - $(INSTALL_PROGRAM) libdebuginfod.so $(DESTDIR)$(libdir)/libdebuginfod-$(PACKAGE_VERSION).so - ln -fs libdebuginfod-$(PACKAGE_VERSION).so $(DESTDIR)$(libdir)/$(LIBDEBUGINFOD_SONAME) - ln -fs libdebuginfod-$(PACKAGE_VERSION).so $(DESTDIR)$(libdir)/libdebuginfod.so + $(INSTALL_PROGRAM) libdebuginfod.so $(DESTDIR)$(libdir)/$(LIBDEBUGINFOD_FULL_NAME) + ln -fs $(LIBDEBUGINFOD_FULL_NAME) $(DESTDIR)$(libdir)/$(LIBDEBUGINFOD_SONAME) + ln -fs $(LIBDEBUGINFOD_FULL_NAME) $(DESTDIR)$(libdir)/libdebuginfod.so uninstall: uninstall-am - rm -f $(DESTDIR)$(libdir)/libdebuginfod-$(PACKAGE_VERSION).so + rm -f $(DESTDIR)$(libdir)/$(LIBDEBUGINFOD_FULL_NAME) rm -f $(DESTDIR)$(libdir)/$(LIBDEBUGINFOD_SONAME) rm -f $(DESTDIR)$(libdir)/libdebuginfod.so rmdir --ignore-fail-on-non-empty $(DESTDIR)$(includedir)/elfutils -- ldv