commit:     4add1ce6ed03c5de84c75b8823273fc912ba58e8
Author:     Maciej Barć <xgqt <AT> gentoo <DOT> org>
AuthorDate: Tue May 17 12:53:59 2022 +0000
Commit:     Maciej Barć <xgqt <AT> gentoo <DOT> org>
CommitDate: Tue May 17 13:18:09 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4add1ce6

dev-scheme/guile-gi: add static-libs USE flag

Closes: https://bugs.gentoo.org/845162
Signed-off-by: Maciej Barć <xgqt <AT> gentoo.org>

 ...uile-gi-0.3.1.ebuild => guile-gi-0.3.1-r1.ebuild} | 20 +++++++++++---------
 ...uile-gi-0.3.2.ebuild => guile-gi-0.3.2-r1.ebuild} | 13 +++++++++----
 dev-scheme/guile-gi/guile-gi-9999.ebuild             | 13 +++++++++----
 3 files changed, 29 insertions(+), 17 deletions(-)

diff --git a/dev-scheme/guile-gi/guile-gi-0.3.1.ebuild 
b/dev-scheme/guile-gi/guile-gi-0.3.1-r1.ebuild
similarity index 70%
rename from dev-scheme/guile-gi/guile-gi-0.3.1.ebuild
rename to dev-scheme/guile-gi/guile-gi-0.3.1-r1.ebuild
index 0fd9d6ec4efe..cf870f83e265 100644
--- a/dev-scheme/guile-gi/guile-gi-0.3.1.ebuild
+++ b/dev-scheme/guile-gi/guile-gi-0.3.1-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -8,7 +8,7 @@ inherit autotools
 DESCRIPTION="Bindings for GObject Introspection and libgirepository for Guile"
 HOMEPAGE="https://spk121.github.io/guile-gi/";
 
-if [[ "${PV}" == *9999* ]]; then
+if [[ "${PV}" == *9999* ]] ; then
        inherit git-r3
        EGIT_REPO_URI="https://github.com/spk121/${PN}.git";
 else
@@ -16,20 +16,18 @@ else
        KEYWORDS="~amd64"
 fi
 
-# Tests fail
-RESTRICT="strip test"
 LICENSE="GPL-3"
 SLOT="0"
+IUSE="static-libs"
+RESTRICT="strip test"  # Tests fail
 
-BDEPEND="
-       sys-apps/texinfo
-"
 DEPEND="
        >=dev-scheme/guile-2.0.9:=
        dev-libs/gobject-introspection
        x11-libs/gtk+:3[introspection]
 "
 RDEPEND="${DEPEND}"
+BDEPEND="sys-apps/texinfo"
 
 # guile generates ELF files without use of C or machine code
 # It's a portage's false positive. bug #677600
@@ -45,11 +43,15 @@ src_prepare() {
 }
 
 src_configure() {
-       econf --enable-introspection="yes"
+       econf --enable-introspection=yes $(use_enable static-libs static)
 }
 
 src_install() {
        default
 
-       mv "${D}/usr/share/doc/${PN}" "${D}/usr/share/doc/${PF}" || die
+       mv "${D}"/usr/share/doc/${PN} "${D}"/usr/share/doc/${PF} || die
+
+       if ! use static-libs ; then
+               find "${ED}" -type f -name '*.la' -delete || die
+       fi
 }

diff --git a/dev-scheme/guile-gi/guile-gi-0.3.2.ebuild 
b/dev-scheme/guile-gi/guile-gi-0.3.2-r1.ebuild
similarity index 80%
rename from dev-scheme/guile-gi/guile-gi-0.3.2.ebuild
rename to dev-scheme/guile-gi/guile-gi-0.3.2-r1.ebuild
index e1dbe9e8b9ec..b5423a07a2d3 100644
--- a/dev-scheme/guile-gi/guile-gi-0.3.2.ebuild
+++ b/dev-scheme/guile-gi/guile-gi-0.3.2-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -8,7 +8,7 @@ inherit virtualx autotools
 DESCRIPTION="Bindings for GObject Introspection and libgirepository for Guile"
 HOMEPAGE="https://spk121.github.io/guile-gi/";
 
-if [[ "${PV}" == *9999* ]]; then
+if [[ "${PV}" == *9999* ]] ; then
        inherit git-r3
        EGIT_REPO_URI="https://github.com/spk121/${PN}.git";
 else
@@ -16,9 +16,10 @@ else
        KEYWORDS="~amd64"
 fi
 
-RESTRICT="strip"
 LICENSE="GPL-3"
 SLOT="0"
+IUSE="static-libs"
+RESTRICT="strip"
 
 DEPEND="
        >=dev-scheme/guile-2.0.9:=
@@ -42,7 +43,7 @@ src_prepare() {
 }
 
 src_configure() {
-       econf --enable-introspection=yes
+       econf --enable-introspection=yes $(use_enable static-libs static)
 }
 
 src_test() {
@@ -53,4 +54,8 @@ src_install() {
        default
 
        mv "${D}"/usr/share/doc/${PN} "${D}"/usr/share/doc/${PF} || die
+
+       if ! use static-libs ; then
+               find "${ED}" -type f -name '*.la' -delete || die
+       fi
 }

diff --git a/dev-scheme/guile-gi/guile-gi-9999.ebuild 
b/dev-scheme/guile-gi/guile-gi-9999.ebuild
index e1dbe9e8b9ec..b5423a07a2d3 100644
--- a/dev-scheme/guile-gi/guile-gi-9999.ebuild
+++ b/dev-scheme/guile-gi/guile-gi-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
@@ -8,7 +8,7 @@ inherit virtualx autotools
 DESCRIPTION="Bindings for GObject Introspection and libgirepository for Guile"
 HOMEPAGE="https://spk121.github.io/guile-gi/";
 
-if [[ "${PV}" == *9999* ]]; then
+if [[ "${PV}" == *9999* ]] ; then
        inherit git-r3
        EGIT_REPO_URI="https://github.com/spk121/${PN}.git";
 else
@@ -16,9 +16,10 @@ else
        KEYWORDS="~amd64"
 fi
 
-RESTRICT="strip"
 LICENSE="GPL-3"
 SLOT="0"
+IUSE="static-libs"
+RESTRICT="strip"
 
 DEPEND="
        >=dev-scheme/guile-2.0.9:=
@@ -42,7 +43,7 @@ src_prepare() {
 }
 
 src_configure() {
-       econf --enable-introspection=yes
+       econf --enable-introspection=yes $(use_enable static-libs static)
 }
 
 src_test() {
@@ -53,4 +54,8 @@ src_install() {
        default
 
        mv "${D}"/usr/share/doc/${PN} "${D}"/usr/share/doc/${PF} || die
+
+       if ! use static-libs ; then
+               find "${ED}" -type f -name '*.la' -delete || die
+       fi
 }

Reply via email to