This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Building Python 3 on old distributions
- From: Siddhesh Poyarekar <siddhesh at gotplt dot org>
- To: Joseph Myers <joseph at codesourcery dot com>, libc-alpha at sourceware dot org
- Date: Sat, 8 Sep 2018 03:17:20 +0530
- Subject: Re: Building Python 3 on old distributions
- References: <alpine.DEB.2.21.1809071820070.28211@digraph.polyomino.org.uk>
On Friday 07 September 2018 11:50 PM, Joseph Myers wrote:
One question asked at today's glibc BoF at the Cauldron was how hard it
was to build Python 3 on old GNU/Linux distributions, should we require it
for the glibc build.
I tried building Python 3.7.0 on Ubuntu 10.04, as the oldest distribution
I have readily to hand for testing such things. I needed to build libffi
3.2.1 first:
./configure --prefix=/scratch/jmyers/python-install
make
make install
and then could build Python 3.7.0:
./configure --prefix=/scratch/jmyers/python-install CPPFLAGS=-I/scratch/jmyers/python-install/lib/libffi-3.2.1/include LDFLAGS="-L/scratch/jmyers/python-install/lib -Wl,-rpath,/scratch/jmyers/python-install/lib"
make -j8
make install
The resulting Python does not support the ssl module (OpenSSL is too old
and I didn't try building newer OpenSSL locally). It *does* support
hashlib.
We should not need openssl support to build glibc, so this shouldn't be
a problem.
It might be a good idea to make a list of modules that are allowed when
writing scripts directly related to build or bootstrap, maybe starting
with the following:
- os
- sys
- argparse
- subprocess
- time
- io
- re
and then adding as required, keeping the list as small as possible.
Siddhesh