@@ -19,9 +19,8 @@ DEVTOOLS_HASH=a8ebeb4bed624700f727179e6ef771dafe47651131a00a78b342251415646acc
19
19
# https://github.com/NixOS/patchelf/commit/2a9cefd7d637d160d12dc7946393778fa8abbc58
20
20
PATCHELF_VERSION=2a9cefd7d637d160d12dc7946393778fa8abbc58
21
21
PATCHELF_HASH=12da4727f09be42ae0b54878e1b8e86d85cb7a5b595731cdc1a0a170c4873c6d
22
- CURL_ROOT=curl-7.57.0
23
- # https://github.com/Homebrew/homebrew-core/blob/e3a8622111ecefe444194cade5cca3c69165e26c/Formula/curl.rb#L6
24
- CURL_HASH=c92fe31a348eae079121b73884065e600c533493eb50f1f6cee9c48a3f454826
22
+ CURL_ROOT=curl_7.52.1
23
+ CURL_HASH=a8984e8b20880b621f61a62d95ff3c0763a3152093a9f9ce4287cfd614add6ae
25
24
AUTOCONF_ROOT=autoconf-2.69
26
25
AUTOCONF_HASH=954bd69b391edc12d6a4a51a2dd1476543da5c6bbf05a95b59dc0dd6fd4c2969
27
26
AUTOMAKE_ROOT=automake-1.15
@@ -31,6 +30,8 @@ LIBTOOL_HASH=e3bd4d5d3d025a36c21dd6af7ea818a2afcd4dfc1ea5a17b39d7854bcd0c06e3
31
30
SQLITE_AUTOCONF_VERSION=sqlite-autoconf-3210000
32
31
# Homebrew saw the same hash: https://github.com/Homebrew/homebrew-core/blob/e3a8622111ecefe444194cade5cca3c69165e26c/Formula/sqlite.rb#L6
33
32
SQLITE_AUTOCONF_HASH=d7dd516775005ad87a57f428b6f86afd206cb341722927f104d3f0cf65fbbbe3
33
+ GIT_ROOT=2.16.2
34
+ GIT_HASH=cbdc2398204c7b7bed64f28265870aabe40dd3cd5c0455f7d315570ad7f7f5c8
34
35
35
36
# Dependencies for compiling Python that we want to remove from
36
37
# the final image after compiling Python
@@ -64,26 +65,38 @@ source $MY_DIR/build_utils.sh
64
65
yum -y update
65
66
66
67
# EPEL support
67
- yum -y install wget curl
68
+ yum -y install wget
68
69
# https://dl.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
69
70
cp $MY_DIR /epel-release-5-4.noarch.rpm .
70
71
check_sha256sum epel-release-5-4.noarch.rpm $EPEL_RPM_HASH
71
72
72
73
# Dev toolset (for LLVM and other projects requiring C++11 support)
73
- curl -fsSLO http://people.centos.org/tru/devtools-2/devtools-2.repo
74
+ wget -q http://people.centos.org/tru/devtools-2/devtools-2.repo
74
75
check_sha256sum devtools-2.repo $DEVTOOLS_HASH
75
76
mv devtools-2.repo /etc/yum.repos.d/devtools-2.repo
76
77
rpm -Uvh --replacepkgs epel-release-5* .rpm
77
78
rm -f epel-release-5* .rpm
78
79
79
80
# Development tools and libraries
80
- yum -y install bzip2 make git patch unzip bison yasm diffutils \
81
+ yum -y install bzip2 make patch unzip bison yasm diffutils \
81
82
automake which file cmake28 \
82
83
kernel-devel-` uname -r` \
84
+ expat-devel gettext \
83
85
devtoolset-2-binutils devtoolset-2-gcc \
84
86
devtoolset-2-gcc-c++ devtoolset-2-gcc-gfortran \
85
87
${PYTHON_COMPILE_DEPS}
86
88
89
+ # Build an OpenSSL for both curl and the Pythons. We'll delete this at the end.
90
+ build_openssl $OPENSSL_ROOT $OPENSSL_HASH
91
+ # Install curl so we can have TLS 1.2 in this ancient container.
92
+ build_curl $CURL_ROOT $CURL_HASH
93
+ hash -r
94
+ curl --version
95
+ curl-config --features
96
+
97
+ # Install a git we link against OpenSSL so that we can use TLS 1.2
98
+ build_git $GIT_ROOT $GIT_HASH
99
+
87
100
# Install newest autoconf
88
101
build_autoconf $AUTOCONF_ROOT $AUTOCONF_HASH
89
102
autoconf --version
@@ -109,8 +122,7 @@ rm -rf $SQLITE_AUTOCONF_VERSION*
109
122
# Compile the latest Python releases.
110
123
# (In order to have a proper SSL module, Python is compiled
111
124
# against a recent openssl [see env vars above], which is linked
112
- # statically. We delete openssl afterwards.)
113
- build_openssl $OPENSSL_ROOT $OPENSSL_HASH
125
+ # statically.
114
126
mkdir -p /opt/python
115
127
build_cpythons $CPYTHON_VERSIONS
116
128
@@ -129,14 +141,7 @@ ln -s $($PY36_BIN/python -c 'import certifi; print(certifi.where())') \
129
141
# Dockerfiles:
130
142
export SSL_CERT_FILE=/opt/_internal/certs.pem
131
143
132
- # Install newest curl
133
- build_curl $CURL_ROOT $CURL_HASH
134
- rm -rf /usr/local/include/curl /usr/local/lib/libcurl* /usr/local/lib/pkgconfig/libcurl.pc
135
- hash -r
136
- curl --version
137
- curl-config --features
138
-
139
- # Now we can delete our built SSL
144
+ # Now we can delete our built OpenSSL headers/static libs since we've linked everything we need
140
145
rm -rf /usr/local/ssl
141
146
142
147
# Install patchelf (latest with unreleased bug fixes)
@@ -152,6 +157,7 @@ ln -s $PY36_BIN/auditwheel /usr/local/bin/auditwheel
152
157
# final image
153
158
yum -y erase wireless-tools gtk2 libX11 hicolor-icon-theme \
154
159
avahi freetype bitstream-vera-fonts \
160
+ expat-devel gettext \
155
161
${PYTHON_COMPILE_DEPS} > /dev/null 2>&1
156
162
yum -y install ${MANYLINUX1_DEPS}
157
163
yum -y clean all > /dev/null 2>&1
0 commit comments