init
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
Some checks failed
Docker. / Ubuntu (push) Has been cancelled
User-agent updater. / User-agent (push) Failing after 15s
Lock Threads / lock (push) Failing after 10s
Waiting for answer. / waiting-for-answer (push) Failing after 22s
Needs user action. / needs-user-action (push) Failing after 8s
Can't reproduce. / cant-reproduce (push) Failing after 8s
Close stale issues and PRs / stale (push) Has been cancelled
This commit is contained in:
1
Telegram/build/docker/centos_env/.gitignore
vendored
Normal file
1
Telegram/build/docker/centos_env/.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
||||
__pycache__
|
||||
884
Telegram/build/docker/centos_env/Dockerfile
Normal file
884
Telegram/build/docker/centos_env/Dockerfile
Normal file
@@ -0,0 +1,884 @@
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM rockylinux:8 AS builder
|
||||
ENV LANG=C.UTF-8
|
||||
ENV TOOLSET=gcc-toolset-14
|
||||
ENV PATH=/opt/rh/$TOOLSET/root/usr/bin:$PATH
|
||||
ENV LIBRARY_PATH=/opt/rh/$TOOLSET/root/usr/lib64:/opt/rh/$TOOLSET/root/usr/lib:/usr/local/lib64:/usr/local/lib:/lib64:/lib:/usr/lib64:/usr/lib
|
||||
ENV LD_LIBRARY_PATH=$LIBRARY_PATH
|
||||
ENV PKG_CONFIG_PATH=/opt/rh/$TOOLSET/root/usr/lib64/pkgconfig:/opt/rh/$TOOLSET/root/usr/lib/pkgconfig:/usr/local/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/share/pkgconfig
|
||||
|
||||
RUN dnf -y install epel-release \
|
||||
&& dnf config-manager --set-enabled powertools \
|
||||
&& dnf -y install cmake autoconf automake libtool pkgconfig make patch git \
|
||||
python3.11-pip python3.11-devel gperf flex bison clang clang-tools-extra \
|
||||
lld nasm yasm file which wget perl-open perl-XML-Parser perl-IPC-Cmd \
|
||||
xorg-x11-util-macros $TOOLSET-gcc $TOOLSET-gcc-c++ $TOOLSET-binutils \
|
||||
$TOOLSET-gdb $TOOLSET-libasan-devel libffi-devel fontconfig-devel \
|
||||
freetype-devel libX11-devel wayland-devel alsa-lib-devel \
|
||||
pulseaudio-libs-devel mesa-libGL-devel mesa-libEGL-devel mesa-libgbm-devel \
|
||||
libdrm-devel vulkan-devel libva-devel libvdpau-devel libselinux-devel \
|
||||
libmount-devel systemd-devel glib2-devel gobject-introspection-devel \
|
||||
at-spi2-core-devel gtk3-devel boost1.78-devel \
|
||||
&& dnf clean all
|
||||
|
||||
RUN alternatives --set python3 /usr/bin/python3.11
|
||||
RUN python3 -m pip install meson ninja
|
||||
RUN cat <<EOF > /usr/local/bin/pkg-config && chmod +x /usr/local/bin/pkg-config
|
||||
#!/bin/sh
|
||||
for i in "\$@"; do
|
||||
[ "\$i" = "--version" ] && exec /usr/bin/pkg-config "\$i"
|
||||
done
|
||||
exec /usr/bin/pkg-config --static "\$@"
|
||||
EOF
|
||||
RUN sed -i '/CMAKE_${lang}_FLAGS_DEBUG_INIT/s/")/ -O0 {% if LTO %}-fno-lto -fno-use-linker-plugin{% endif %} -fuse-ld=lld")/' /usr/share/cmake/Modules/Compiler/GNU.cmake
|
||||
RUN sed -i 's/NO_DEFAULT_PATH//g; s/PKG_CONFIG_ALLOW_SYSTEM_LIBS/PKG_CONFIG_IS_DUMB/g' /usr/share/cmake/Modules/FindPkgConfig.cmake
|
||||
RUN sed -i 's/set(OpenGL_GL_PREFERENCE "")/set(OpenGL_GL_PREFERENCE "LEGACY")/' /usr/share/cmake/Modules/FindOpenGL.cmake
|
||||
RUN sed -i '/Requires.private: valgrind/d' /usr/lib64/pkgconfig/libdrm.pc
|
||||
RUN sed -i 's/-lharfbuzz//' /usr/lib64/pkgconfig/harfbuzz.pc
|
||||
RUN sed -i 's/-lpng16//' /usr/lib64/pkgconfig/libpng16.pc
|
||||
RUN echo set debuginfod enabled on > /opt/rh/$TOOLSET/root/etc/gdbinit.d/00-debuginfod.gdb
|
||||
RUN adduser user
|
||||
|
||||
WORKDIR /usr/src
|
||||
ENV AR=gcc-ar
|
||||
ENV RANLIB=gcc-ranlib
|
||||
ENV NM=gcc-nm
|
||||
ENV CFLAGS='{% if DEBUG %}-g{% endif %} -O3 {% if LTO %}-flto=auto -ffat-lto-objects{% endif %} -pipe -fPIC -fno-strict-aliasing -fexceptions -fasynchronous-unwind-tables -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer -fhardened -Wno-hardened'
|
||||
ENV CXXFLAGS=$CFLAGS
|
||||
ENV LDFLAGS='-static-libstdc++ -static-libgcc -static-libasan -pthread -Wl,--push-state,--no-as-needed,-ldl,--pop-state -Wl,--as-needed -Wl,-z,muldefs'
|
||||
|
||||
ENV CMAKE_GENERATOR=Ninja
|
||||
ENV CMAKE_BUILD_TYPE=None
|
||||
ENV CMAKE_BUILD_PARALLEL_LEVEL='{{ JOBS }}'
|
||||
|
||||
RUN git init Implib.so \
|
||||
&& cd Implib.so \
|
||||
&& git remote add origin https://github.com/yugr/Implib.so.git \
|
||||
&& git fetch --depth=1 origin ecf7bb51a92a0fb16834c5b698570ab25f9f1d21 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& mkdir build \
|
||||
&& cd build \
|
||||
&& implib() { \
|
||||
LIBFILE=$(basename $1); \
|
||||
LIBNAME=$(basename $1 .so); \
|
||||
../implib-gen.py -q $1; \
|
||||
gcc $CFLAGS -c -o $LIBFILE.tramp.o $LIBFILE.tramp.S; \
|
||||
gcc $CFLAGS -c -o $LIBFILE.init.o $LIBFILE.init.c; \
|
||||
ar rcs /usr/local/lib64/$LIBNAME.a $LIBFILE.tramp.o $LIBFILE.init.o; \
|
||||
} \
|
||||
&& implib /usr/lib64/libgtk-3.so \
|
||||
&& implib /usr/lib64/libgdk-3.so \
|
||||
&& implib /usr/lib64/libgdk_pixbuf-2.0.so \
|
||||
&& implib /usr/lib64/libpango-1.0.so \
|
||||
&& implib /usr/lib64/libvdpau.so \
|
||||
&& implib /usr/lib64/libva-x11.so \
|
||||
&& implib /usr/lib64/libva-drm.so \
|
||||
&& implib /usr/lib64/libva.so \
|
||||
&& implib /usr/lib64/libEGL.so \
|
||||
&& implib /usr/lib64/libGL.so \
|
||||
&& implib /usr/lib64/libdrm.so \
|
||||
&& implib /usr/lib64/libwayland-egl.so \
|
||||
&& implib /usr/lib64/libwayland-cursor.so \
|
||||
&& implib /usr/lib64/libwayland-client.so \
|
||||
&& implib /usr/lib64/libwayland-server.so \
|
||||
&& implib /usr/lib64/libX11-xcb.so \
|
||||
&& implib /usr/lib64/libxcb.so \
|
||||
&& cd ../.. \
|
||||
&& rm -rf Implib.so
|
||||
|
||||
FROM builder AS patches
|
||||
RUN git init patches \
|
||||
&& cd patches \
|
||||
&& git remote add origin https://github.com/desktop-app/patches.git \
|
||||
&& git fetch --depth=1 origin 859556cab51d17585ff76d3db62ff1c7502bc850 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& rm -rf .git
|
||||
|
||||
FROM builder AS zlib
|
||||
RUN git clone -b v1.3.1 --depth=1 https://github.com/madler/zlib.git \
|
||||
&& cd zlib \
|
||||
&& cmake -B build . -DZLIB_BUILD_EXAMPLES=OFF \
|
||||
&& cmake --build build \
|
||||
&& export DESTDIR=/usr/src/zlib-cache \
|
||||
&& cmake --install build \
|
||||
&& rm $DESTDIR/usr/local/lib/libz.so* \
|
||||
&& cd .. \
|
||||
&& rm -rf zlib
|
||||
|
||||
FROM builder AS xz
|
||||
RUN git clone -b v5.8.1 --depth=1 https://github.com/tukaani-project/xz.git \
|
||||
&& cd xz \
|
||||
&& cmake -B build . \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/xz-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf xz
|
||||
|
||||
FROM builder AS protobuf
|
||||
RUN git clone -b v30.2 --depth=1 --recursive --shallow-submodules https://github.com/protocolbuffers/protobuf.git \
|
||||
&& cd protobuf \
|
||||
&& cmake -B build . \
|
||||
-Dprotobuf_BUILD_TESTS=OFF \
|
||||
-Dprotobuf_BUILD_PROTOBUF_BINARIES=ON \
|
||||
-Dprotobuf_BUILD_LIBPROTOC=ON \
|
||||
-Dprotobuf_WITH_ZLIB=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/protobuf-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf protobuf
|
||||
|
||||
FROM builder AS lcms2
|
||||
RUN git clone -b lcms2.15 --depth=1 https://github.com/mm2/Little-CMS.git \
|
||||
&& cd Little-CMS \
|
||||
&& meson build \
|
||||
--buildtype=plain \
|
||||
--default-library=static \
|
||||
&& meson compile -C build \
|
||||
&& DESTDIR=/usr/src/lcms2-cache meson install -C build \
|
||||
&& cd .. \
|
||||
&& rm -rf Little-CMS
|
||||
|
||||
FROM builder AS brotli
|
||||
RUN git clone -b v1.1.0 --depth=1 https://github.com/google/brotli.git \
|
||||
&& cd brotli \
|
||||
&& cmake -B build . \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DBROTLI_DISABLE_TESTS=ON \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/brotli-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf brotli
|
||||
|
||||
FROM builder AS highway
|
||||
RUN git clone -b 1.0.7 --depth=1 https://github.com/google/highway.git \
|
||||
&& cd highway \
|
||||
&& cmake -B build . \
|
||||
-DBUILD_TESTING=OFF \
|
||||
-DHWY_ENABLE_CONTRIB=OFF \
|
||||
-DHWY_ENABLE_EXAMPLES=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/highway-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf highway
|
||||
|
||||
FROM builder AS opus
|
||||
RUN git clone -b v1.5.2 --depth=1 https://github.com/xiph/opus.git \
|
||||
&& cd opus \
|
||||
&& cmake -B build . \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/opus-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf opus
|
||||
|
||||
FROM builder AS dav1d
|
||||
RUN git clone -b 1.5.1 --depth=1 https://github.com/videolan/dav1d.git \
|
||||
&& cd dav1d \
|
||||
&& meson build \
|
||||
--buildtype=plain \
|
||||
--default-library=static \
|
||||
-Denable_tools=false \
|
||||
-Denable_tests=false \
|
||||
&& meson compile -C build \
|
||||
&& DESTDIR=/usr/src/dav1d-cache meson install -C build \
|
||||
&& cd .. \
|
||||
&& rm -rf dav1d
|
||||
|
||||
FROM builder AS openh264
|
||||
RUN git clone -b v2.6.0 --depth=1 https://github.com/cisco/openh264.git \
|
||||
&& cd openh264 \
|
||||
&& meson build \
|
||||
--buildtype=plain \
|
||||
--default-library=static \
|
||||
&& meson compile -C build \
|
||||
&& DESTDIR=/usr/src/openh264-cache meson install -C build \
|
||||
&& cd .. \
|
||||
&& rm -rf openh264
|
||||
|
||||
FROM builder AS de265
|
||||
RUN git clone -b v1.0.16 --depth=1 https://github.com/strukturag/libde265.git \
|
||||
&& cd libde265 \
|
||||
&& cmake -B build . \
|
||||
-DCMAKE_BUILD_TYPE=None \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DENABLE_DECODER=OFF \
|
||||
-DENABLE_SDL=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/de265-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf libde265
|
||||
|
||||
FROM builder AS vpx
|
||||
RUN git init libvpx \
|
||||
&& cd libvpx \
|
||||
&& git remote add origin https://github.com/webmproject/libvpx.git \
|
||||
&& git fetch --depth=1 origin 12f3a2ac603e8f10742105519e0cd03c3b8f71dd \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& CFLAGS="$CFLAGS -fno-lto" CXXFLAGS="$CXXFLAGS -fno-lto" ./configure \
|
||||
--disable-examples \
|
||||
--disable-unit-tests \
|
||||
--disable-tools \
|
||||
--disable-docs \
|
||||
--enable-vp8 \
|
||||
--enable-vp9 \
|
||||
--enable-webm-io \
|
||||
--size-limit=4096x4096 \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/vpx-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libvpx
|
||||
|
||||
FROM builder AS webp
|
||||
RUN git clone -b v1.5.0 --depth=1 https://github.com/webmproject/libwebp.git \
|
||||
&& cd libwebp \
|
||||
&& cmake -B build . \
|
||||
-DWEBP_BUILD_ANIM_UTILS=OFF \
|
||||
-DWEBP_BUILD_CWEBP=OFF \
|
||||
-DWEBP_BUILD_DWEBP=OFF \
|
||||
-DWEBP_BUILD_GIF2WEBP=OFF \
|
||||
-DWEBP_BUILD_IMG2WEBP=OFF \
|
||||
-DWEBP_BUILD_VWEBP=OFF \
|
||||
-DWEBP_BUILD_WEBPMUX=OFF \
|
||||
-DWEBP_BUILD_WEBPINFO=OFF \
|
||||
-DWEBP_BUILD_EXTRAS=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/webp-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf libwebp
|
||||
|
||||
FROM builder AS avif
|
||||
COPY --link --from=dav1d /usr/src/dav1d-cache /
|
||||
|
||||
RUN git clone -b v1.3.0 --depth=1 https://github.com/AOMediaCodec/libavif.git \
|
||||
&& cd libavif \
|
||||
&& cmake -B build . \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DAVIF_CODEC_DAV1D=SYSTEM \
|
||||
-DAVIF_LIBYUV=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/avif-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf libavif
|
||||
|
||||
FROM builder AS heif
|
||||
COPY --link --from=de265 /usr/src/de265-cache /
|
||||
|
||||
RUN git clone -b v1.19.8 --depth=1 https://github.com/strukturag/libheif.git \
|
||||
&& cd libheif \
|
||||
&& cmake -B build . \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DCMAKE_DISABLE_FIND_PACKAGE_Doxygen=ON \
|
||||
-DBUILD_TESTING=OFF \
|
||||
-DENABLE_PLUGIN_LOADING=OFF \
|
||||
-DWITH_X265=OFF \
|
||||
-DWITH_AOM_DECODER=OFF \
|
||||
-DWITH_AOM_ENCODER=OFF \
|
||||
-DWITH_OpenH264_DECODER=OFF \
|
||||
-DWITH_RAV1E=OFF \
|
||||
-DWITH_RAV1E_PLUGIN=OFF \
|
||||
-DWITH_SvtEnc=OFF \
|
||||
-DWITH_SvtEnc_PLUGIN=OFF \
|
||||
-DWITH_DAV1D=OFF \
|
||||
-DWITH_LIBSHARPYUV=OFF \
|
||||
-DWITH_EXAMPLES=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/heif-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf libheif
|
||||
|
||||
FROM builder AS jxl
|
||||
COPY --link --from=lcms2 /usr/src/lcms2-cache /
|
||||
COPY --link --from=brotli /usr/src/brotli-cache /
|
||||
COPY --link --from=highway /usr/src/highway-cache /
|
||||
|
||||
RUN git clone -b v0.11.1 --depth=1 https://github.com/libjxl/libjxl.git \
|
||||
&& cd libjxl \
|
||||
&& git submodule update --init --recursive --depth=1 third_party/libjpeg-turbo \
|
||||
&& curl -sSL https://github.com/libjxl/libjxl/commit/ee3955b1553bcc10304d45b85dfef9afa9349d72.patch | sed 's/offset + t/offset + i/' | git apply \
|
||||
&& cmake -B build . \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
-DBUILD_TESTING=OFF \
|
||||
-DJPEGXL_ENABLE_DEVTOOLS=OFF \
|
||||
-DJPEGXL_ENABLE_TOOLS=OFF \
|
||||
-DJPEGXL_INSTALL_JPEGLI_LIBJPEG=ON \
|
||||
-DJPEGXL_ENABLE_DOXYGEN=OFF \
|
||||
-DJPEGXL_ENABLE_MANPAGES=OFF \
|
||||
-DJPEGXL_ENABLE_BENCHMARK=OFF \
|
||||
-DJPEGXL_ENABLE_EXAMPLES=OFF \
|
||||
-DJPEGXL_ENABLE_JNI=OFF \
|
||||
-DJPEGXL_ENABLE_SJPEG=OFF \
|
||||
-DJPEGXL_ENABLE_OPENEXR=OFF \
|
||||
-DJPEGXL_ENABLE_SKCMS=OFF \
|
||||
&& cmake --build build \
|
||||
&& export DESTDIR=/usr/src/jxl-cache \
|
||||
&& cmake --install build \
|
||||
&& sed -i 's/-lstdc++//' $DESTDIR/usr/local/lib64/pkgconfig/libjxl*.pc \
|
||||
&& rm $DESTDIR/usr/local/lib64/libjpeg.so* \
|
||||
&& cp build/lib/libjpegli-static.a $DESTDIR/usr/local/lib64/libjpeg.a \
|
||||
&& mkdir build/hwy \
|
||||
&& ar --output=build/hwy x /usr/local/lib64/libhwy.a \
|
||||
&& ar rcs $DESTDIR/usr/local/lib64/libjpeg.a build/lib/CMakeFiles/jpegli-libjpeg-obj.dir/jpegli/libjpeg_wrapper.cc.o build/hwy/* \
|
||||
&& cd .. \
|
||||
&& rm -rf libjxl
|
||||
|
||||
FROM builder AS rnnoise
|
||||
RUN git clone -b v0.2 --depth=1 https://github.com/xiph/rnnoise.git \
|
||||
&& cd rnnoise \
|
||||
&& ./autogen.sh \
|
||||
&& ./configure --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/rnnoise-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf rnnoise
|
||||
|
||||
FROM builder AS xcb-proto
|
||||
RUN git clone -b xcb-proto-1.16.0 --depth=1 https://github.com/gitlab-freedesktop-mirrors/xcbproto.git \
|
||||
&& cd xcbproto \
|
||||
&& ./autogen.sh \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-proto-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf xcbproto
|
||||
|
||||
FROM builder AS xcb
|
||||
COPY --link --from=xcb-proto /usr/src/xcb-proto-cache /
|
||||
|
||||
RUN git clone -b libxcb-1.16 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxcb.git \
|
||||
&& cd libxcb \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& export DESTDIR=/usr/src/xcb-cache \
|
||||
&& make install \
|
||||
&& rm $DESTDIR/usr/local/lib/{libxcb.{,l}a,pkgconfig/xcb.pc} \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb
|
||||
|
||||
FROM builder AS xcb-wm
|
||||
RUN git clone -b xcb-util-wm-0.4.2 --depth=1 --recursive --shallow-submodules https://github.com/gitlab-freedesktop-mirrors/libxcb-wm.git \
|
||||
&& cd libxcb-wm \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-wm-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-wm
|
||||
|
||||
FROM builder AS xcb-util
|
||||
RUN git clone -b xcb-util-0.4.1-gitlab --depth=1 --recursive --shallow-submodules https://github.com/gitlab-freedesktop-mirrors/libxcb-util.git \
|
||||
&& cd libxcb-util \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-util-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-util
|
||||
|
||||
FROM builder AS xcb-image
|
||||
COPY --link --from=xcb-util /usr/src/xcb-util-cache /
|
||||
|
||||
RUN git clone -b xcb-util-image-0.4.1-gitlab --depth=1 --recursive --shallow-submodules https://github.com/gitlab-freedesktop-mirrors/libxcb-image.git \
|
||||
&& cd libxcb-image \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-image-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-image
|
||||
|
||||
FROM builder AS xcb-keysyms
|
||||
RUN git init libxcb-keysyms \
|
||||
&& cd libxcb-keysyms \
|
||||
&& git remote add origin https://github.com/gitlab-freedesktop-mirrors/libxcb-keysyms.git \
|
||||
&& git fetch --depth=1 origin ef5cb393d27511ba511c68a54f8ff7b9aab4a384 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& git submodule update --init --recursive --depth=1 \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-keysyms-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-keysyms
|
||||
|
||||
FROM builder AS xcb-render-util
|
||||
RUN git init libxcb-render-util \
|
||||
&& cd libxcb-render-util \
|
||||
&& git remote add origin https://github.com/gitlab-freedesktop-mirrors/libxcb-render-util.git \
|
||||
&& git fetch --depth=1 origin 5ad9853d6ddcac394d42dd2d4e34436b5db9da39 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& git submodule update --init --recursive --depth=1 \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-render-util-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-render-util
|
||||
|
||||
FROM builder AS xcb-cursor
|
||||
COPY --link --from=xcb-util /usr/src/xcb-util-cache /
|
||||
COPY --link --from=xcb-image /usr/src/xcb-image-cache /
|
||||
COPY --link --from=xcb-render-util /usr/src/xcb-render-util-cache /
|
||||
|
||||
RUN git init libxcb-cursor \
|
||||
&& cd libxcb-cursor \
|
||||
&& git remote add origin https://github.com/gitlab-freedesktop-mirrors/libxcb-cursor.git \
|
||||
&& git fetch --depth=1 origin 4929f6051658ba5424b41703a1fb63f9db896065 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& git submodule update --init --recursive --depth=1 \
|
||||
&& ./autogen.sh --enable-static --disable-shared --with-cursorpath='~/.local/share/icons:~/.icons:/usr/share/icons:/usr/share/pixmaps' \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcb-cursor-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcb-cursor
|
||||
|
||||
FROM builder AS xext
|
||||
RUN git clone -b libXext-1.3.5 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxext.git \
|
||||
&& cd libxext \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xext-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxext
|
||||
|
||||
FROM builder AS xtst
|
||||
RUN git clone -b libXtst-1.2.4 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxtst.git \
|
||||
&& cd libxtst \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xtst-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxtst
|
||||
|
||||
FROM builder AS xfixes
|
||||
RUN git clone -b libXfixes-5.0.3 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxfixes.git \
|
||||
&& cd libxfixes \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xfixes-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxfixes
|
||||
|
||||
FROM builder AS xv
|
||||
COPY --link --from=xext /usr/src/xext-cache /
|
||||
|
||||
RUN git clone -b libXv-1.0.12 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxv.git \
|
||||
&& cd libxv \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xv-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxv
|
||||
|
||||
FROM builder AS xrandr
|
||||
RUN git clone -b libXrandr-1.5.3 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxrandr.git \
|
||||
&& cd libxrandr \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xrandr-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxrandr
|
||||
|
||||
FROM builder AS xrender
|
||||
RUN git clone -b libXrender-0.9.11 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxrender.git \
|
||||
&& cd libxrender \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xrender-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxrender
|
||||
|
||||
FROM builder AS xdamage
|
||||
RUN git clone -b libXdamage-1.1.6 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxdamage.git \
|
||||
&& cd libxdamage \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xdamage-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxdamage
|
||||
|
||||
FROM builder AS xcomposite
|
||||
RUN git clone -b libXcomposite-0.4.6 --depth=1 https://github.com/gitlab-freedesktop-mirrors/libxcomposite.git \
|
||||
&& cd libxcomposite \
|
||||
&& ./autogen.sh --enable-static --disable-shared \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/xcomposite-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf libxcomposite
|
||||
|
||||
FROM builder AS nv-codec-headers
|
||||
RUN git clone -b n12.1.14.0 --depth=1 https://github.com/FFmpeg/nv-codec-headers.git \
|
||||
&& DESTDIR=/usr/src/nv-codec-headers-cache make -C nv-codec-headers install \
|
||||
&& rm -rf nv-codec-headers
|
||||
|
||||
FROM builder AS ffmpeg
|
||||
COPY --link --from=opus /usr/src/opus-cache /
|
||||
COPY --link --from=openh264 /usr/src/openh264-cache /
|
||||
COPY --link --from=dav1d /usr/src/dav1d-cache /
|
||||
COPY --link --from=vpx /usr/src/vpx-cache /
|
||||
COPY --link --from=xext /usr/src/xext-cache /
|
||||
COPY --link --from=xv /usr/src/xv-cache /
|
||||
COPY --link --from=nv-codec-headers /usr/src/nv-codec-headers-cache /
|
||||
|
||||
RUN git clone -b n6.1.1 --depth=1 https://github.com/FFmpeg/FFmpeg.git \
|
||||
&& cd FFmpeg \
|
||||
&& ./configure \
|
||||
--extra-cflags="-fno-lto -DCONFIG_SAFE_BITSTREAM_READER=1" \
|
||||
--extra-cxxflags="-fno-lto -DCONFIG_SAFE_BITSTREAM_READER=1" \
|
||||
--extra-ldflags="-Wl,--push-state,--no-as-needed,-lstdc++,--pop-state" \
|
||||
--disable-debug \
|
||||
--disable-programs \
|
||||
--disable-doc \
|
||||
--disable-network \
|
||||
--disable-autodetect \
|
||||
--disable-everything \
|
||||
--enable-libdav1d \
|
||||
--enable-libopenh264 \
|
||||
--enable-libopus \
|
||||
--enable-libvpx \
|
||||
--enable-vaapi \
|
||||
--enable-vdpau \
|
||||
--enable-xlib \
|
||||
--enable-libdrm \
|
||||
--enable-ffnvcodec \
|
||||
--enable-nvdec \
|
||||
--enable-cuvid \
|
||||
--enable-protocol=file \
|
||||
--enable-hwaccel=av1_vaapi \
|
||||
--enable-hwaccel=av1_nvdec \
|
||||
--enable-hwaccel=h264_vaapi \
|
||||
--enable-hwaccel=h264_vdpau \
|
||||
--enable-hwaccel=h264_nvdec \
|
||||
--enable-hwaccel=hevc_vaapi \
|
||||
--enable-hwaccel=hevc_vdpau \
|
||||
--enable-hwaccel=hevc_nvdec \
|
||||
--enable-hwaccel=mpeg2_vaapi \
|
||||
--enable-hwaccel=mpeg2_vdpau \
|
||||
--enable-hwaccel=mpeg2_nvdec \
|
||||
--enable-hwaccel=mpeg4_vaapi \
|
||||
--enable-hwaccel=mpeg4_vdpau \
|
||||
--enable-hwaccel=mpeg4_nvdec \
|
||||
--enable-hwaccel=vp8_vaapi \
|
||||
--enable-hwaccel=vp8_nvdec \
|
||||
--enable-decoder=aac \
|
||||
--enable-decoder=aac_fixed \
|
||||
--enable-decoder=aac_latm \
|
||||
--enable-decoder=aasc \
|
||||
--enable-decoder=ac3 \
|
||||
--enable-decoder=alac \
|
||||
--enable-decoder=av1 \
|
||||
--enable-decoder=av1_cuvid \
|
||||
--enable-decoder=eac3 \
|
||||
--enable-decoder=flac \
|
||||
--enable-decoder=gif \
|
||||
--enable-decoder=h264 \
|
||||
--enable-decoder=hevc \
|
||||
--enable-decoder=libdav1d \
|
||||
--enable-decoder=libvpx_vp8 \
|
||||
--enable-decoder=libvpx_vp9 \
|
||||
--enable-decoder=mp1 \
|
||||
--enable-decoder=mp1float \
|
||||
--enable-decoder=mp2 \
|
||||
--enable-decoder=mp2float \
|
||||
--enable-decoder=mp3 \
|
||||
--enable-decoder=mp3adu \
|
||||
--enable-decoder=mp3adufloat \
|
||||
--enable-decoder=mp3float \
|
||||
--enable-decoder=mp3on4 \
|
||||
--enable-decoder=mp3on4float \
|
||||
--enable-decoder=mpeg4 \
|
||||
--enable-decoder=msmpeg4v2 \
|
||||
--enable-decoder=msmpeg4v3 \
|
||||
--enable-decoder=opus \
|
||||
--enable-decoder=pcm_alaw \
|
||||
--enable-decoder=pcm_f32be \
|
||||
--enable-decoder=pcm_f32le \
|
||||
--enable-decoder=pcm_f64be \
|
||||
--enable-decoder=pcm_f64le \
|
||||
--enable-decoder=pcm_lxf \
|
||||
--enable-decoder=pcm_mulaw \
|
||||
--enable-decoder=pcm_s16be \
|
||||
--enable-decoder=pcm_s16be_planar \
|
||||
--enable-decoder=pcm_s16le \
|
||||
--enable-decoder=pcm_s16le_planar \
|
||||
--enable-decoder=pcm_s24be \
|
||||
--enable-decoder=pcm_s24daud \
|
||||
--enable-decoder=pcm_s24le \
|
||||
--enable-decoder=pcm_s24le_planar \
|
||||
--enable-decoder=pcm_s32be \
|
||||
--enable-decoder=pcm_s32le \
|
||||
--enable-decoder=pcm_s32le_planar \
|
||||
--enable-decoder=pcm_s64be \
|
||||
--enable-decoder=pcm_s64le \
|
||||
--enable-decoder=pcm_s8 \
|
||||
--enable-decoder=pcm_s8_planar \
|
||||
--enable-decoder=pcm_u16be \
|
||||
--enable-decoder=pcm_u16le \
|
||||
--enable-decoder=pcm_u24be \
|
||||
--enable-decoder=pcm_u24le \
|
||||
--enable-decoder=pcm_u32be \
|
||||
--enable-decoder=pcm_u32le \
|
||||
--enable-decoder=pcm_u8 \
|
||||
--enable-decoder=pcm_zork \
|
||||
--enable-decoder=vorbis \
|
||||
--enable-decoder=vp8 \
|
||||
--enable-decoder=wavpack \
|
||||
--enable-decoder=wmalossless \
|
||||
--enable-decoder=wmapro \
|
||||
--enable-decoder=wmav1 \
|
||||
--enable-decoder=wmav2 \
|
||||
--enable-decoder=wmavoice \
|
||||
--enable-encoder=aac \
|
||||
--enable-encoder=libopenh264 \
|
||||
--enable-encoder=libopus \
|
||||
--enable-encoder=pcm_s16le \
|
||||
--enable-filter=atempo \
|
||||
--enable-parser=aac \
|
||||
--enable-parser=aac_latm \
|
||||
--enable-parser=flac \
|
||||
--enable-parser=gif \
|
||||
--enable-parser=h264 \
|
||||
--enable-parser=hevc \
|
||||
--enable-parser=mpeg4video \
|
||||
--enable-parser=mpegaudio \
|
||||
--enable-parser=opus \
|
||||
--enable-parser=vorbis \
|
||||
--enable-demuxer=aac \
|
||||
--enable-demuxer=flac \
|
||||
--enable-demuxer=gif \
|
||||
--enable-demuxer=h264 \
|
||||
--enable-demuxer=hevc \
|
||||
--enable-demuxer=matroska \
|
||||
--enable-demuxer=m4v \
|
||||
--enable-demuxer=mov \
|
||||
--enable-demuxer=mp3 \
|
||||
--enable-demuxer=ogg \
|
||||
--enable-demuxer=wav \
|
||||
--enable-muxer=mp4 \
|
||||
--enable-muxer=ogg \
|
||||
--enable-muxer=opus \
|
||||
--enable-muxer=wav \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/ffmpeg-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf ffmpeg
|
||||
|
||||
FROM builder AS pipewire
|
||||
RUN git clone -b 0.3.62 --depth=1 https://github.com/PipeWire/pipewire.git \
|
||||
&& cd pipewire \
|
||||
&& meson build \
|
||||
--buildtype=plain \
|
||||
-Dtests=disabled \
|
||||
-Dexamples=disabled \
|
||||
-Dspa-plugins=disabled \
|
||||
-Dsession-managers= \
|
||||
&& meson compile -C build \
|
||||
&& DESTDIR=/usr/src/pipewire-cache meson install -C build \
|
||||
&& cd .. \
|
||||
&& rm -rf pipewire
|
||||
|
||||
FROM builder AS openal
|
||||
COPY --link --from=pipewire /usr/src/pipewire-cache /
|
||||
|
||||
RUN git clone -b 1.24.3 --depth=1 https://github.com/kcat/openal-soft.git \
|
||||
&& cd openal-soft \
|
||||
&& cmake -B build . \
|
||||
-DLIBTYPE:STRING=STATIC \
|
||||
-DALSOFT_EXAMPLES=OFF \
|
||||
-DALSOFT_UTILS=OFF \
|
||||
-DALSOFT_INSTALL_CONFIG=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/openal-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf openal-soft
|
||||
|
||||
FROM builder AS openssl
|
||||
RUN git clone -b openssl-3.2.1 --depth=1 https://github.com/openssl/openssl.git \
|
||||
&& cd openssl \
|
||||
&& ./config \
|
||||
--openssldir=/etc/ssl \
|
||||
no-shared \
|
||||
no-tests \
|
||||
no-dso \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/openssl-cache install_sw \
|
||||
&& cd .. \
|
||||
&& rm -rf openssl
|
||||
|
||||
FROM builder AS xkbcommon
|
||||
COPY --link --from=xcb /usr/src/xcb-cache /
|
||||
|
||||
RUN git clone -b xkbcommon-1.6.0 --depth=1 https://github.com/xkbcommon/libxkbcommon.git \
|
||||
&& cd libxkbcommon \
|
||||
&& meson build \
|
||||
--buildtype=plain \
|
||||
--default-library=static \
|
||||
-Denable-docs=false \
|
||||
-Denable-wayland=false \
|
||||
-Denable-xkbregistry=false \
|
||||
-Dxkb-config-root=/usr/share/X11/xkb \
|
||||
-Dxkb-config-extra-path=/etc/xkb \
|
||||
-Dx-locale-root=/usr/share/X11/locale \
|
||||
&& meson compile -C build \
|
||||
&& DESTDIR=/usr/src/xkbcommon-cache meson install -C build \
|
||||
&& cd .. \
|
||||
&& rm -rf libxkbcommon
|
||||
|
||||
FROM patches AS qt
|
||||
COPY --link --from=zlib /usr/src/zlib-cache /
|
||||
COPY --link --from=lcms2 /usr/src/lcms2-cache /
|
||||
COPY --link --from=webp /usr/src/webp-cache /
|
||||
COPY --link --from=jxl /usr/src/jxl-cache /
|
||||
COPY --link --from=xcb /usr/src/xcb-cache /
|
||||
COPY --link --from=xcb-wm /usr/src/xcb-wm-cache /
|
||||
COPY --link --from=xcb-util /usr/src/xcb-util-cache /
|
||||
COPY --link --from=xcb-image /usr/src/xcb-image-cache /
|
||||
COPY --link --from=xcb-keysyms /usr/src/xcb-keysyms-cache /
|
||||
COPY --link --from=xcb-render-util /usr/src/xcb-render-util-cache /
|
||||
COPY --link --from=xcb-cursor /usr/src/xcb-cursor-cache /
|
||||
COPY --link --from=openssl /usr/src/openssl-cache /
|
||||
COPY --link --from=xkbcommon /usr/src/xkbcommon-cache /
|
||||
|
||||
ENV QT=6.10.1
|
||||
RUN git clone -b v$QT --depth=1 https://github.com/qt/qt5.git \
|
||||
&& cd qt5 \
|
||||
&& git submodule update --init --recursive --depth=1 qtbase qtdeclarative qtwayland qtimageformats qtsvg qtshadertools \
|
||||
&& cd qtbase \
|
||||
&& find ../../patches/qtbase_$QT -type f -print0 | sort -z | xargs -r0 git apply \
|
||||
&& cd ../qtwayland \
|
||||
&& find ../../patches/qtwayland_$QT -type f -print0 | sort -z | xargs -r0 git apply \
|
||||
&& cd .. \
|
||||
&& cmake -B build . \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr/local \
|
||||
-DBUILD_SHARED_LIBS=OFF \
|
||||
{%- if ASAN %}
|
||||
-DFEATURE_sanitize_address=ON \
|
||||
{%- endif %}
|
||||
-DQT_QPA_PLATFORMS="wayland;xcb" \
|
||||
-DINPUT_libpng=qt \
|
||||
-DINPUT_harfbuzz=qt \
|
||||
-DINPUT_pcre=qt \
|
||||
-DFEATURE_icu=OFF \
|
||||
-DFEATURE_xcb_sm=OFF \
|
||||
-DFEATURE_eglfs=OFF \
|
||||
-DINPUT_dbus=runtime \
|
||||
-DINPUT_openssl=linked \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/qt-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf qt5
|
||||
|
||||
FROM builder AS breakpad
|
||||
RUN git clone -b v2024.02.16 --depth=1 https://chromium.googlesource.com/breakpad/breakpad.git \
|
||||
&& cd breakpad \
|
||||
&& git clone -b v2024.02.01 --depth=1 https://chromium.googlesource.com/linux-syscall-support.git src/third_party/lss \
|
||||
&& CFLAGS="$CFLAGS -fno-lto" CXXFLAGS="$CXXFLAGS -fno-lto" ./configure \
|
||||
&& make -j$(nproc) \
|
||||
&& make DESTDIR=/usr/src/breakpad-cache install \
|
||||
&& cd .. \
|
||||
&& rm -rf breakpad
|
||||
|
||||
FROM builder AS webrtc
|
||||
COPY --link --from=zlib /usr/src/zlib-cache /
|
||||
COPY --link --from=opus /usr/src/opus-cache /
|
||||
COPY --link --from=openh264 /usr/src/openh264-cache /
|
||||
COPY --link --from=dav1d /usr/src/dav1d-cache /
|
||||
COPY --link --from=vpx /usr/src/vpx-cache /
|
||||
COPY --link --from=jxl /usr/src/jxl-cache /
|
||||
COPY --link --from=ffmpeg /usr/src/ffmpeg-cache /
|
||||
COPY --link --from=openssl /usr/src/openssl-cache /
|
||||
COPY --link --from=xext /usr/src/xext-cache /
|
||||
COPY --link --from=xfixes /usr/src/xfixes-cache /
|
||||
COPY --link --from=xtst /usr/src/xtst-cache /
|
||||
COPY --link --from=xrandr /usr/src/xrandr-cache /
|
||||
COPY --link --from=xrender /usr/src/xrender-cache /
|
||||
COPY --link --from=xdamage /usr/src/xdamage-cache /
|
||||
COPY --link --from=xcomposite /usr/src/xcomposite-cache /
|
||||
COPY --link --from=pipewire /usr/src/pipewire-cache /
|
||||
|
||||
# Shallow clone on a specific commit.
|
||||
RUN git init tg_owt \
|
||||
&& cd tg_owt \
|
||||
&& git remote add origin https://github.com/desktop-app/tg_owt.git \
|
||||
&& git fetch --depth=1 origin 5c5c71258777d0196dbb3a09cc37d2f56ead28ab \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& git submodule update --init --recursive --depth=1 \
|
||||
&& cmake -B build . -DTG_OWT_DLOPEN_PIPEWIRE=ON \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/webrtc-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf tg_owt
|
||||
|
||||
FROM builder AS ada
|
||||
RUN git clone -b v3.2.4 --depth=1 https://github.com/ada-url/ada.git \
|
||||
&& cd ada \
|
||||
&& cmake -B build . \
|
||||
-D ADA_TESTING=OFF \
|
||||
-D ADA_TOOLS=OFF \
|
||||
-D ADA_INCLUDE_URL_PATTERN=OFF \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/ada-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf ada
|
||||
|
||||
FROM builder AS tde2e
|
||||
COPY --link --from=zlib /usr/src/zlib-cache /
|
||||
COPY --link --from=openssl /usr/src/openssl-cache /
|
||||
|
||||
# Shallow clone on a specific commit.
|
||||
RUN git init tde2e \
|
||||
&& cd tde2e \
|
||||
&& git remote add origin https://github.com/tdlib/td.git \
|
||||
&& git fetch --depth=1 origin 51743dfd01dff6179e2d8f7095729caa4e2222e9 \
|
||||
&& git reset --hard FETCH_HEAD \
|
||||
&& cmake -B build . -DTD_E2E_ONLY=ON \
|
||||
&& cmake --build build \
|
||||
&& DESTDIR=/usr/src/tde2e-cache cmake --install build \
|
||||
&& cd .. \
|
||||
&& rm -rf tde2e
|
||||
|
||||
FROM builder
|
||||
COPY --link --from=zlib /usr/src/zlib-cache /
|
||||
COPY --link --from=xz /usr/src/xz-cache /
|
||||
COPY --link --from=protobuf /usr/src/protobuf-cache /
|
||||
COPY --link --from=lcms2 /usr/src/lcms2-cache /
|
||||
COPY --link --from=brotli /usr/src/brotli-cache /
|
||||
COPY --link --from=highway /usr/src/highway-cache /
|
||||
COPY --link --from=opus /usr/src/opus-cache /
|
||||
COPY --link --from=dav1d /usr/src/dav1d-cache /
|
||||
COPY --link --from=openh264 /usr/src/openh264-cache /
|
||||
COPY --link --from=de265 /usr/src/de265-cache /
|
||||
COPY --link --from=vpx /usr/src/vpx-cache /
|
||||
COPY --link --from=webp /usr/src/webp-cache /
|
||||
COPY --link --from=avif /usr/src/avif-cache /
|
||||
COPY --link --from=heif /usr/src/heif-cache /
|
||||
COPY --link --from=jxl /usr/src/jxl-cache /
|
||||
COPY --link --from=rnnoise /usr/src/rnnoise-cache /
|
||||
COPY --link --from=xcb /usr/src/xcb-cache /
|
||||
COPY --link --from=xcb-wm /usr/src/xcb-wm-cache /
|
||||
COPY --link --from=xcb-util /usr/src/xcb-util-cache /
|
||||
COPY --link --from=xcb-image /usr/src/xcb-image-cache /
|
||||
COPY --link --from=xcb-keysyms /usr/src/xcb-keysyms-cache /
|
||||
COPY --link --from=xcb-render-util /usr/src/xcb-render-util-cache /
|
||||
COPY --link --from=xcb-cursor /usr/src/xcb-cursor-cache /
|
||||
COPY --link --from=xext /usr/src/xext-cache /
|
||||
COPY --link --from=xfixes /usr/src/xfixes-cache /
|
||||
COPY --link --from=xv /usr/src/xv-cache /
|
||||
COPY --link --from=xtst /usr/src/xtst-cache /
|
||||
COPY --link --from=xrandr /usr/src/xrandr-cache /
|
||||
COPY --link --from=xrender /usr/src/xrender-cache /
|
||||
COPY --link --from=xdamage /usr/src/xdamage-cache /
|
||||
COPY --link --from=xcomposite /usr/src/xcomposite-cache /
|
||||
COPY --link --from=ffmpeg /usr/src/ffmpeg-cache /
|
||||
COPY --link --from=openal /usr/src/openal-cache /
|
||||
COPY --link --from=openssl /usr/src/openssl-cache /
|
||||
COPY --link --from=xkbcommon /usr/src/xkbcommon-cache /
|
||||
COPY --link --from=qt /usr/src/qt-cache /
|
||||
COPY --link --from=breakpad /usr/src/breakpad-cache /
|
||||
COPY --link --from=webrtc /usr/src/webrtc-cache /
|
||||
COPY --link --from=ada /usr/src/ada-cache /
|
||||
COPY --link --from=tde2e /usr/src/tde2e-cache /
|
||||
|
||||
COPY --link --from=patches /usr/src/patches patches
|
||||
RUN patch -p1 -d /usr/lib64/gobject-introspection -i $PWD/patches/gobject-introspection.patch && rm -rf patches
|
||||
|
||||
WORKDIR /usr/src/tdesktop
|
||||
ENV BOOST_INCLUDEDIR=/usr/include/boost1.78
|
||||
ENV BOOST_LIBRARYDIR=/usr/lib64/boost1.78
|
||||
|
||||
USER user
|
||||
VOLUME [ "/usr/src/tdesktop" ]
|
||||
CMD [ "/usr/src/tdesktop/Telegram/build/docker/centos_env/build.sh" ]
|
||||
6
Telegram/build/docker/centos_env/build.sh
Executable file
6
Telegram/build/docker/centos_env/build.sh
Executable file
@@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
cd Telegram
|
||||
./configure.sh "$@"
|
||||
cmake --build ../out --config "${CONFIG:-Release}"
|
||||
1
Telegram/build/docker/centos_env/centos_env/__init__.py
Normal file
1
Telegram/build/docker/centos_env/centos_env/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
|
||||
20
Telegram/build/docker/centos_env/gen_dockerfile.py
Executable file
20
Telegram/build/docker/centos_env/gen_dockerfile.py
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env python3
|
||||
from os import environ
|
||||
from os.path import dirname
|
||||
from jinja2 import Environment, FileSystemLoader
|
||||
|
||||
def checkEnv(envName, defaultValue):
|
||||
if isinstance(defaultValue, bool):
|
||||
return bool(len(environ[envName])) if envName in environ else defaultValue
|
||||
return environ[envName] if envName in environ else defaultValue
|
||||
|
||||
def main():
|
||||
print(Environment(loader=FileSystemLoader(dirname(__file__))).get_template("Dockerfile").render(
|
||||
DEBUG=checkEnv("DEBUG", True),
|
||||
LTO=checkEnv("LTO", True),
|
||||
ASAN=checkEnv("ASAN", False),
|
||||
JOBS=checkEnv("JOBS", ""),
|
||||
))
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
74
Telegram/build/docker/centos_env/poetry.lock
generated
Normal file
74
Telegram/build/docker/centos_env/poetry.lock
generated
Normal file
@@ -0,0 +1,74 @@
|
||||
# This file is automatically @generated by Poetry 2.1.1 and should not be changed by hand.
|
||||
|
||||
[[package]]
|
||||
name = "jinja2"
|
||||
version = "3.1.6"
|
||||
description = "A very fast and expressive template engine."
|
||||
optional = false
|
||||
python-versions = ">=3.7"
|
||||
groups = ["main"]
|
||||
files = [
|
||||
{file = "jinja2-3.1.6-py3-none-any.whl", hash = "sha256:85ece4451f492d0c13c5dd7c13a64681a86afae63a5f347908daf103ce6d2f67"},
|
||||
{file = "jinja2-3.1.6.tar.gz", hash = "sha256:0137fb05990d35f1275a587e9aee6d56da821fc83491a0fb838183be43f66d6d"},
|
||||
]
|
||||
|
||||
[package.dependencies]
|
||||
MarkupSafe = ">=2.0"
|
||||
|
||||
[package.extras]
|
||||
i18n = ["Babel (>=2.7)"]
|
||||
|
||||
[[package]]
|
||||
name = "markupsafe"
|
||||
version = "2.1.1"
|
||||
description = "Safely add untrusted strings to HTML/XML markup."
|
||||
optional = false
|
||||
python-versions = ">=3.7"
|
||||
groups = ["main"]
|
||||
files = [
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:10c1bfff05d95783da83491be968e8fe789263689c02724e0c691933c52994f5"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b7bd98b796e2b6553da7225aeb61f447f80a1ca64f41d83612e6139ca5213aa4"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:b09bf97215625a311f669476f44b8b318b075847b49316d3e28c08e41a7a573f"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:694deca8d702d5db21ec83983ce0bb4b26a578e71fbdbd4fdcd387daa90e4d5e"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:efc1913fd2ca4f334418481c7e595c00aad186563bbc1ec76067848c7ca0a933"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-win32.whl", hash = "sha256:4a33dea2b688b3190ee12bd7cfa29d39c9ed176bda40bfa11099a3ce5d3a7ac6"},
|
||||
{file = "MarkupSafe-2.1.1-cp310-cp310-win_amd64.whl", hash = "sha256:dda30ba7e87fbbb7eab1ec9f58678558fd9a6b8b853530e176eabd064da81417"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:671cd1187ed5e62818414afe79ed29da836dde67166a9fac6d435873c44fdd02"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3799351e2336dc91ea70b034983ee71cf2f9533cdff7c14c90ea126bfd95d65a"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e72591e9ecd94d7feb70c1cbd7be7b3ebea3f548870aa91e2732960fa4d57a37"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6fbf47b5d3728c6aea2abb0589b5d30459e369baa772e0f37a0320185e87c980"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:d5ee4f386140395a2c818d149221149c54849dfcfcb9f1debfe07a8b8bd63f9a"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:bcb3ed405ed3222f9904899563d6fc492ff75cce56cba05e32eff40e6acbeaa3"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:e1c0b87e09fa55a220f058d1d49d3fb8df88fbfab58558f1198e08c1e1de842a"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-win32.whl", hash = "sha256:8dc1c72a69aa7e082593c4a203dcf94ddb74bb5c8a731e4e1eb68d031e8498ff"},
|
||||
{file = "MarkupSafe-2.1.1-cp37-cp37m-win_amd64.whl", hash = "sha256:97a68e6ada378df82bc9f16b800ab77cbf4b2fada0081794318520138c088e4a"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:e8c843bbcda3a2f1e3c2ab25913c80a3c5376cd00c6e8c4a86a89a28c8dc5452"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0212a68688482dc52b2d45013df70d169f542b7394fc744c02a57374a4207003"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8e576a51ad59e4bfaac456023a78f6b5e6e7651dcd383bcc3e18d06f9b55d6d1"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b9fe39a2ccc108a4accc2676e77da025ce383c108593d65cc909add5c3bd601"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:96e37a3dc86e80bf81758c152fe66dbf60ed5eca3d26305edf01892257049925"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6d0072fea50feec76a4c418096652f2c3238eaa014b2f94aeb1d56a66b41403f"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:089cf3dbf0cd6c100f02945abeb18484bd1ee57a079aefd52cffd17fba910b88"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:6a074d34ee7a5ce3effbc526b7083ec9731bb3cbf921bbe1d3005d4d2bdb3a63"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-win32.whl", hash = "sha256:421be9fbf0ffe9ffd7a378aafebbf6f4602d564d34be190fc19a193232fd12b1"},
|
||||
{file = "MarkupSafe-2.1.1-cp38-cp38-win_amd64.whl", hash = "sha256:fc7b548b17d238737688817ab67deebb30e8073c95749d55538ed473130ec0c7"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e04e26803c9c3851c931eac40c695602c6295b8d432cbe78609649ad9bd2da8a"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:b87db4360013327109564f0e591bd2a3b318547bcef31b468a92ee504d07ae4f"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:99a2a507ed3ac881b975a2976d59f38c19386d128e7a9a18b7df6fff1fd4c1d6"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:56442863ed2b06d19c37f94d999035e15ee982988920e12a5b4ba29b62ad1f77"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3ce11ee3f23f79dbd06fb3d63e2f6af7b12db1d46932fe7bd8afa259a5996603"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:33b74d289bd2f5e527beadcaa3f401e0df0a89927c1559c8566c066fa4248ab7"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:43093fb83d8343aac0b1baa75516da6092f58f41200907ef92448ecab8825135"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:8e3dcf21f367459434c18e71b2a9532d96547aef8a871872a5bd69a715c15f96"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-win32.whl", hash = "sha256:d4306c36ca495956b6d568d276ac11fdd9c30a36f1b6eb928070dc5360b22e1c"},
|
||||
{file = "MarkupSafe-2.1.1-cp39-cp39-win_amd64.whl", hash = "sha256:46d00d6cfecdde84d40e572d63735ef81423ad31184100411e6e3388d405e247"},
|
||||
{file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"},
|
||||
]
|
||||
|
||||
[metadata]
|
||||
lock-version = "2.1"
|
||||
python-versions = "^3.7"
|
||||
content-hash = "375b9a134584d381be4e5f1a5a3a6935f2ff7852fdf3fef8b128d3d1e89263f8"
|
||||
18
Telegram/build/docker/centos_env/pyproject.toml
Normal file
18
Telegram/build/docker/centos_env/pyproject.toml
Normal file
@@ -0,0 +1,18 @@
|
||||
[tool.poetry]
|
||||
name = "centos_env"
|
||||
version = "0.1.0"
|
||||
description = ""
|
||||
authors = []
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.7"
|
||||
Jinja2 = "^3.1.6"
|
||||
|
||||
[tool.poetry.dev-dependencies]
|
||||
|
||||
[tool.poetry.scripts]
|
||||
gen_dockerfile = "gen_dockerfile:main"
|
||||
|
||||
[build-system]
|
||||
requires = ["poetry-core>=1.0.0"]
|
||||
build-backend = "poetry.core.masonry.api"
|
||||
21
Telegram/build/docker/centos_env/run.sh
Executable file
21
Telegram/build/docker/centos_env/run.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
set -e
|
||||
FullExecPath=$PWD
|
||||
pushd `dirname $0` > /dev/null
|
||||
FullScriptPath=`pwd`
|
||||
popd > /dev/null
|
||||
|
||||
if [ ! -d "$FullScriptPath/../../../../../DesktopPrivate" ]; then
|
||||
echo ""
|
||||
echo "This script is for building the production version of Telegram Desktop."
|
||||
echo ""
|
||||
echo "For building custom versions please visit the build instructions page at:"
|
||||
echo "https://github.com/telegramdesktop/tdesktop/#build-instructions"
|
||||
exit
|
||||
fi
|
||||
|
||||
Command="$1"
|
||||
if [ "$Command" == "" ]; then
|
||||
Command="bash"
|
||||
fi
|
||||
|
||||
docker run -it --rm --cpus=8 --memory=22g -u $(id -u) -v $HOME/Telegram/DesktopPrivate:/usr/src/DesktopPrivate -v $HOME/Telegram/tdesktop:/usr/src/tdesktop tdesktop:centos_env $Command
|
||||
Reference in New Issue
Block a user