From: Dmitry V. Levin Date: Wed, 9 Dec 2020 00:13:12 +0000 (+0300) Subject: debuginfod: create libdebuginfod.so.1 before libdebuginfod.so X-Git-Tag: elfutils-0.183~66 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7e2e30586dfb05482861865077af2609196aad87;p=thirdparty%2Felfutils.git debuginfod: create libdebuginfod.so.1 before libdebuginfod.so This would allow to switch from "libdebuginfod-" VERSION ".so" to DEBUGINFOD_SONAME in __libdwfl_debuginfod_init, and to remove the fall back to dlopen of "libdebuginfod.so" which would no longer be needed. Signed-off-by: Dmitry V. Levin --- diff --git a/debuginfod/ChangeLog b/debuginfod/ChangeLog index ad5b4d384..0a7e458f6 100644 --- a/debuginfod/ChangeLog +++ b/debuginfod/ChangeLog @@ -1,3 +1,8 @@ +2020-12-08 Dmitry V. Levin + + * Makefile.am [LIBDEBUGINFOD]: Create libdebuginfod.so.1 first, turn + libdebuginfod.so into symlink. + 2020-11-30 Dmitry V. Levin * Makefile.am (libdebuginfod.so): Replace $@.$(VERSION) with diff --git a/debuginfod/Makefile.am b/debuginfod/Makefile.am index 93423c857..3adb27559 100644 --- a/debuginfod/Makefile.am +++ b/debuginfod/Makefile.am @@ -99,20 +99,21 @@ libdebuginfod_so_LDLIBS = else libdebuginfod_so_LDLIBS = $(libcurl_LIBS) $(fts_LIBS) endif -libdebuginfod.so: $(srcdir)/libdebuginfod.map $(libdebuginfod_so_LIBS) +$(LIBDEBUGINFOD_SONAME): $(srcdir)/libdebuginfod.map $(libdebuginfod_so_LIBS) $(AM_V_CCLD)$(LINK) $(dso_LDFLAGS) -o $@ \ -Wl,--soname,$(LIBDEBUGINFOD_SONAME) \ -Wl,--version-script,$<,--no-undefined \ -Wl,--whole-archive $(libdebuginfod_so_LIBS) -Wl,--no-whole-archive \ $(libdebuginfod_so_LDLIBS) @$(textrel_check) - $(AM_V_at)ln -fs $@ $(LIBDEBUGINFOD_SONAME) -endif -if LIBDEBUGINFOD +libdebuginfod.so: $(LIBDEBUGINFOD_SONAME) + ln -fs $< $@ + install: install-am libdebuginfod.so $(mkinstalldirs) $(DESTDIR)$(libdir) - $(INSTALL_PROGRAM) libdebuginfod.so $(DESTDIR)$(libdir)/libdebuginfod-$(PACKAGE_VERSION).so + $(INSTALL_PROGRAM) $(LIBDEBUGINFOD_SONAME) \ + $(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