ports/devel/glib2/patches/patch-meson_build

46 lines
1.8 KiB
Text

XXX base gcc
Reordering needed to prefer long long because base-gcc doesn't recognize
#pragma GCC diagnostic error "-Wincompatible-pointer-types"
and doesn't fail to compile the test case (gint64 should be long long).
Index: meson.build
--- meson.build.orig
+++ meson.build
@@ -1443,18 +1443,6 @@ endif
# works.
if long_long_size == long_size
if cc.compiles('''#if defined(_AIX) && !defined(__GNUC__)
- #pragma options langlvl=stdc99
- #endif
- #pragma GCC diagnostic error "-Wincompatible-pointer-types"
- #include <stdint.h>
- #include <stdio.h>
- int main () {
- int64_t i1 = 1;
- long *i2 = &i1;
- return 1;
- }''', name : 'int64_t is long')
- int64_t_typedef = 'long'
- elif cc.compiles('''#if defined(_AIX) && !defined(__GNUC__)
#pragma options langlvl=stdc99
#endif
#pragma GCC diagnostic error "-Wincompatible-pointer-types"
@@ -1466,6 +1454,18 @@ if long_long_size == long_size
return 1;
}''', name : 'int64_t is long long')
int64_t_typedef = 'long long'
+ elif cc.compiles('''#if defined(_AIX) && !defined(__GNUC__)
+ #pragma options langlvl=stdc99
+ #endif
+ #pragma GCC diagnostic error "-Wincompatible-pointer-types"
+ #include <stdint.h>
+ #include <stdio.h>
+ int main () {
+ int64_t i1 = 1;
+ long *i2 = &i1;
+ return 1;
+ }''', name : 'int64_t is long')
+ int64_t_typedef = 'long'
endif
endif