ENH: Compile git with SSL support

Older versions of git included in older linux distributions are not able
to download source from Github. A newer version is required with a newer
OpenSSL. This requires to also build curl with the same OpenSSL.

CMake is downloaded precompiled if available (64bits system) or compiled
from source otherwise.
This commit is contained in:
Francois Budin
2018-04-13 14:56:49 -04:00
parent 856ef6016e
commit 602fb22cce
17 changed files with 331 additions and 147 deletions

View File

@ -1,21 +1,38 @@
WORKDIR /usr/share
RUN git clone "https://github.com/nojhan/liquidprompt.git" && \
cd liquidprompt && \
git checkout v_1.11
COPY imagefiles/.bashrc /root/
WORKDIR /usr/src
COPY imagefiles/install-openssl.sh imagefiles/install-cmake.sh /dockcross/
ARG GIT_VERSION=2.16.2
ARG CMAKE_VERSION=3.11.0
COPY imagefiles/build-and-install-git.sh \
imagefiles/utils.sh \
imagefiles/build-and-install-openssl.sh \
imagefiles/build-and-install-openssh.sh \
imagefiles/build-and-install-cmake.sh \
imagefiles/install-cmake-binary.sh \
imagefiles/build-and-install-curl.sh \
/dockcross/
RUN \
if [ "$DEFAULT_DOCKCROSS_IMAGE" = "dockcross/manylinux-x86" ]; then \
/dockcross/install-openssl.sh -32 && \
/dockcross/install-cmake.sh -32 || exit 1; \
/dockcross/build-and-install-openssl.sh -32 && \
/dockcross/build-and-install-openssh.sh && \
/dockcross/build-and-install-curl.sh && \
/dockcross/build-and-install-git.sh && \
/dockcross/build-and-install-cmake.sh -32 || exit 1; \
else \
/dockcross/install-openssl.sh && \
/dockcross/install-cmake.sh || exit 1; \
/dockcross/build-and-install-openssl.sh && \
/dockcross/build-and-install-openssh.sh && \
/dockcross/build-and-install-curl.sh && \
/dockcross/build-and-install-git.sh && \
/dockcross/install-cmake-binary.sh || exit 1; \
fi; \
rm /dockcross/install-openssl.sh /dockcross/install-cmake.sh
rm /dockcross/build-and-install-git.sh \
/dockcross/utils.sh \
/dockcross/build-and-install-openssl.sh \
/dockcross/build-and-install-openssh.sh \
/dockcross/build-and-install-cmake.sh \
/dockcross/install-cmake-binary.sh \
/dockcross/build-and-install-curl.sh
COPY imagefiles/cmake.sh /usr/local/bin/cmake
COPY imagefiles/ccmake.sh /usr/local/bin/ccmake
@ -38,6 +55,12 @@ RUN if [ -e /opt/python/cp35-cp35m/bin/python ]; then \
RUN $([ -e /opt/python/cp35-cp35m/bin/python ] && echo "/opt/python/cp35-cp35m/bin/python" || echo "python") -m pip install --ignore-installed conan
WORKDIR /usr/share
RUN git clone "https://github.com/nojhan/liquidprompt.git" && \
cd liquidprompt && \
git checkout v_1.11
COPY imagefiles/.bashrc /root/
RUN echo "root:root" | chpasswd
WORKDIR /work
ENTRYPOINT ["/dockcross/entrypoint.sh"]