Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 680826

Summary: media-libs/giflib-5.1.8 ignores LDFLAGS, installs man pages in /usr/share/man/man1/man1 directory
Product: Gentoo Linux Reporter: Arfrever Frehtes Taifersar Arahesis <arfrever.fta>
Component: Current packagesAssignee: Gentoo Graphics Project <graphics+disabled>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 331933    

Description Arfrever Frehtes Taifersar Arahesis 2019-03-18 04:53:00 UTC
media-libs/giflib-5.1.8 ignores LDFLAGS.

 * QA Notice: Files built without respecting LDFLAGS have been detected
 *  Please include the following list of files in your report:
 * /usr/lib64/libgif.so.7.1.0

giflib-5.1.6-gentoo.patch (used by media-libs/giflib-5.1.7) contains:
 libgif.so: $(OBJECTS) $(HEADERS)
-       $(CC) $(CFLAGS) -shared $(OFLAGS) -o libgif.so $(OBJECTS)
+       $(CC) $(CFLAGS) -shared $(LDFLAGS) -Wl,-soname,libgif.so.$(LIBMAJOR) -o libgif.so $(OBJECTS)

giflib-5.1.8-gentoo.patch (used by media-libs/giflib-5.1.8) does not contain any change in that line.

Upstream made this change:
--- Makefile
+++ Makefile
@@ -68,6 +68,6 @@
 libgif.so: $(OBJECTS) $(HEADERS)
-       $(CC) $(CFLAGS) -shared $(OFLAGS) -o libgif.so $(OBJECTS)
+       $(CC) $(CFLAGS) -shared $(OFLAGS) -Wl,-soname -Wl,libgif.so.$(LIBMAJOR) -o libgif.so $(OBJECTS)

This has fixed soname of library, but has not fixed using LDFLAGS.


media-libs/giflib-5.1.8 installs man pages in /usr/share/man/man1/man1 directory.

Upstream made this change:
--- Makefile
+++ Makefile
@@ -98,4 +98,4 @@
 install-man:
-       $(INSTALL) -d "$(DESTDIR)$(MANDIR)"
-       $(INSTALL) -m 644 doc/*.1 "$(DESTDIR)$(MANDIR)"
+       $(INSTALL) -d "$(DESTDIR)$(MANDIR)/man1"
+       $(INSTALL) -m 644 doc/*.1 "$(DESTDIR)$(MANDIR)/man1"
 uninstall: uninstall-man uninstall-include uninstall-lib uninstall-bin

media-libs/giflib-5.1.8 ebuild still passes MANDIR="${EPREFIX}/usr/share/man/man1" to emake, so man pages are now installed in wrong directory.
Probably MANDIR="${EPREFIX}/usr/share/man" should be now used (to respect ${EPREFIX}).
Comment 1 Arfrever Frehtes Taifersar Arahesis 2019-03-18 05:12:09 UTC
LDFLAGS problem reported to upstream:
https://sourceforge.net/p/giflib/bugs/128/
Comment 2 Larry the Git Cow gentoo-dev 2019-03-18 07:32:50 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03700281db70e961bde015ce8727d578afc9705b

commit 03700281db70e961bde015ce8727d578afc9705b
Author:     Lars Wendler <polynomial-c@gentoo.org>
AuthorDate: 2019-03-18 07:31:20 +0000
Commit:     Lars Wendler <polynomial-c@gentoo.org>
CommitDate: 2019-03-18 07:32:01 +0000

    media-libs/giflib: Revbump to fix LDFLAGS and man page installation
    
    Closes: https://bugs.gentoo.org/680826
    Thanks-to: Arfrever Frehtes Taifersar Arahesis <Arfrever@Apache.Org>
    Package-Manager: Portage-2.3.62, Repoman-2.3.12
    Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>

 media-libs/giflib/files/giflib-5.1.8-gentoo.patch                 | 8 +++++++-
 media-libs/giflib/{giflib-5.1.8.ebuild => giflib-5.1.8-r1.ebuild} | 1 -
 2 files changed, 7 insertions(+), 2 deletions(-)