[Distutils] Does anyone understand what's going on with libpython on Linux?

Matthias Klose doko at ubuntu.com
Sun Feb 7 12:15:06 EST 2016


On 07.02.2016 13:38, Antoine Pitrou wrote:
> On Sun, 7 Feb 2016 00:25:57 -0800
> "Robert T. McGibbon" <rmcgibbo at gmail.com> wrote:
>>> What are Debian/Ubuntu doing in distutils so that extensions don't link
>> to libpython by default?
>>
>> I don't know exactly, but one way to reproduce this is simply to build the
>> interpreter without `--enable-shared`.
>
> See https://bugs.python.org/issue21536. It would be nice if you could
> lobby for this issue to be resolved... (though that would only be for
> 3.6, presumably)
>
>> I don't know that their reasons are, but I presume that the Debian
>> maintainers have a well-considered reason for this design.
>
> Actually, shared library builds can be noticeably slower. I did
> measurements some time ago, and the results are:
> - shared builds are 5-10% slower on x86
> - they can be up to 30% slower on some ARM CPUs!

yes, that's the reason why the python executable is built statically against the 
libpython library.

Matthias



More information about the Distutils-SIG mailing list