mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Have a variable to control debug info in docker image
This commit is contained in:
parent
68f35e98e0
commit
9cc1a020f3
2 changed files with 9 additions and 5 deletions
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
|
@ -22,4 +22,4 @@ jobs:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
|
|
||||||
- name: Docker image build.
|
- name: Docker image build.
|
||||||
run: docker build -t telegram_desktop Telegram/build/docker/centos_env
|
run: docker build -t telegram_desktop --build-arg DEBUG= Telegram/build/docker/centos_env
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
FROM centos:7 AS builder
|
ARG DEBUG 1
|
||||||
|
|
||||||
|
FROM centos:7 AS builder
|
||||||
ENV GIT https://github.com
|
ENV GIT https://github.com
|
||||||
ENV GIT_FREEDESKTOP ${GIT}/gitlab-freedesktop-mirrors
|
ENV GIT_FREEDESKTOP ${GIT}/gitlab-freedesktop-mirrors
|
||||||
ENV PKG_CONFIG_PATH /usr/local/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/share/pkgconfig
|
ENV PKG_CONFIG_PATH /usr/local/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/share/pkgconfig
|
||||||
|
@ -527,6 +528,7 @@ COPY --from=wayland ${LibrariesPath}/wayland-cache /
|
||||||
COPY --from=openssl ${LibrariesPath}/openssl-cache /
|
COPY --from=openssl ${LibrariesPath}/openssl-cache /
|
||||||
COPY --from=xkbcommon ${LibrariesPath}/xkbcommon-cache /
|
COPY --from=xkbcommon ${LibrariesPath}/xkbcommon-cache /
|
||||||
|
|
||||||
|
ARG DEBUG
|
||||||
RUN git clone -b ${QT_TAG} --depth=1 git://code.qt.io/qt/qt5.git qt_${QT} \
|
RUN git clone -b ${QT_TAG} --depth=1 git://code.qt.io/qt/qt5.git qt_${QT} \
|
||||||
&& cd qt_${QT} \
|
&& cd qt_${QT} \
|
||||||
&& perl init-repository --module-subset=qtbase,qtwayland,qtimageformats,qtsvg,qt5compat \
|
&& perl init-repository --module-subset=qtbase,qtwayland,qtimageformats,qtsvg,qt5compat \
|
||||||
|
@ -535,7 +537,7 @@ RUN git clone -b ${QT_TAG} --depth=1 git://code.qt.io/qt/qt5.git qt_${QT} \
|
||||||
&& cd .. \
|
&& cd .. \
|
||||||
&& ./configure -prefix "$QT_PREFIX" \
|
&& ./configure -prefix "$QT_PREFIX" \
|
||||||
-release \
|
-release \
|
||||||
-force-debug-info \
|
${DEBUG:+-force-debug-info} \
|
||||||
-opensource \
|
-opensource \
|
||||||
-confirm-license \
|
-confirm-license \
|
||||||
-libproxy \
|
-libproxy \
|
||||||
|
@ -609,8 +611,10 @@ RUN cmake --build out --config Release --parallel \
|
||||||
&& find out -mindepth 1 -maxdepth 1 ! -name Release -exec rm -rf {} \;
|
&& find out -mindepth 1 -maxdepth 1 ! -name Release -exec rm -rf {} \;
|
||||||
|
|
||||||
FROM webrtc AS webrtc_debug
|
FROM webrtc AS webrtc_debug
|
||||||
RUN cmake --build out --config Debug --parallel \
|
ARG DEBUG
|
||||||
&& find out -mindepth 1 -maxdepth 1 ! -name Debug -exec rm -rf {} \;
|
RUN [ -z "$DEBUG" ] || (cmake --build out --config Debug --parallel \
|
||||||
|
&& find out -mindepth 1 -maxdepth 1 ! -name Debug -exec rm -rf {} \;)
|
||||||
|
RUN [ -n "$DEBUG" ] || mkdir -p out/Debug
|
||||||
|
|
||||||
FROM builder
|
FROM builder
|
||||||
COPY --from=libffi ${LibrariesPath}/libffi-cache /
|
COPY --from=libffi ${LibrariesPath}/libffi-cache /
|
||||||
|
|
Loading…
Add table
Reference in a new issue