Skip to content

Commit 7e882ae

Browse files
dengertJakuje
authored andcommitted
setup-linux.sh - do wine install last
reorder "sudo dpkg --add-architecture i386" till after first update and the actions/runner-images#4589 which removes a number of packages. Then do "sudo dpkg --add-architecture i386" so next update will add all the i386 packages Install any wine packages last. Previous code would fail when called to build-ix86 but work with build-mingw32 and build-mingw All 3 call setup-linux.sh Date: Thu Jan 26 07:59:41 2023 -0600 Changes to be committed: modified: .github/setup-linux.sh
1 parent fe7cc69 commit 7e882ae

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

.github/setup-linux.sh

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
set -ex -o xtrace
44

5+
WINE_DEPS=""
56
# Generic dependencies
67
DEPS="docbook-xsl xsltproc gengetopt help2man pcscd check pcsc-tools libtool make autoconf autoconf-archive automake pkg-config git xxd openssl"
78

89
# 64bit or 32bit dependencies
910
if [ "$1" == "ix86" ]; then
10-
sudo dpkg --add-architecture i386
1111
DEPS="$DEPS gcc-multilib libpcsclite-dev:i386 libcmocka-dev:i386 libssl-dev:i386 zlib1g-dev:i386 libreadline-dev:i386 softhsm2:i386"
1212
else
1313
DEPS="$DEPS libpcsclite-dev libcmocka-dev libssl-dev zlib1g-dev libreadline-dev softhsm2"
@@ -27,27 +27,28 @@ elif [ "$1" == "piv" -o "$1" == "isoapplet" -o "$1" == "gidsapplet" -o "$1" == "
2727
elif [ "$1" == "mingw" -o "$1" == "mingw32" ]; then
2828
# Note, that this list is somehow magic and adding libwine, libwine:i386 or wine64
2929
# will make the following sections break without any useful logs. See GH#2458
30-
DEPS="$DEPS wine wine32 xvfb wget"
31-
sudo dpkg --add-architecture i386
30+
WINE_DEPS="wine wine32 xvfb wget"
3231
if [ "$1" == "mingw" ]; then
33-
DEPS="$DEPS binutils-mingw-w64-x86-64 gcc-mingw-w64-x86-64 mingw-w64"
32+
WINE_DEPS="$WINE_DEPS binutils-mingw-w64-x86-64 gcc-mingw-w64-x86-64 mingw-w64"
3433
elif [ "$1" == "mingw32" ]; then
35-
DEPS="$DEPS binutils-mingw-w64-i686 gcc-mingw-w64-i686"
34+
WINE_DEPS="$WINE_DEPS binutils-mingw-w64-i686 gcc-mingw-w64-i686"
3635
fi
3736
fi
3837

39-
# The Github's Ubuntu images since 20211122.1 are broken
38+
# The Github Ubuntu images since 20211122.1 are broken
4039
# https://github.com/actions/virtual-environments/issues/4589
4140
if [ "$1" == "mingw" -o "$1" == "mingw32" -o "$1" == "ix86" ]; then
4241
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
4342
sudo apt-get update -qq
4443
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
44+
sudo dpkg --add-architecture i386
4545
fi
4646

4747
# make sure we do not get prompts
4848
export DEBIAN_FRONTEND=noninteractive
4949
export DEBCONF_NONINTERACTIVE_SEEN=true
50-
sudo apt-get update
50+
sudo apt-get update -qq
51+
5152
sudo apt-get install -y build-essential $DEPS
5253

5354
# install libressl if needed
@@ -56,6 +57,7 @@ if [ "$1" == "libressl" -o "$2" == "libressl" ]; then
5657
fi
5758

5859
if [ "$1" == "mingw" -o "$1" == "mingw32" ]; then
60+
sudo apt-get install -y $WINE_DEPS
5961
if [ ! -f "$(winepath 'C:/Program Files/Inno Setup 5/ISCC.exe')" ]; then
6062
/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -ac -screen 0 1280x1024x16
6163
export DISPLAY=:99.0

0 commit comments

Comments
 (0)