Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 509414 - app-emulation/emul-linux-x86-baselibs: provides useless partial python install
Summary: app-emulation/emul-linux-x86-baselibs: provides useless partial python install
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Multilib team
Depends on:
Blocks: 416723
  Show dependency tree
Reported: 2014-05-02 18:41 UTC by Michał Górny
Modified: 2015-06-02 08:33 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2014-05-02 18:41:30 UTC
Arfrever pinged me on IRC recently pointing out that Python 2.7 & 3.3 installed by emul-linux doesn't contain the .py files of the standard library. In other words, it pretty much can't run anything more complex than 'Hello world' (and I'm not even sure if it can work at all).

He suggested that we should just remove Python from that set. I don't have a strong opinion on this. Alternatively, we could take a safe route and keep it around till we kill emul-linux completely.

What are your thoughts?
Comment 1 Mike Gilbert gentoo-dev 2014-05-02 19:05:33 UTC
I agree that we should not include python in emul-linux-x86. The python infrastructure in Gentoo is not designed to deal with python being installed for multiple abis.
Comment 2 Arfrever Frehtes Taifersar Arahesis 2014-05-02 19:20:43 UTC
Results with unavailable:

$ cat test.c
#include <Python.h>
#include <stdio.h>

int main(int argc, char** argv)
#ifdef NO_SITE
        Py_NoSiteFlag = 1;
        return 0;
$ gcc -I/usr/include/python2.7 -o test-2.7 test.c -lpython2.7
$ gcc -I/usr/include/python3.3 -o test-3.3 test.c -lpython3.3
$ gcc -DNO_SITE -I/usr/include/python2.7 -o test-2.7-no-site test.c -lpython2.7
$ gcc -DNO_SITE -I/usr/include/python3.3 -o test-3.3-no-site test.c -lpython3.3
$ ./test-2.7 ; echo $?
ImportError: No module named site
$ ./test-2.7-no-site ; echo $?
$ ./test-3.3 ; echo $?
ImportError: No module named 'site'
$ ./test-3.3-no-site ; echo $?
Comment 3 Pacho Ramos gentoo-dev 2014-05-03 08:24:10 UTC
As this is not a regression, I would simply wait for next emul set as, that way, I will see in full script run what other package was wanting python included (if any) and drop if really save (or report the offending package wanting that files to be included)
Comment 4 eroen 2014-06-29 18:28:14 UTC
eroen@occam ~ $ diff -u0 <(tar tf /var/distfiles/emul-linux-x86-baselibs-20140406.tar.xz | grep '/var/db/pkg/' | cut -d '/' -f -6 | sort -u) <(tar tf /var/distfiles/emul-linux-x86-baselibs-20140508.tar.xz | grep '/var/db/pkg/' | cut -d '/' -f -6 | sort -u)
--- /dev/fd/63	2014-06-29 20:19:23.405205616 +0200
+++ /dev/fd/62	2014-06-29 20:19:23.406205626 +0200
@@ -15,2 +14,0 @@
@@ -23 +21 @@
@@ -40 +38 @@
@@ -49,2 +47,2 @@
@@ -64 +62 @@
@@ -68 +66 @@
@@ -104 +102 @@

dev-lang/python is not included in >=emul-linux-x86-baselibs-20140508, but it is listed in [1]. The changelog does not mention this change. Is this intentional?

FYI, I noticed this while getting a binary-only application (not in Gentoo) requiring 32-bit libpython to run, relying on a bundled libpython.

Comment 5 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2014-06-29 19:14:28 UTC
Yes, we removed it intentionally. However, we may need to reintroduce it because of samba-4 which is so much broken it links to python.
Comment 6 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2015-06-02 08:33:50 UTC
The emul-linux-x86 packages have been removed.