summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2021-03-31 08:57:15 -0400
committerMichael Orlitzky <mjo@gentoo.org>2021-03-31 09:03:50 -0400
commita36cbeb1287c096d09464f527fd9ce6c4450155a (patch)
tree584e9dc79d28512276ff31675e49d67dd6136c63 /sci-mathematics
parentnet-libs/courier-unicode: Version bump (diff)
downloadgentoo-a36cbeb1287c096d09464f527fd9ce6c4450155a.tar.gz
gentoo-a36cbeb1287c096d09464f527fd9ce6c4450155a.tar.bz2
gentoo-a36cbeb1287c096d09464f527fd9ce6c4450155a.zip
sci-mathematics/glpk: don't install build artifacts with USE=examples.
The build system for glpk automatically descends into the "examples" directory to build an example program. Afterwards, when we install the entire "examples" directory to honor USE=examples, we wind up installing the build artifacts for that program as well. This commit adds an extra "emake clean" to remove the build artifacts, and an "rm" to get rid of the (useless, to the end user) example Makefiles themselves. Closes: https://bugs.gentoo.org/779358 Reported-by: Alessandro Barbieri <lssndrbarbieri@gmail.com> Package-Manager: Portage-3.0.13, Repoman-3.0.2 Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
Diffstat (limited to 'sci-mathematics')
-rw-r--r--sci-mathematics/glpk/glpk-5.0-r1.ebuild (renamed from sci-mathematics/glpk/glpk-5.0.ebuild)16
1 files changed, 16 insertions, 0 deletions
diff --git a/sci-mathematics/glpk/glpk-5.0.ebuild b/sci-mathematics/glpk/glpk-5.0-r1.ebuild
index c91cdf6a34ae..8bf55ceb4aa2 100644
--- a/sci-mathematics/glpk/glpk-5.0.ebuild
+++ b/sci-mathematics/glpk/glpk-5.0-r1.ebuild
@@ -44,6 +44,7 @@ src_prepare() {
append-cppflags $($(tc-getPKG_CONFIG) --cflags libiodbc)
default
+
eautoreconf
}
@@ -64,11 +65,26 @@ src_configure() {
src_install() {
default
+
if use examples; then
+ # The top-level Makefile descends into the "examples" directory
+ # unconditionally, building a program and excreting build
+ # artifacts that we don't want to install. Note: this still
+ # leaves the example program /usr/bin/glpsol installed. An
+ # additional "emake ... uninstall" could probably take care
+ # of that if desired.
+ emake -C examples clean
+
+ # Installing the Makefiles for the examples does the user no
+ # good without the top-level Makefile.
+ rm examples/Makefile{.in,.am,} \
+ || die "failed to remove example Makefiles"
+
insinto "/usr/share/doc/${PF}"
doins -r examples
docompress -x "/usr/share/doc/${PF}/examples"
fi
+
use doc && dodoc doc/*.pdf doc/notes/*.pdf doc/*.txt
# no static archives