Skip to content

Commit 9f6fa52

Browse files
committed
Add Python 3.7.0b4
1 parent 5aae218 commit 9f6fa52

File tree

3 files changed

+14
-4
lines changed

3 files changed

+14
-4
lines changed

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ directory for source code.
5858

5959
The images currently contain:
6060

61-
- CPython 2.7, 3.3, 3.4, 3.5 and 3.6, installed in
61+
- CPython 2.7, 3.3, 3.4, 3.5, 3.6 and 3.7, installed in
6262
``/opt/python/<python tag>-<abi tag>``. The directories are named
6363
after the PEP 425 tags for each environment --
6464
e.g. ``/opt/python/cp27-cp27mu`` contains a wide-unicode CPython 2.7

docker/build_scripts/build_env.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# source me
22

33
PYTHON_DOWNLOAD_URL=https://www.python.org/ftp/python
4-
CPYTHON_VERSIONS="2.7.14 3.4.8 3.5.5 3.6.5"
4+
CPYTHON_VERSIONS="2.7.14 3.4.8 3.5.5 3.6.5 3.7.0b4"
55

66
# openssl version to build, with expected sha256 hash of .tar.gz
77
# archive.

docker/build_scripts/build_utils.sh

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,15 @@ function lex_pyver {
1919
}
2020

2121

22+
function pyver_dist_dir {
23+
# Echoes the dist directory name of given pyver, removing alpha/beta prerelease
24+
# Thus:
25+
# 3.2.1 -> 3.2.1
26+
# 3.7.0b4 -> 3.7.0
27+
echo $1 | awk -F "." '{printf "%d.%d.%d", $1, $2, $3}'
28+
}
29+
30+
2231
function do_cpython_build {
2332
local py_ver=$1
2433
check_var $py_ver
@@ -64,8 +73,9 @@ function build_cpython {
6473
local py_ver=$1
6574
check_var $py_ver
6675
check_var $PYTHON_DOWNLOAD_URL
67-
curl -fsSLO $PYTHON_DOWNLOAD_URL/$py_ver/Python-$py_ver.tgz
68-
curl -fsSLO $PYTHON_DOWNLOAD_URL/$py_ver/Python-$py_ver.tgz.asc
76+
local py_dist_dir=$(pyver_dist_dir $py_ver)
77+
curl -fsSLO $PYTHON_DOWNLOAD_URL/$py_dist_dir/Python-$py_ver.tgz
78+
curl -fsSLO $PYTHON_DOWNLOAD_URL/$py_dist_dir/Python-$py_ver.tgz.asc
6979
gpg --verify Python-$py_ver.tgz.asc
7080
if [ $(lex_pyver $py_ver) -lt $(lex_pyver 3.3) ]; then
7181
do_cpython_build $py_ver ucs2

0 commit comments

Comments
 (0)