/usr/share isn't the place for architecture dependent files like shared objects please consider not installing it in the first place also because they are useless /usr/share/doc/glpk-5.0/examples/glpsol.o and the corresponding debug files /usr/lib/debug/usr/share/doc/glpk-5.0/examples/.libs/glpsol.debug /usr/lib/debug/usr/share/doc/glpk-5.0/examples/glpsol.o.debug
OK, we have compiled stuff because the makefile in the examples folder is systematically run. As per the line SUBDIRS = src examples in the top Makefile.am. Patching that line would stop any objects from being produced. The next question is do we really want to ship the Makefile{.am,.in,} that are in that "examples" folder? They are not exactly useful without the rest of the code.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a36cbeb1287c096d09464f527fd9ce6c4450155a commit a36cbeb1287c096d09464f527fd9ce6c4450155a Author: Michael Orlitzky <mjo@gentoo.org> AuthorDate: 2021-03-31 12:57:15 +0000 Commit: Michael Orlitzky <mjo@gentoo.org> CommitDate: 2021-03-31 13:03:50 +0000 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> .../glpk/{glpk-5.0.ebuild => glpk-5.0-r1.ebuild} | 16 ++++++++++++++++ 1 file changed, 16 insertions(+)
Thanks for the hint. I think I managed to get away without adding another patch.