2
0
mirror of https://github.com/FWGS/xash3d-fwgs synced 2024-12-27 11:16:43 +01:00

scripts: gha: use 64-bit compiler for 32-bit target for faster compilation on Win32

This commit is contained in:
Alibek Omarov 2024-08-18 14:04:35 +03:00
parent c84d2f4624
commit 3de370f3d5

View File

@ -5,13 +5,19 @@
# Build engine
cd $BUILDDIR
if [ "$ARCH" = "amd64" ]; then # we need enabling 64-bit target only on Intel-compatible CPUs
AMD64="-8"
if [ "$ARCH" = "i386" ]; then
# use 64-bit compiler crosscompiling for 32-bit for faster compilation
CONFIGURE_FLAGS="--msvc_targets=amd64_x86"
elif [ "$ARCH" = "amd64" ]; then
# we need enabling 64-bit target only on Intel-compatible CPUs
CONFIGURE_FLAGS="-8"
else
die
fi
# NOTE: to build with other version use --msvc_version during configuration
# NOTE: sometimes you may need to add WinSDK to %PATH%
./waf.bat configure -s "SDL2_VC" -T release --enable-utils --enable-tests --enable-lto $AMD64 || die_configure
./waf.bat configure -s "SDL2_VC" -T release --enable-utils --enable-tests --enable-lto $CONFIGURE_FLAGS || die_configure
./waf.bat build || die
./waf.bat install --destdir=. || die