Compare commits

..

6 Commits
master ... 3.6

Author SHA1 Message Date
dave b64bd3c2e3 fix install path 2018-11-01 22:39:33 -07:00
dave d2e1271e5b use local git mirror 2018-11-01 21:53:55 -07:00
dave ebf131aad9 test commit 2018-11-01 21:14:08 -07:00
dave 361db966ec Fixes 2018-10-31 11:37:53 -07:00
dave f7dba914a3 Set version 2018-10-18 22:12:06 -07:00
dave b5df2532bb Initial commit - python v3.7.0 2018-10-18 22:12:06 -07:00
63 changed files with 54 additions and 739 deletions

View File

@ -1,6 +1 @@
cpython
.git
temp
/src/out
/builds/
/ssl/

3
.gitignore vendored
View File

@ -1,3 +0,0 @@
.DS_Store
/src/out/
/builds/

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "cpython"]
path = cpython
url = http://192.168.1.122:4808/dave/cpython.git

12
Dockerfile Normal file
View File

@ -0,0 +1,12 @@
FROM ubuntu:bionic
RUN sed -i -E 's/(archive|security).ubuntu.com/192.168.1.142/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list
RUN apt-get update && \
apt-get install -y dpkg-dev debhelper && \
useradd builder && \
install -d /target -o builder -g builder
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y 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

View File

@ -1,14 +0,0 @@
FROM ubuntu:bionic
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

View File

@ -1,14 +0,0 @@
FROM ubuntu:disco
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

View File

@ -1,14 +0,0 @@
FROM ubuntu:focal
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

View File

@ -1,14 +0,0 @@
FROM ubuntu:jammy
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

View File

@ -1,14 +0,0 @@
FROM ubuntu:trusty
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

View File

@ -1,14 +0,0 @@
FROM ubuntu:xenial
RUN sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y dpkg-dev debhelper build-essential sudo wget curl
RUN useradd builder && \
install -d /build -o builder -g builder
ADD scripts/bootstrap.sh /bootstrap.sh
ADD scripts/build.sh /build.sh
ENTRYPOINT ["/bootstrap.sh"]

18
Makefile Normal file
View File

@ -0,0 +1,18 @@
#!/usr/bin/make -f
PY3_SRC=./cpython/
PY3_CONFFLAGS=--prefix=$(DESTDIR)/opt/extpython/3.6.7 --with-ensurepip=install
all:
cd $(PY3_SRC) && \
./configure $(PY3_CONFFLAGS) && \
make -j8
install:
cd $(PY3_SRC) && \
make install
# $(DESTDIR)/opt/extpython/3.6.7/bin/python3 $(DESTDIR)/opt/extpython/3.6.7/bin/pip3 install -r requirements.txt
clean:
cd $(PY3_SRC) && \
make clean || true

View File

