1
1
FROM quay.io/pypa/manylinux2014_i686:latest
2
2
3
+ ARG CCACHE_VERSION=3.7.9
4
+ ARG CMAKE_VERSION=3.17.0
5
+ ARG FFMPEG_VERSION=4.4.1
6
+ ARG NASM_VERSION=2.15.04
7
+ ARG OPENSSL_VERSION=1_1_1m
8
+ ARG QT_VERSION=5.15.0
9
+ ARG YASM_VERSION=1.3.0
10
+
3
11
RUN yum install bzip2-devel curl-devel zlib-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel freetype-devel -y
4
12
5
- RUN curl -O -L https://download.qt.io/official_releases/qt/5.15/5.15.0 /single/qt-everywhere-src-5.15.0 .tar.xz && \
6
- tar -xf qt-everywhere-src-5.15.0 .tar.xz && \
13
+ RUN curl -O -L https://download.qt.io/official_releases/qt/5.15/${QT_VERSION} /single/qt-everywhere-src-${QT_VERSION} .tar.xz && \
14
+ tar -xf qt-everywhere-src-${QT_VERSION} .tar.xz && \
7
15
cd qt-everywhere* && \
8
16
export MAKEFLAGS=-j$(nproc) && \
9
- ./configure -prefix /opt/Qt5.15.0 -release -opensource -confirm-license -qtnamespace QtOpenCVPython -xcb -xcb-xlib -bundled-xcb-xinput -no-openssl -no-dbus -skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtconnectivity -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmultimedia -skip qtpurchasing -skip qtqa -skip qtremoteobjects -skip qtrepotools -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttranslations -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview -skip xmlpatterns -skip declarative -make libs && \
17
+ ./configure -prefix /opt/Qt${QT_VERSION} -release -opensource -confirm-license -qtnamespace QtOpenCVPython -xcb -xcb-xlib -bundled-xcb-xinput -no-openssl -no-dbus -skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtconnectivity -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmultimedia -skip qtpurchasing -skip qtqa -skip qtremoteobjects -skip qtrepotools -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttranslations -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview -skip xmlpatterns -skip declarative -make libs && \
10
18
make && \
11
19
make install && \
12
20
cd .. && \
13
- rm -rf qt-everywhere-src-5.15.0 && \
14
- rm qt-everywhere-src-5.15.0 .tar.xz
21
+ rm -rf qt-everywhere-src-${QT_VERSION} && \
22
+ rm qt-everywhere-src-${QT_VERSION} .tar.xz
15
23
16
- ENV QTDIR /opt/Qt5.15.0
24
+ ENV QTDIR /opt/Qt${QT_VERSION}
17
25
ENV PATH "$QTDIR/bin:$PATH"
18
26
19
27
RUN mkdir ~/ffmpeg_sources && \
20
28
cd ~/ffmpeg_sources && \
21
- curl -O -L https://github.com/openssl/openssl/archive/OpenSSL_1_1_1g .tar.gz && \
22
- tar -xf OpenSSL_1_1_1g .tar.gz && \
23
- cd openssl-OpenSSL_1_1_1g && \
29
+ curl -O -L https://github.com/openssl/openssl/archive/OpenSSL_${OPENSSL_VERSION} .tar.gz && \
30
+ tar -xf OpenSSL_${OPENSSL_VERSION} .tar.gz && \
31
+ cd openssl-OpenSSL_${OPENSSL_VERSION} && \
24
32
# in i686, ./config detects x64 in i686 container without linux32
25
33
# when run from "docker build"
26
34
linux32 ./config --prefix="$HOME/ffmpeg_build" no-pinshared shared zlib && \
@@ -30,16 +38,16 @@ RUN mkdir ~/ffmpeg_sources && \
30
38
rm -rf ~/openssl_build
31
39
32
40
RUN cd ~/ffmpeg_sources && \
33
- curl -O -L http://www.nasm.us/pub/nasm/releasebuilds/2.15.04 /nasm-2.15.04 .tar.bz2 && \
34
- tar -xf nasm-2.15.04. tar.bz2 && cd nasm-2.15.04 && ./autogen.sh && \
41
+ curl -O -L http://www.nasm.us/pub/nasm/releasebuilds/${NASM_VERSION} /nasm-${NASM_VERSION} .tar.bz2 && \
42
+ tar -xf nasm-${NASM_VERSION}. tar.bz2 && cd nasm-${NASM_VERSION} && ./autogen.sh && \
35
43
linux32 ./configure && \
36
44
make -j$(getconf _NPROCESSORS_ONLN) && \
37
45
make install
38
46
39
47
RUN cd ~/ffmpeg_sources && \
40
- curl -O -L http://www.tortall.net/projects/yasm/releases/yasm-1.3.0 .tar.gz && \
41
- tar -xf yasm-1.3.0 .tar.gz && \
42
- cd yasm-1.3.0 && \
48
+ curl -O -L http://www.tortall.net/projects/yasm/releases/yasm-${YASM_VERSION} .tar.gz && \
49
+ tar -xf yasm-${YASM_VERSION} .tar.gz && \
50
+ cd yasm-${YASM_VERSION} && \
43
51
linux32 ./configure && \
44
52
make -j$(getconf _NPROCESSORS_ONLN) && \
45
53
make install
@@ -52,9 +60,9 @@ RUN cd ~/ffmpeg_sources && \
52
60
make install
53
61
54
62
RUN cd ~/ffmpeg_sources && \
55
- curl -O -L https://ffmpeg.org/releases/ffmpeg-4.3.2 .tar.bz2 && \
56
- tar -xf ffmpeg-4.3.2 .tar.bz2 && \
57
- cd ffmpeg-4.3.2 && \
63
+ curl -O -L https://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION} .tar.bz2 && \
64
+ tar -xf ffmpeg-${FFMPEG_VERSION} .tar.bz2 && \
65
+ cd ffmpeg-${FFMPEG_VERSION} && \
58
66
PATH=~/bin:$PATH && \
59
67
PKG_CONFIG_PATH="$HOME/ffmpeg_build/lib/pkgconfig" linux32 ./configure --prefix="$HOME/ffmpeg_build" --extra-cflags="-I$HOME/ffmpeg_build/include" --extra-ldflags="-L$HOME/ffmpeg_build/lib" --enable-openssl --enable-libvpx --enable-shared --enable-pic --bindir="$HOME/bin" && \
60
68
make -j$(getconf _NPROCESSORS_ONLN) && \
@@ -63,22 +71,22 @@ RUN cd ~/ffmpeg_sources && \
63
71
ldconfig && \
64
72
rm -rf ~/ffmpeg_sources
65
73
66
- RUN curl -O -L https://github.com/ccache/ccache/releases/download/v3.7.9 /ccache-3.7.9 .tar.gz && \
67
- tar -xf ccache-3.7.9 .tar.gz && \
68
- cd ccache-3.7.9 && \
74
+ RUN curl -O -L https://github.com/ccache/ccache/releases/download/v${CCACHE_VERSION} /ccache-${CCACHE_VERSION} .tar.gz && \
75
+ tar -xf ccache-${CCACHE_VERSION} .tar.gz && \
76
+ cd ccache-${CCACHE_VERSION} && \
69
77
linux32 ./configure && \
70
78
make -j$(getconf _NPROCESSORS_ONLN) && \
71
79
make install
72
80
73
- RUN curl -O -L https://github.com/Kitware/CMake/releases/download/v3.17.0 /cmake-3.17.0 .tar.gz && \
74
- tar -xf cmake-3.17.0 .tar.gz && \
75
- cd cmake-3.17.0 && \
81
+ RUN curl -O -L https://github.com/Kitware/CMake/releases/download/v${CMAKE_VERSION} /cmake-${CMAKE_VERSION} .tar.gz && \
82
+ tar -xf cmake-${CMAKE_VERSION} .tar.gz && \
83
+ cd cmake-${CMAKE_VERSION} && \
76
84
export MAKEFLAGS=-j$(getconf _NPROCESSORS_ONLN) && \
77
85
./configure --system-curl && \
78
86
make && \
79
87
make install && \
80
88
cd .. && \
81
- rm -rf cmake-3.17.0 *
89
+ rm -rf cmake-${CMAKE_VERSION} *
82
90
83
91
ENV PKG_CONFIG_PATH /usr/local/lib/pkgconfig:/root/ffmpeg_build/lib/pkgconfig
84
92
ENV LDFLAGS -L/root/ffmpeg_build/lib
0 commit comments