commit:     f84c70570cd60734001239fa1a9cc5a4fef2b9f2
Author:     Vivian Heisz (demize) <demize <AT> unstable <DOT> systems>
AuthorDate: Thu May 15 19:31:51 2025 +0000
Commit:     demize <demize <AT> unstable <DOT> systems>
CommitDate: Thu May 15 20:42:04 2025 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=f84c7057

media-libs/glee: add -r2

This fixes a pkgconfig issue on multilib LLVM systems. The
previous .pc file hardcoded `/lib`, which causes LLD to
strictly link against libraries in `/lib`--which are the
incorrect binary format for x64 systems.

This updates the configure script to generate a pkgconf
config automatically, using the configured `libdir`.

Signed-off-by: Vivian Heisz (demize) <demize <AT> unstable.systems>

 media-libs/glee/files/glee-5.4.0.pc                | 12 -------
 media-libs/glee/files/glee-autotools.patch         | 19 ++++++++++-
 .../{glee-5.4.0-r1.ebuild => glee-5.4.0-r2.ebuild} |  2 +-
 media-libs/glee/glee-5.4.0.ebuild                  | 39 ----------------------
 4 files changed, 19 insertions(+), 53 deletions(-)

diff --git a/media-libs/glee/files/glee-5.4.0.pc 
b/media-libs/glee/files/glee-5.4.0.pc
deleted file mode 100644
index b2a6464c8..000000000
--- a/media-libs/glee/files/glee-5.4.0.pc
+++ /dev/null
@@ -1,12 +0,0 @@
-prefix=/usr
-exec_prefix=${prefix}
-libdir=${exec_prefix}/lib
-includedir=${prefix}/include/GL/
-
-Name: GLee
-Description: GL Easy Extension library
-Version: 5.4.0
-Requires:
-Conflicts:
-Libs: -L${libdir} -lGLee
-Cflags: -I${includedir}

diff --git a/media-libs/glee/files/glee-autotools.patch 
b/media-libs/glee/files/glee-autotools.patch
index 617c49058..394d98070 100644
--- a/media-libs/glee/files/glee-autotools.patch
+++ b/media-libs/glee/files/glee-autotools.patch
@@ -1,8 +1,9 @@
 diff -ruN configure.ac configure.ac
 --- configure.ac       1970-01-01 03:00:00.000000000 +0300
 +++ configure.ac       2007-02-13 23:48:45.000000000 +0300
-@@ -0,0 +1,10 @@
+@@ -0,0 +1,11 @@
 +AC_INIT(configure.ac)
++AC_CONFIG_FILES([glee.pc])
 +
 +AM_CONFIG_HEADER(config.h)
 +AM_INIT_AUTOMAKE(libGLee, 5.4)
@@ -20,3 +21,19 @@ diff -ruN Makefile.am Makefile.am
 +libGLee_la_SOURCES = GLee.c
 +includeGLdir = $(includedir)/GL
 +includeGL_HEADERS = GLee.h
+diff -ruN glee.pc.in.orig glee.pc.in
+--- glee.pc.in.orig    2025-05-15 15:16:23.422989994 -0400
++++ glee.pc.in 2025-05-15 15:16:01.246086074 -0400
+@@ -0,0 +1,12 @@
++prefix=@prefix@
++exec_prefix=@prefix@
++libdir=@libdir@
++includedir=@includedir@/GL
++
++Name: GLee
++Description: GL Easy Extension library
++Version: @PACKAGE_VERSION@
++Requires:
++Conflicts:
++Libs: -L${libdir} -lGLee
++Cflags: -I${includedir}

diff --git a/media-libs/glee/glee-5.4.0-r1.ebuild 
b/media-libs/glee/glee-5.4.0-r2.ebuild
similarity index 95%
rename from media-libs/glee/glee-5.4.0-r1.ebuild
rename to media-libs/glee/glee-5.4.0-r2.ebuild
index 147b807d2..71c703f10 100644
--- a/media-libs/glee/glee-5.4.0-r1.ebuild
+++ b/media-libs/glee/glee-5.4.0-r2.ebuild
@@ -35,5 +35,5 @@ src_install() {
        find "${ED}" -type f -name '*.la' -delete || die
        dodoc readme.txt extensionList.txt || die
        insinto /usr/$(get_libdir)/pkgconfig
-       newins "${FILESDIR}/${P}.pc" glee.pc
+       doins glee.pc
 }

diff --git a/media-libs/glee/glee-5.4.0.ebuild 
b/media-libs/glee/glee-5.4.0.ebuild
deleted file mode 100644
index 2fe6944a4..000000000
--- a/media-libs/glee/glee-5.4.0.ebuild
+++ /dev/null
@@ -1,39 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit autotools
-
-DESCRIPTION="OpenGL Easy Extension library"
-HOMEPAGE="https://elf-stone.com/glee.php";
-SRC_URI="https://elf-stone.com/downloads/GLee/GLee-${PV}-src.tar.gz";
-
-S="${WORKDIR}"
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE="static-libs"
-
-RDEPEND="virtual/opengl"
-DEPEND="${RDEPEND}"
-
-src_prepare() {
-       default
-       eapply -p0 "${FILESDIR}/${PN}-autotools.patch"
-       eautoreconf || die
-}
-
-src_configure() {
-       econf \
-               $(use_enable static-libs static)
-}
-
-src_install() {
-       emake DESTDIR="${D}" install || die
-       find "${ED}" -type f -name '*.la' -delete || die
-       dodoc readme.txt extensionList.txt || die
-       insinto /usr/lib/pkgconfig
-       newins "${FILESDIR}/${P}.pc" glee.pc
-}

Reply via email to