builder: mingw 32 bit updates.
Fix cross building glib with meson for 32 bit Windows, set cpu_family correctly in the cross file. Do not build ffmpeg for 32 bit Windows because it is not compatible with Windows XP and it's better to have a smaller 32 bit binary. Turn off LTO for 32 bit Windows because it is now broken too, in a different way than for 64 bit Windows. Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
parent
b57bd76e3a
commit
17d2fbc5cc
|
@ -210,7 +210,6 @@ DISTS=$DISTS'
|
|||
ffmpeg https://ffmpeg.org/releases/ffmpeg-4.2.1.tar.bz2 lib/libavformat.a
|
||||
'
|
||||
|
||||
# for now we don't build ffmpeg because game recording is broken
|
||||
BUILD_FFMPEG=1
|
||||
|
||||
FFMPEG_DISTS='
|
||||
|
@ -479,6 +478,9 @@ pre_build_all() {
|
|||
setup() {
|
||||
detect_os
|
||||
|
||||
target_os=${CROSS_OS:-$os}
|
||||
target_bits=${target_bits:-$bits}
|
||||
|
||||
mkdir -p "$BUILD_ROOT/tmp"
|
||||
|
||||
rm -rf "$BUILD_ROOT/tmp/"*
|
||||
|
@ -506,6 +508,12 @@ setup() {
|
|||
|
||||
cd "$OPWD"
|
||||
|
||||
# Don't use ffmpeg for 32 bit windows builds for XP compat and to make the
|
||||
# binary smaller.
|
||||
if [ "$target_os" = windows ] && [ "$target_bits" -eq 32 ]; then
|
||||
BUILD_FFMPEG=
|
||||
fi
|
||||
|
||||
if [ -z "$BUILD_FFMPEG" ]; then
|
||||
for dist in $FFMPEG_DISTS; do
|
||||
table_line_remove DISTS $dist
|
||||
|
@ -2636,9 +2644,6 @@ die() {
|
|||
build_project() {
|
||||
puts "${NL}[32mBuilding project: [1;34m$CHECKOUT[0m${NL}${NL}"
|
||||
|
||||
target_os=${CROSS_OS:-$os}
|
||||
target_bits=${target_bits:-$bits}
|
||||
|
||||
dist_pre_build project
|
||||
|
||||
mkdir -p "$BUILD_ROOT/project"
|
||||
|
@ -2648,8 +2653,8 @@ build_project() {
|
|||
|
||||
lto=ON
|
||||
|
||||
# FIXME: LTO still broken on 64 bit mingw
|
||||
if [ "$target_os" = windows ] && [ "$target_bits" = 64 ]; then
|
||||
# FIXME: LTO still broken on 64 bit mingw, and now 32 bit mingw too
|
||||
if [ "$target_os" = windows ]; then
|
||||
lto=OFF
|
||||
fi
|
||||
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
set -e
|
||||
|
||||
target_bits=64
|
||||
target_cpu_family=x86_64
|
||||
target_cpu=x86_64
|
||||
lib_suffix=64
|
||||
target_endian=little
|
||||
|
@ -13,6 +14,7 @@ case "$1" in
|
|||
;;
|
||||
-32)
|
||||
target_bits=32
|
||||
target_cpu_family=x86
|
||||
target_cpu=i686
|
||||
lib_suffix=
|
||||
shift
|
||||
|
@ -71,7 +73,7 @@ meson() {
|
|||
cat >$BUILD_ROOT/tmp/meson_cross_$$.txt <<EOF
|
||||
[host_machine]
|
||||
system = 'windows'
|
||||
cpu_family = '$target_cpu'
|
||||
cpu_family = '$target_cpu_family'
|
||||
cpu = '$target_cpu'
|
||||
endian = '$target_endian'
|
||||
|
||||
|
|
Loading…
Reference in New Issue