@ -1,76 +0,0 @@
extpython
=========
Isolated python .deb builder
Extpython is a collection of tools for building installable packages containing various versions of Python. The
installations are isolated from the operating system's python such that modules may be added, removed, or upgraded
without risk of breaking. The builds are executed in Docker.
*Example invocation:*
```
./images.sh # pulls / creates base images with dependencies
./build.sh trusty-3.9.5.sh # build using the recipe in the named script file
```
The vars file - `trusty-3.9.5.sh` above - contains information about what python version will be built. See
`src/bionic-3.9.5.sh` for an annotated example.
Version support matrix
----------------------
| | 2.7 | 3.6 | 3.7 | 3.8 | 3.9 | 3.10 | 3.11 |
|--------|--------|------------------|-------|----------------------|--------|---------|--------|
| 14.04 | | 3.6.7<br />3.6.8 | | | 3.9.5* | 3.10.0* | |
| 16.04 | | 3.6.7 | 3.7.3 | | 3.9.5 | 3.10.0* | |
| 18.04 | 2.7.16 | 3.6.7 | 3.7.3 | 3.8.0a4<br />3.8.0b1 | 3.9.5 | 3.10.0 | 3.11.5 |
| 19.04 | | | 3.7.3 | | | | |
| 20.04 | | | | | 3.9.5 | 3.10.0 | 3.11.5 |
| 22.04 | | | | | | | 3.11.5 |
\* with provided extpython-openssl packages - see below
Openssl
-------
Some versions of Python require a version of openssl that is newer than what ships on many of these host OSes. To
satisfy this requirement, extpython also builds an Openssl package that installs in a similar isolated manner.
See `./ssl/` for details.
TODO
----
* Parameter for pre-loaded pip modules
Uploading
---------
`curl -v 'http://artifact.scc.net.davepedu.com/addpkg?provider=tar&reponame=cpython&version=3.10.0' -F 'f=@cpython-3.10.0.tar.gz'`
`rpcli -s http://artifact.scc.net.davepedu.com upload -y apt -f builds/3.10.0/trusty/extpython-python3.10_3.10.0_amd64.deb -r extpython -p extpython-python3.10 -i 3.10.0 -a dist=trusty`
Testing
-------
Install extpython in a temporary container an run it.
`docker run -it --rm ubuntu:bionic bash`
```
sed -i -E 's/(archive|security).ubuntu.com/aptmirror/' /etc/apt/sources.list && \
sed -i -E 's/^deb-src/# deb-src/' /etc/apt/sources.list && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y wget gnupg && \
. /etc/lsb-release && \
wget -q -O- http://artifact.scc.net.davepedu.com/repo/apt/extpython/dists/${DISTRIB_CODENAME}/install | bash -x /dev/stdin && \
apt-get install -y extpython-python3.10
```

11
build-inner.sh Executable file
View File

