Imported Upstream version 3.17.1
[platform/upstream/cmake.git] / Utilities / Release / linux / x86_64 / deps / Dockerfile
1 # Distributed under the OSI-approved BSD 3-Clause License.  See accompanying
2 # file Copyright.txt or https://cmake.org/licensing for details.
3
4 # Produce an image with custom-built dependencies for portable CMake binaries.
5 # Build using the directory containing this file as its own build context.
6
7 ARG FROM_IMAGE_NAME=kitware/cmake:build-linux-x86_64-base-2019-08-09
8 ARG FROM_IMAGE_DIGEST=@sha256:d2c13617f01181a3143a069e4496d6b78eafffa19d181c42be196d5dfd588151
9 ARG FROM_IMAGE=$FROM_IMAGE_NAME$FROM_IMAGE_DIGEST
10 FROM $FROM_IMAGE
11
12 # Sphinx
13 RUN : \
14  && source /opt/rh/rh-python36/enable \
15  && pip install sphinx==2.1.2 \
16  && :
17
18 # Qt
19 # Version 5.12.0 was the last to bundle xkbcommon.
20 COPY qt-install.patch /opt/qt/src/
21 RUN : \
22  && mkdir -p /opt/qt/src/qt-build \
23  && cd /opt/qt/src \
24  && curl -OL https://download.qt.io/archive/qt/5.12/5.12.0/single/qt-everywhere-src-5.12.0.tar.xz \
25  && sha512sum qt-everywhere-src-5.12.0.tar.xz | grep -q 0dd03d2645fb6dac5b58c8caf92b4a0a6900131f1ccfb02443a0df4702b5da0458f4c45e758d1b929ec709b0f4b36900df2fd60a058af9cc8c1a0748b6d57aae \
26  && tar xJf qt-everywhere-src-5.12.0.tar.xz \
27  && cd qt-build \
28  && source /opt/rh/devtoolset-6/enable \
29  && ../qt-everywhere-src-5.12.0/configure \
30       -prefix /opt/qt \
31       -static \
32       -release \
33       -c++std c++11 \
34       -opensource -confirm-license \
35       -gui \
36       -widgets \
37       -xcb \
38       -fontconfig \
39       -sql-sqlite \
40       -qt-doubleconversion \
41       -qt-libjpeg \
42       -qt-libpng \
43       -qt-pcre \
44       -qt-sqlite \
45       -qt-xcb \
46       -qt-xkbcommon \
47       -qt-zlib \
48       -system-freetype \
49       -no-accessibility \
50       -no-compile-examples \
51       -no-cups \
52       -no-dbus \
53       -no-directfb \
54       -no-egl \
55       -no-eglfs \
56       -no-evdev \
57       -no-gbm \
58       -no-gif \
59       -no-glib \
60       -no-gtk \
61       -no-harfbuzz \
62       -no-iconv \
63       -no-icu \
64       -no-journald \
65       -no-kms \
66       -no-libinput \
67       -no-libproxy \
68       -no-linuxfb \
69       -no-ltcg \
70       -no-mirclient \
71       -no-mtdev \
72       -no-opengl \
73       -no-openssl \
74       -no-pch \
75       -no-sql-mysql \
76       -no-sql-psql \
77       -no-sql-sqlite2 \
78       -no-syslog \
79       -no-system-proxies \
80       -no-tslib \
81       -no-use-gold-linker \
82       -skip declarative \
83       -skip multimedia \
84       -skip qtcanvas3d \
85       -skip qtconnectivity \
86       -skip qtdeclarative \
87       -skip qtlocation \
88       -skip qtmultimedia \
89       -skip qtsensors \
90       -skip qtserialport \
91       -skip qtsvg \
92       -skip qtwayland \
93       -skip qtwebchannel \
94       -skip qtwebengine \
95       -skip qtwebsockets \
96       -skip qtwinextras \
97       -skip qtxmlpatterns \
98       -nomake examples \
99       -nomake tests \
100  && make install -j $(nproc) \
101  && cd /opt/qt \
102  && patch -p1 -i src/qt-install.patch \
103  && cd /opt \
104  && rm -rf /opt/qt/src \
105  && :
106
107 # Curses
108 RUN : \
109  && mkdir -p /opt/ncurses/src/ncurses-build \
110  && cd /opt/ncurses/src \
111  && curl -O https://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.1.tar.gz \
112  && sha512sum ncurses-6.1.tar.gz | grep -q e308af43f8b7e01e98a55f4f6c4ee4d1c39ce09d95399fa555b3f0cdf5fd0db0f4c4d820b4af78a63f6cf6d8627587114a40af48cfc066134b600520808a77ee \
113  && tar xzf ncurses-6.1.tar.gz \
114  && cd ncurses-build \
115  && source /opt/rh/devtoolset-6/enable \
116  && ../ncurses-6.1/configure \
117       --prefix=/opt/ncurses \
118       --with-terminfo-dirs=/etc/terminfo:/lib/terminfo:/usr/share/terminfo \
119       --with-default-terminfo-dir=/usr/share/terminfo \
120       --without-shared \
121  && make -j $(nproc) \
122  && make install.libs install.includes \
123  && cd /opt \
124  && rm -rf /opt/ncurses/src \
125  && :
126
127 # OpenSSL
128 COPY openssl-source.patch /opt/openssl/src/
129 RUN : \
130  && mkdir -p /opt/openssl/src \
131  && cd /opt/openssl/src \
132  && curl -O https://www.openssl.org/source/openssl-1.1.1f.tar.gz \
133  && sha512sum openssl-1.1.1f.tar.gz | grep -q b00bd9b5ad5298fbceeec6bb19c1ab0c106ca5cfb31178497c58bf7e0e0cf30fcc19c20f84e23af31cc126bf2447d3e4f8461db97bafa7bd78f69561932f000c \
134  && tar xzf openssl-1.1.1f.tar.gz \
135  && cd openssl-1.1.1f \
136  && patch -p1 -i ../openssl-source.patch \
137  && source /opt/rh/devtoolset-6/enable \
138  && ./Configure --prefix=/opt/openssl linux-elf no-asm no-shared -D_POSIX_C_SOURCE=199506L -D_POSIX_SOURCE=1 -D_SVID_SOURCE=1 -D_BSD_SOURCE=1 \
139  && make install_dev -j $(nproc) \
140  && cd /opt \
141  && rm -rf /opt/openssl/src \
142  && :