2021-01-10 23:40:17 +00:00
|
|
|
FROM ubuntu:20.04
|
|
|
|
|
|
|
|
ARG THREADS=1
|
2022-03-14 10:33:42 +00:00
|
|
|
ARG QT_VERSION=v5.15.3-lts-lgpl
|
2021-01-10 23:40:17 +00:00
|
|
|
ENV SOURCE_DATE_EPOCH=1397818193
|
2021-06-25 14:14:49 +00:00
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
|
|
|
|
|
|
# Feather build flags
|
|
|
|
ENV CHECK_UPDATES=ON
|
|
|
|
ENV WITH_SCANNER=ON
|
2021-01-10 23:40:17 +00:00
|
|
|
|
2021-02-05 10:53:18 +00:00
|
|
|
ENV OPENSSL_ROOT_DIR=/usr/local/openssl/
|
|
|
|
|
2021-01-10 23:40:17 +00:00
|
|
|
RUN apt update && \
|
2021-06-25 14:14:49 +00:00
|
|
|
apt install -y \
|
2022-02-23 16:04:23 +00:00
|
|
|
curl wget zip automake build-essential gcc-mingw-w64 g++-mingw-w64 gettext git libtool pkg-config \
|
2021-06-25 14:14:49 +00:00
|
|
|
python \
|
|
|
|
# zbar
|
|
|
|
autopoint && \
|
2021-01-10 23:40:17 +00:00
|
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
|
|
|
|
RUN update-alternatives --set x86_64-w64-mingw32-g++ $(which x86_64-w64-mingw32-g++-posix) && \
|
|
|
|
update-alternatives --set x86_64-w64-mingw32-gcc $(which x86_64-w64-mingw32-gcc-posix)
|
|
|
|
|
2022-02-23 16:04:23 +00:00
|
|
|
# The version from ubuntu repo is too old
|
|
|
|
RUN git clone -b v3.22.2 --depth 1 https://github.com/Kitware/CMake && \
|
|
|
|
cd CMake && \
|
|
|
|
git reset --hard 8428e39ed9cddb3b7f1a6f7a58cb8617503183d2 && \
|
|
|
|
./bootstrap -- -DCMAKE_USE_OPENSSL=OFF && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
2021-04-26 10:58:17 +00:00
|
|
|
RUN git clone -b v0.17.2.0 --depth 1 https://github.com/monero-project/monero && \
|
2021-01-10 23:40:17 +00:00
|
|
|
cd monero && \
|
2021-04-26 10:58:17 +00:00
|
|
|
git reset --hard f6e63ef260e795aacd408c28008398785b84103a && \
|
2021-01-10 23:40:17 +00:00
|
|
|
cp -a contrib/depends / && \
|
|
|
|
cd .. && \
|
|
|
|
rm -rf monero
|
|
|
|
|
|
|
|
RUN make -j$THREADS -C /depends HOST=x86_64-w64-mingw32 NO_QT=1
|
|
|
|
|
|
|
|
RUN git clone git://code.qt.io/qt/qt5.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
cd qt5 && \
|
|
|
|
git clone git://code.qt.io/qt/qtbase.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qtimageformats.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qtmultimedia.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qtsvg.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qttools.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qttranslations.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qtxmlpatterns.git -b ${QT_VERSION} --depth 1 && \
|
|
|
|
git clone git://code.qt.io/qt/qtwebsockets.git -b ${QT_VERSION} --depth 1 && \
|
2021-04-26 11:00:42 +00:00
|
|
|
OPENSSL_LIBS="-lssl -lcrypto -lws2_32" \
|
2021-01-10 23:40:17 +00:00
|
|
|
./configure --prefix=/depends/x86_64-w64-mingw32 -xplatform win32-g++ \
|
|
|
|
-device-option CROSS_COMPILE=/usr/bin/x86_64-w64-mingw32- \
|
|
|
|
-I $(pwd)/qtbase/src/3rdparty/angle/include \
|
|
|
|
-opensource -confirm-license -release -static -static-runtime -no-opengl \
|
2021-04-26 11:00:42 +00:00
|
|
|
-no-avx -openssl-linked -I /depends/x86_64-w64-mingw32/include -L /depends/x86_64-w64-mingw32/lib \
|
2021-01-10 23:40:17 +00:00
|
|
|
-qt-freetype -qt-harfbuzz -qt-libjpeg -qt-libpng -qt-pcre -qt-zlib \
|
|
|
|
-skip gamepad -skip location -skip qt3d -skip qtactiveqt -skip qtandroidextras \
|
|
|
|
-skip qtcanvas3d -skip qtcharts -skip qtconnectivity -skip qtdatavis3d -skip qtdoc \
|
|
|
|
-skip qtgamepad -skip qtlocation -skip qtmacextras -skip qtnetworkauth -skip qtpurchasing \
|
|
|
|
-skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport \
|
|
|
|
-skip qtspeech -skip qttools -skip qtvirtualkeyboard -skip qtwayland -skip qtwebchannel \
|
|
|
|
-skip qtwebengine -skip qtwebview -skip qtwinextras -skip qtx11extras \
|
|
|
|
-skip qtdeclarative -skip qtquickcontrols -skip qtquickcontrols2 \
|
|
|
|
-skip serialbus -skip webengine \
|
|
|
|
-nomake examples -nomake tests -nomake tools && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
cd qttools/src/linguist/lrelease && \
|
|
|
|
../../../../qtbase/bin/qmake && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
cd ../../../.. && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
|
|
|
RUN git clone -b libgpg-error-1.38 --depth 1 git://git.gnupg.org/libgpg-error.git && \
|
|
|
|
cd libgpg-error && \
|
|
|
|
git reset --hard 71d278824c5fe61865f7927a2ed1aa3115f9e439 && \
|
|
|
|
./autogen.sh && \
|
|
|
|
./configure --disable-shared --enable-static --disable-doc --disable-tests \
|
|
|
|
--host=x86_64-w64-mingw32 --prefix=/depends/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
cd .. && \
|
|
|
|
rm -rf libgpg-error
|
|
|
|
|
|
|
|
RUN git clone -b libgcrypt-1.8.5 --depth 1 git://git.gnupg.org/libgcrypt.git && \
|
|
|
|
cd libgcrypt && \
|
|
|
|
git reset --hard 56606331bc2a80536db9fc11ad53695126007298 && \
|
|
|
|
./autogen.sh && \
|
|
|
|
./configure --disable-shared --enable-static --disable-doc \
|
|
|
|
--host=x86_64-w64-mingw32 --prefix=/depends/x86_64-w64-mingw32 \
|
|
|
|
--with-gpg-error-prefix=/depends/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
cd .. && \
|
|
|
|
rm -rf libgcrypt
|
|
|
|
|
2022-02-23 16:04:23 +00:00
|
|
|
# zlib -> libpng
|
2021-01-10 23:40:17 +00:00
|
|
|
RUN git clone -b v1.2.11 --depth 1 https://github.com/madler/zlib && \
|
|
|
|
cd zlib && \
|
|
|
|
git reset --hard cacf7f1d4e3d44d871b605da3b647f07d718623f && \
|
|
|
|
CC=x86_64-w64-mingw32-gcc AR=x86_64-w64-mingw32-ar ./configure --static --prefix=/usr/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
|
|
|
# libpng -> libqrencode
|
|
|
|
RUN git clone -b libpng16 --depth 1 https://github.com/glennrp/libpng.git && \
|
|
|
|
cd libpng && \
|
2021-03-24 13:16:11 +00:00
|
|
|
git reset --hard a37d4836519517bdce6cb9d956092321eca3e73b && \
|
2021-01-10 23:40:17 +00:00
|
|
|
CPPFLAGS="-I/depends/x86_64-w64-mingw32/include" LDFLAGS="-L/depends/x86_64-w64-mingw32/lib" \
|
|
|
|
./configure --host=x86_64-w64-mingw32 --prefix=/depends/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
|
|
|
RUN git clone -b v4.0.2 --depth 1 https://github.com/fukuchi/libqrencode.git && \
|
|
|
|
cd libqrencode && \
|
|
|
|
git reset --hard 59ee597f913fcfda7a010a6e106fbee2595f68e4 && \
|
|
|
|
./autogen.sh && \
|
|
|
|
CPPFLAGS="-I/depends/x86_64-w64-mingw32/include" LDFLAGS="-L/depends/x86_64-w64-mingw32/lib" \
|
|
|
|
./configure --disable-shared --enable-static --host=x86_64-w64-mingw32 --prefix=/depends/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
|
|
|
RUN wget https://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.16.tar.gz && \
|
|
|
|
echo "e6a1b1b589654277ee790cce3734f07876ac4ccfaecbee8afa0b649cf529cc04 libiconv-1.16.tar.gz" | sha256sum -c && \
|
|
|
|
tar -xzf libiconv-1.16.tar.gz && \
|
|
|
|
rm libiconv-1.16.tar.gz && \
|
|
|
|
cd libiconv-1.16 && \
|
|
|
|
./configure --enable-static --host=x86_64-w64-mingw32 --prefix=/usr/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
|
|
|
|
2022-02-23 16:04:23 +00:00
|
|
|
# TOR_VERSION is used by CMAKE to determine embedded version
|
|
|
|
ENV TOR_VERSION=0.4.6.9
|
|
|
|
ENV TOR_DIR=/tor/Tor/
|
|
|
|
RUN wget https://dist.torproject.org/torbrowser/11.0.6/tor-win64-0.4.6.9.zip && \
|
|
|
|
echo "fabb46fb0b82c7cd3592c96554ffd8c0766b2e467559e3613b3e14ac191aed19 tor-win64-0.4.6.9.zip" | sha256sum -c && \
|
|
|
|
unzip tor-win64-0.4.6.9.zip -d tor && \
|
|
|
|
rm tor-win64-0.4.6.9.zip
|
2021-01-12 13:31:40 +00:00
|
|
|
|
2021-04-26 11:01:17 +00:00
|
|
|
RUN git clone https://github.com/nih-at/libzip.git && \
|
|
|
|
cd libzip && \
|
|
|
|
git reset --hard 66e496489bdae81bfda8b0088172871d8fda0032 && \
|
|
|
|
cmake -DCMAKE_INSTALL_PREFIX=/depends/x86_64-w64-mingw32 \
|
|
|
|
-DCMAKE_TOOLCHAIN_FILE=/depends/x86_64-w64-mingw32/share/toolchain.cmake \
|
|
|
|
-DBUILD_SHARED_LIBS=OFF \
|
|
|
|
-DCMAKE_PREFIX_PATH=/usr/x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
2021-07-10 13:48:10 +00:00
|
|
|
make -j$THREADS install && \
|
|
|
|
rm -rf $(pwd)
|
2021-06-25 14:14:49 +00:00
|
|
|
|
|
|
|
RUN git clone -b 0.23.92 --depth 1 --recursive https://github.com/mchehab/zbar.git && \
|
|
|
|
cd zbar && \
|
|
|
|
git reset --hard aac86d5f08d64ab4c3da78188eb622fa3cb07182 && \
|
|
|
|
autoreconf -vfi && \
|
|
|
|
./configure --enable-static --disable-shared --without-imagemagick --disable-video --without-xv --with-gtk=no --with-python=no --enable-doc=no --host=x86_64-w64-mingw32 && \
|
|
|
|
make -j$THREADS && \
|
2021-07-10 13:48:10 +00:00
|
|
|
make install && \
|
|
|
|
rm -rf $(pwd)
|