1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

chore(ci): Windows docker build fixes

* Fix unit tests not running in windows build
* Fix missing comment ports from old build script
This commit is contained in:
Mick Sayson 2022-01-09 12:55:55 -08:00 committed by Anthony Bilinski
parent 1bc72ab1a4
commit 1288a0a7fa
No known key found for this signature in database
GPG Key ID: 2AA8E0DA1B31FB3C
7 changed files with 17 additions and 5 deletions

View File

@ -326,7 +326,7 @@ jobs:
with:
docker_image_name: windows_builder
- name: Run build
run: docker-compose run --rm windows_builder ./windows/cross-compile/build.sh --arch x86_64 --build-type ${{ matrix.build_type }} --src-dir /qtox
run: docker-compose run --rm windows_builder ./windows/cross-compile/build.sh --arch x86_64 --build-type ${{ matrix.build_type }} --run-tests --src-dir /qtox
- name: Upload installer
uses: actions/upload-artifact@v2
with:
@ -398,7 +398,7 @@ jobs:
with:
docker_image_name: windows_builder.i686
- name: Run build
run: docker-compose run --rm windows_builder.i686 ./windows/cross-compile/build.sh --arch i686 --build-type ${{ matrix.build_type }} --src-dir /qtox
run: docker-compose run --rm windows_builder.i686 ./windows/cross-compile/build.sh --arch i686 --build-type ${{ matrix.build_type }} --run-tests --src-dir /qtox
- name: Upload installer
uses: actions/upload-artifact@v2
with:

View File

@ -54,7 +54,7 @@ fi
--openssldir=/windows/ssl \
shared \
$OPENSSL_ARCH \
--cross-compile-prefix=${ARCH}-w64-mingw32- && \
--cross-compile-prefix=${ARCH}-w64-mingw32-
make -j $(nproc)
make install

View File

@ -41,6 +41,9 @@ fi
"$(dirname "$0")"/download/download_vpx.sh
# There is a bug in gcc that breaks avx512 on 64-bit Windows https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54412
# VPX fails to build due to it.
# This is a workaround as suggested in https://stackoverflow.com/questions/43152633
if [ "${ARCH}" == "x86_64" ]; then
ARCH_FLAGS="-fno-asynchronous-unwind-tables"
VPX_ARCH="x86_64-win64-gcc"

View File

@ -21,6 +21,7 @@ NSISSHELLEXECASUSER_HASH=8fc19829e144716a422b15a85e718e1816fe561de379b2b5ae87ef9
source "$(dirname "$0")/common.sh"
# Backup: https://web.archive.org/web/20171008011417/http://nsis.sourceforge.net/mediawiki/images/c/c7/ShellExecAsUser.zip
download_file http://nsis.sourceforge.net/mediawiki/images/c/c7/ShellExecAsUser.zip
if ! check_sha256 "$NSISSHELLEXECASUSER_HASH" ShellExecAsUser.zip; then

View File

@ -18,6 +18,7 @@
set -euo pipefail
OPUS_VERSION=1.3.1
# https://archive.mozilla.org/pub/opus/SHA256SUMS.txt
OPUS_HASH=65b58e1e25b2a114157014736a3d9dfeaad8d41be1c8179866f144a2fb44ff9d
source "$(dirname "$0")"/common.sh

View File

@ -1,3 +1,6 @@
Fix VPX not supporting creation of dll
Modified version of https://aur.archlinux.org/cgit/aur.git/tree/configure.patch?h=mingw-w64-libvpx&id=6d658aa0f4d8409fcbd0f20be2c0adcf1e81a297
diff -ruN libvpx/build/make/configure.sh patched/build/make/configure.sh
--- libvpx/build/make/configure.sh 2019-02-13 16:56:48.972857636 +0100
+++ patched/build/make/configure.sh 2019-02-13 16:50:37.995967583 +0100

View File

@ -30,11 +30,13 @@
set -euo pipefail
RUN_TESTS=0
while (( $# > 0 )); do
case $1 in
--src-dir) QTOX_SRC_DIR=$2; shift 2 ;;
--arch) ARCH=$2; shift 2 ;;
--run-tests) RUN_TESTS=1; shift ;;
--build-type) BUILD_TYPE=$2; shift 2;;
*) "Unexpected argument $1"; exit 1 ;;
esac
@ -86,6 +88,7 @@ then
-DDESKTOP_NOTIFICATIONS=ON \
-DUPDATE_CHECK=ON \
-DSTRICT_OPTIONS=ON \
-DTEST_CROSSCOMPILING_EMULATOR=wine \
"$QTOX_SRC_DIR"
elif [[ "$BUILD_TYPE" == "debug" ]]
then
@ -96,6 +99,7 @@ then
-DDESKTOP_NOTIFICATIONS=ON \
-DUPDATE_CHECK=ON \
-DSTRICT_OPTIONS=ON \
-DTEST_CROSSCOMPILING_EMULATOR=wine \
"$QTOX_SRC_DIR"
fi
@ -105,9 +109,9 @@ mkdir -p "${QTOX_PREFIX_DIR}"
cp qtox.exe $QTOX_PREFIX_DIR
cp -r /export/* $QTOX_PREFIX_DIR
# Run tests (only on Travis)
# Run tests
set +u
if [[ -n "$TRAVIS_CI_STAGE" ]]
if [[ $RUN_TESTS -ne 0 ]]
then
export WINEPATH='/export;/windows/bin'
export CTEST_OUTPUT_ON_FAILURE=1