@ -0,0 +1,11 @@
#!/bin/bash
#export PATH=$PATH:/usr/bin
time dpkg-buildpackage -us -uc -b
ls -la ../
mkdir -p ./out
mv ../*.buildinfo ../*.changes ../*.deb ./out/

View File

@ -1,16 +1,3 @@
#!/bin/bash -eux
#!/bin/sh
VARSFILE=$1
. src/$VARSFILE
echo "FROM extbuilder-$EXTPYTHON_DIST" > Dockerfile.temp
echo "RUN apt-get update && \\" >> Dockerfile.temp
echo " DEBIAN_FRONTEND=noninteractive apt-get install -y -o Dpkg::Options::=\"--force-confdef\" -o Dpkg::Options::=\"--force-confold\" $CPYTHON_DEPS" >> Dockerfile.temp
# build image with just the deps
docker build -t extbuilder-${EXTPYTHON_DIST}-deps -f Dockerfile.temp .
rm -f Dockerfile.temp
time docker run -it --rm -e "VARSFILE=$VARSFILE" -v $PWD/src:/src extbuilder-${EXTPYTHON_DIST}-deps
sudo docker run -it --rm --workdir=/target/src -v $PWD:/target/src extbuilder ./build-inner.sh

1
cpython Submodule

@ -0,0 +1 @@
Subproject commit 6ec5cf24b7f38ea72bb42d5cd60dca0d3ee332f9

5
debian/changelog vendored Normal file
View File

@ -0,0 +1,5 @@
extpython-python3.6 (3.6.7) unstable; urgency=low
* Python tag v3.6.7
-- Dave Pedu <dave@davepedu.com> Wed, 17 Oct 2018 22:08:15 -0800

View File

@ -1,4 +1,4 @@
Source: extpython-openssl-1-1
Source: extpython-python3.6
Section: unknown
Priority: optional
Maintainer: ubuntu <ubuntu@unknown>
@ -6,7 +6,7 @@ Build-Depends: debhelper (>= 8.0.0)
Standards-Version: 3.9.4
Homepage: <insert the upstream URL, if relevant>
Package: extpython-openssl-1-1
Package: extpython-python3.6
Architecture: amd64
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: <insert up to 60 chars description>

View File

@ -1,8 +0,0 @@
#!/bin/bash -ex
RELEASES="trusty xenial bionic focal jammy"
for release in $RELEASES ; do
docker pull ubuntu:${release}
docker build -t extbuilder-${release} -f Dockerfile.${release} .
done

View File

@ -1,20 +0,0 @@
#!/bin/bash -eux
# get metadata
ln -s /src/$VARSFILE /tmp/vars.sh
. /tmp/vars.sh
. /etc/lsb-release #for DISTRIB_CODENAME
if [ -v INSIDE_SCRIPT ] ; then
echo "$INSIDE_SCRIPT" > /tmp/inside.sh
cat /tmp/inside.sh
bash -x /tmp/inside.sh
fi
# run the build
sudo -Hu builder /build.sh
# export the debs
OUTDIR="/src/out/${PYTHON_RELEASE}/${DISTRIB_CODENAME}"
mkdir -p $OUTDIR
cp /build/out/* $OUTDIR

View File

@ -1,40 +0,0 @@
#!/bin/bash -eux
. /tmp/vars.sh
function template {
perl -p -e 's/\$\{([^}]+)\}/defined $ENV{$1} ? $ENV{$1} : $&/eg' < $1
}
# create build dir
cd /build
mkdir work
cd work
# get cpython source
mkdir cpython
wget -qO- cpython.tar.gz $PYTHON_TARBALL | tar zxf - -C cpython/ --strip-components=1
# generate debian metadata
mkdir debian
export BUILD_DATE=$(date -R)
template /src/debian/changelog | tee debian/changelog
template /src/debian/control | tee debian/control
cp /src/debian/compat debian/
cp /src/Makefile ./
sed -i -E "s/_OPT_DIR_/${PYTHON_MAJOR}/" Makefile
if [ -v RULESFILE ]; then
cp /src/debian/$RULESFILE debian/rules
else
cp /src/debian/rules debian/
fi
# build the deb
time dpkg-buildpackage -us -uc -b
cd ..
mkdir out
mv *.deb out/
cd out
sha256sum *

View File

@ -1,18 +0,0 @@
#!/usr/bin/make -f
PY3_SRC=./cpython/
PY3_CONFFLAGS=--prefix=$(DESTDIR)/opt/extpython/_OPT_DIR_ --with-ensurepip=install ${EXTRA_PY_CONFIGURE_FLAGS}
all:
cd $(PY3_SRC) && \
./configure $(PY3_CONFFLAGS) && \
make -j8
install:
cd $(PY3_SRC) && \
make install -j8
# $(DESTDIR)/opt/extpython/3.7.0/bin/python3 $(DESTDIR)/opt/extpython/3.7/bin/pip3 install -r requirements.txt
clean:
cd $(PY3_SRC) && \
make clean || true

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=2.7.16
export PYTHON_MAJOR=2.7
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=3.10.0
export PYTHON_MAJOR=3.10
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=3.11.5
export PYTHON_MAJOR=3.11
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,13 +0,0 @@
#!/bin/bash -eux
# Which dist to build on
export EXTPYTHON_DIST=bionic
# Release is used to select which tarball to download
export PYTHON_RELEASE=3.7.3
# Major version no is used in paths and labels (extpython-python${}, /opt/extpython/${}/...)
export PYTHON_MAJOR=3.7
# Tarball download URL
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
# Deps needed to build this package
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"

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=3.8.0a4
export PYTHON_MAJOR=3.8
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=3.8.0b1
export PYTHON_MAJOR=3.8
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=bionic
export PYTHON_RELEASE=3.9.5
export PYTHON_MAJOR=3.9
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,5 +0,0 @@
extpython-python${PYTHON_MAJOR} (${PYTHON_RELEASE}) unstable; urgency=low
* Initial release
-- Dave Pedu <dave@davepedu.com> ${BUILD_DATE}

View File

@ -1,13 +0,0 @@
Source: extpython-python${PYTHON_MAJOR}
Section: unknown
Priority: optional
Maintainer: ubuntu <ubuntu@unknown>
Build-Depends: debhelper (>= 8.0.0)
Standards-Version: 3.9.4
Homepage: <insert the upstream URL, if relevant>
Package: extpython-python${PYTHON_MAJOR}
Architecture: amd64
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: <insert up to 60 chars description>
<insert long description, indented with spaces>

View File

@ -1,13 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
export DH_VERBOSE=1
override_dh_usrlocal:
override_dh_strip:
override_dh_shlibdeps:
dh_shlibdeps -l /opt/extpython/ssl/1.1.1l/lib
%:
dh $@

View File

@ -1,13 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
export DH_VERBOSE=1
override_dh_usrlocal:
override_dh_strip:
override_dh_shlibdeps:
dh_shlibdeps -l /opt/extpython/ssl/1.1.1k/lib
%:
dh $@

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=disco
export PYTHON_RELEASE=3.7.3
export PYTHON_MAJOR=3.7
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=focal
export PYTHON_RELEASE=2.7.18
export PYTHON_MAJOR=2.7
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=focal
export PYTHON_RELEASE=3.10.0
export PYTHON_MAJOR=3.10
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=focal
export PYTHON_RELEASE=3.11.5
export PYTHON_MAJOR=3.11
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=focal
export PYTHON_RELEASE=3.9.5
export PYTHON_MAJOR=3.9
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=jammy
export PYTHON_RELEASE=3.11.5
export PYTHON_MAJOR=3.11
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,34 +0,0 @@
#!/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.10.0
# Major version no is used in paths and labels (extpython-python${}, /opt/extpython/${}/...)
export PYTHON_MAJOR=3.10
# 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.1l
# Name of the rules makefile used to build the deb package
export RULESFILE=rules.openssl-1.1.1l
# 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.1l/lib

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=trusty
export PYTHON_RELEASE=3.6.8
export PYTHON_MAJOR=3.6
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"

View File

@ -1,34 +0,0 @@
#!/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

View File

@ -1,25 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=xenial
export PYTHON_RELEASE=3.10.0
export PYTHON_MAJOR=3.10
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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/xenial/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.1l --enable-optimizations"
# Name of the rules makefile used to build the deb package
export RULESFILE=rules.openssl-1.1.1l
# Other arbitrary environment variables
# xenial'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.1l/lib

View File

@ -1,13 +0,0 @@
#!/bin/bash -eux
# Which dist to build on
export EXTPYTHON_DIST=xenial
# Release is used to select which tarball to download
export PYTHON_RELEASE=3.7.3
# Major version no is used in paths and labels (extpython-python${}, /opt/extpython/${}/...)
export PYTHON_MAJOR=3.7
# Tarball download URL
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
# Deps needed to build this package
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"

View File

@ -1,10 +0,0 @@
#!/bin/bash -eux
export EXTPYTHON_DIST=xenial
export PYTHON_RELEASE=3.9.5
export PYTHON_MAJOR=3.9
export PYTHON_TARBALL="http://artifact.scc.net.davepedu.com/repo/tar/cpython/cpython/cpython-${PYTHON_RELEASE}.tar.gz"
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"
export EXTRA_PY_CONFIGURE_FLAGS=--enable-optimizations

View File

@ -1,17 +0,0 @@
#!/usr/bin/make -f
all:
cd openssl && \
./config --prefix=/opt/extpython/ssl/1.1.1l --openssldir=/opt/extpython/ssl/1.1.1l shared zlib && \
make -j8
#&& \
#echo "testing...." && \
#make test
install:
cd openssl && \
make install
clean:
cd openssl && \
make clean || true

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
sudo -Hu builder /src/build-user.sh
# export the debs
OUTDIR="/src/out/trusty/1.1.1l"
mkdir -p $OUTDIR
cp /build/out/* $OUTDIR

View File

@ -1,30 +0,0 @@
#!/bin/bash -eux
function template {
perl -p -e 's/\$\{([^}]+)\}/defined $ENV{$1} ? $ENV{$1} : $&/eg' < $1
}
cd /build
mkdir work
cd work
mkdir openssl
wget -O- -q http://artifact.scc.net.davepedu.com/repo/tar/openssl/openssl/openssl-1.1.1l.tar.gz | tar zxf - -C openssl/ --strip-components=1
# generate debian metadata
mkdir debian
export BUILD_DATE=$(date -R)
template /src/debian/changelog | tee debian/changelog
template /src/debian/control | tee debian/control
cp /src/debian/compat debian/
cp /src/debian/rules debian/
cp /src/Makefile ./
# build the deb
time dpkg-buildpackage -us -uc -b
cd ..
mkdir -p out
mv *.deb out/
cd out
sha256sum *

View File

@ -1,3 +0,0 @@
#!/bin/bash -eux
time docker run -it --rm -v $PWD:/src --entrypoint /src/build-inner.sh extbuilder-trusty-deps

View File

@ -1,11 +0,0 @@
extpython-openssl-1-1 (1.1.1l) unstable; urgency=low
* Initial release
-- Dave Pedu <dave@davepedu.com> ${BUILD_DATE}
extpython-openssl-1-1 (1.1.1k) unstable; urgency=low
* Initial release
-- Dave Pedu <dave@davepedu.com> ${BUILD_DATE}

View File

@ -1 +0,0 @@
9

View File

@ -1,13 +0,0 @@
Source: extpython-openssl-1-1
Section: unknown
Priority: optional
Maintainer: ubuntu <ubuntu@unknown>
Build-Depends: debhelper (>= 8.0.0)
Standards-Version: 3.9.4
Homepage: <insert the upstream URL, if relevant>
Package: extpython-openssl-1-1
Architecture: amd64
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: <insert up to 60 chars description>
<insert long description, indented with spaces>

View File

@ -1,13 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
export DH_VERBOSE=1
override_dh_usrlocal:
override_dh_strip:
override_dh_shlibdeps:
dh_shlibdeps -l /opt/extpython/ssl/1.1.1l/lib
%:
dh $@

View File

@ -1 +0,0 @@
*

View File

@ -1,17 +0,0 @@
#!/usr/bin/make -f
all:
cd openssl && \
./config --prefix=/opt/extpython/ssl/1.1.1l --openssldir=/opt/extpython/ssl/1.1.1l shared zlib && \
make -j8
#&& \
#echo "testing...." && \
#make test
install:
cd openssl && \
make install
clean:
cd openssl && \
make clean || true

View File

@ -1,8 +0,0 @@
#!/bin/bash -eux
sudo -Hu builder /src/build-user.sh
# export the debs
OUTDIR="/src/out/xenial/1.1.1l"
mkdir -p $OUTDIR
cp /build/out/* $OUTDIR

View File

@ -1,30 +0,0 @@
#!/bin/bash -eux
function template {
perl -p -e 's/\$\{([^}]+)\}/defined $ENV{$1} ? $ENV{$1} : $&/eg' < $1
}
cd /build
mkdir work
cd work
mkdir openssl
wget -O- -q http://artifact.scc.net.davepedu.com/repo/tar/openssl/openssl/openssl-1.1.1l.tar.gz | tar zxf - -C openssl/ --strip-components=1
# generate debian metadata
mkdir debian
export BUILD_DATE=$(date -R)
template /src/debian/changelog | tee debian/changelog
template /src/debian/control | tee debian/control
cp /src/debian/compat debian/
cp /src/debian/rules debian/
cp /src/Makefile ./
# build the deb
time dpkg-buildpackage -us -uc -b
cd ..
mkdir -p out
mv *.deb out/
cd out
sha256sum *

View File

@ -1,3 +0,0 @@
#!/bin/bash -eux
time docker run -it --rm -v $PWD:/src --entrypoint /src/build-inner.sh extbuilder-xenial-deps

View File

@ -1,5 +0,0 @@
extpython-openssl-1-1 (1.1.1l) unstable; urgency=low
* Initial release
-- Dave Pedu <dave@davepedu.com> ${BUILD_DATE}

View File

@ -1 +0,0 @@
9

View File

@ -1,13 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
export DH_VERBOSE=1
override_dh_usrlocal:
override_dh_strip:
override_dh_shlibdeps:
dh_shlibdeps -l /opt/extpython/ssl/1.1.1l/lib
%:
dh $@

View File

@ -1 +0,0 @@
*