35 lines
1.4 KiB
Bash
35 lines
1.4 KiB
Bash
#!/bin/bash -eux
|
|
|
|
# Dist chooses which ubuntu base image we build in
|
|
export EXTPYTHON_DIST=trusty
|
|
|
|
# Release is used to select which tarball to download
|
|
export PYTHON_RELEASE=3.9.5
|
|
|
|
# Major version no is used in paths and labels (extpython-python${}, /opt/extpython/${}/...)
|
|
export PYTHON_MAJOR=3.9
|
|
|
|
# Tarball download URL
|
|
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
|
|
|
|
# Dependencies needed to build cpython
|
|
export CPYTHON_DEPS="libssl-dev zlib1g-dev libncurses5-dev libncursesw5-dev \
|
|
libreadline-dev libsqlite3-dev libgdbm-dev libdb5.3-dev libbz2-dev libexpat1-dev liblzma-dev tk-dev libffi-dev uuid-dev"
|
|
|
|
# Optional script to run in the build container early in the build process
|
|
export INSIDE_SCRIPT='#!/bin/bash -eux
|
|
wget -q -O- http://artifact.scc.net.davepedu.com/repo/apt/extpython/dists/trusty/install | bash -x /dev/stdin
|
|
apt-get update -qq
|
|
apt-get install -y extpython-openssl-1-1
|
|
'
|
|
|
|
# Extra args for python's configure script
|
|
export EXTRA_PY_CONFIGURE_FLAGS=--with-openssl=/opt/extpython/ssl/1.1.1k
|
|
|
|
# Name of the rules makefile used to build the deb package
|
|
export RULESFILE=rules.trusty-3.9.5
|
|
|
|
# Other arbitrary environment variables
|
|
# trusty's native openssl is too old, so we ship a newer version. Embed the library path
|
|
export LDFLAGS=-Wl,-rpath=/opt/extpython/ssl/1.1.1k/lib
|