diff options
| author | Junio C Hamano <gitster@pobox.com> | 2025-05-27 13:59:11 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-05-27 13:59:12 -0700 |
| commit | 21b0eb0b6a07f97ca0350729280ea288fc68e6c8 (patch) | |
| tree | 45c2d83be9358d2945c61993fa926f35f357c466 | |
| parent | 80f49f2ae749bce60e79751d1cd0890aca86fca0 (diff) | |
| parent | cddcee7f64263922770bbe5c528ba6af4bf81fb5 (diff) | |
| download | git-21b0eb0b6a07f97ca0350729280ea288fc68e6c8.tar.gz | |
Merge branch 'es/meson-configure-build-options-fix'
Build procedure updates.
* es/meson-configure-build-options-fix:
meson: reformat default options to workaround bug in `meson configure`
| -rw-r--r-- | meson.build | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/meson.build b/meson.build index d938bc8822..596f5ac711 100644 --- a/meson.build +++ b/meson.build @@ -215,14 +215,12 @@ project('git', 'c', capture: true, check: true, ).stdout().strip() : 'unknown', - default_options: [ - # Git requires C99 with GNU extensions, which of course isn't supported by - # MSVC. Funny enough, C99 doesn't work with MSVC either, as it has only - # learned to define __STDC_VERSION__ with C11 and later. We thus require - # GNU C99 and fall back to C11. Meson only learned to handle the fallback - # with version 1.3.0, so on older versions we use GNU C99 unconditionally. - 'c_std=' + (meson.version().version_compare('>=1.3.0') ? 'gnu99,c11' : 'gnu99'), - ], + # Git requires C99 with GNU extensions, which of course isn't supported by + # MSVC. Funny enough, C99 doesn't work with MSVC either, as it has only + # learned to define __STDC_VERSION__ with C11 and later. We thus require + # GNU C99 and fall back to C11. Meson only learned to handle the fallback + # with version 1.3.0, so on older versions we use GNU C99 unconditionally. + default_options: meson.version().version_compare('>=1.3.0') ? ['c_std=gnu99,c11'] : ['c_std=gnu99'], ) fs = import('fs') |
