diff options
author | Seungha Yang <seungha@centricular.com> | 2020-06-08 21:55:15 +0900 |
---|---|---|
committer | Nirbheek Chauhan <nirbheek@centricular.com> | 2020-10-10 10:55:14 +0530 |
commit | 0175ea5ac70df1818cc085ffe7cce8287e84d62b (patch) | |
tree | 5c90bfaf675bea953ee8665decc04741115d6694 | |
parent | dd1c6867e7571061b1a11ae55eef8e24671ee3eb (diff) |
meson: Ensure large file support for MinGW build
Applying upstream PR to fix missing large file support on Windows MinGW build
Backported-by: Nirbheek Chauhan <nirbheek@centricular.com>
Part-of: <https://gitlab.freedesktop.org/gstreamer/cerbero/-/merge_requests/635>
-rw-r--r-- | recipes/build-tools/meson.recipe | 2 | ||||
-rw-r--r-- | recipes/build-tools/meson/0001-compilers-Add-UNIX-large-file-support-for-MinGW.patch | 30 |
2 files changed, 32 insertions, 0 deletions
diff --git a/recipes/build-tools/meson.recipe b/recipes/build-tools/meson.recipe index 2a691bcc..0e103547 100644 --- a/recipes/build-tools/meson.recipe +++ b/recipes/build-tools/meson.recipe @@ -31,6 +31,8 @@ class Recipe(recipe.Recipe): 'meson/0001-vs-Write-out-checksums.patch', # https://github.com/mesonbuild/meson/pull/6459, in 0.53.1 'meson/0001-find_program-Ignore-programs-in-the-WindowsApps-dire.patch', + # https://github.com/mesonbuild/meson/pull/7272, in 0.55 + 'meson/0001-compilers-Add-UNIX-large-file-support-for-MinGW.patch', ] deps = ['ninja'] diff --git a/recipes/build-tools/meson/0001-compilers-Add-UNIX-large-file-support-for-MinGW.patch b/recipes/build-tools/meson/0001-compilers-Add-UNIX-large-file-support-for-MinGW.patch new file mode 100644 index 00000000..cbc42a46 --- /dev/null +++ b/recipes/build-tools/meson/0001-compilers-Add-UNIX-large-file-support-for-MinGW.patch @@ -0,0 +1,30 @@ +From bf57c43a68fa23ae0ec9e27e201e68a70a19e5d1 Mon Sep 17 00:00:00 2001 +From: Seungha Yang <seungha@centricular.com> +Date: Mon, 8 Jun 2020 21:24:54 +0900 +Subject: [PATCH] compilers: Add UNIX large file support for MinGW + +MinGW gcc supports _FILE_OFFSET_BITS=64 and we need to set it for +MinGW as well + +Backported-by: Nirbheek Chauhan <nirbheek@centricular.com> +--- + mesonbuild/compilers/compilers.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mesonbuild/compilers/compilers.py b/mesonbuild/compilers/compilers.py +index e27ae2b3b..51c85885f 100644 +--- a/mesonbuild/compilers/compilers.py ++++ b/mesonbuild/compilers/compilers.py +@@ -1368,7 +1368,8 @@ def get_largefile_args(compiler): + ''' + Enable transparent large-file-support for 32-bit UNIX systems + ''' +- if get_compiler_is_linuxlike(compiler): ++ ctype = getattr(compiler, 'compiler_type', '') ++ if get_compiler_is_linuxlike(compiler) or (ctype and ctype.name.endswith('MINGW')): + # Enable large-file support unconditionally on all platforms other + # than macOS and Windows. macOS is now 64-bit-only so it doesn't + # need anything special, and Windows doesn't have automatic LFS. +-- +2.26.2 + |