mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-24 19:22:11 +01:00
Merge branch 'fix/android-system-checks' into 'master'
build: Fix Android system checks See merge request GNOME/glib!1856
This commit is contained in:
commit
609d1e292f
@ -12,7 +12,7 @@ gnetworking_h_conf = configuration_data()
|
||||
|
||||
gnetworking_h_nameser_compat_include = ''
|
||||
|
||||
if host_system != 'windows' and not host_system.contains('android')
|
||||
if host_system not in ['windows', 'android']
|
||||
# Don't check for C_IN on Android since it does not define it in public
|
||||
# headers, we define it ourselves wherever necessary
|
||||
if not cc.compiles('''#include <sys/types.h>
|
||||
@ -148,7 +148,7 @@ if host_system != 'windows'
|
||||
|
||||
endif
|
||||
|
||||
if host_system.contains('android')
|
||||
if host_system == 'android'
|
||||
# struct ip_mreq_source definition is broken on Android NDK <= r16
|
||||
# See https://bugzilla.gnome.org/show_bug.cgi?id=740791
|
||||
if not cc.compiles('''#include <netinet/in.h>
|
||||
|
@ -34,7 +34,7 @@ if not meson.is_cross_build() or meson.has_exe_wrapper()
|
||||
name : 'printf supports the \'F\' directive')
|
||||
gl_cv_func_printf_directive_f = run_result.compiled() and run_result.returncode() == 0
|
||||
else
|
||||
if host_system == 'linux'
|
||||
if host_system in ['linux', 'android']
|
||||
gl_cv_func_printf_directive_f = true
|
||||
elif (host_system.startswith ('freebsd1') or
|
||||
host_system.startswith ('freebsd2') or
|
||||
|
@ -28,7 +28,7 @@ if not meson.is_cross_build() or meson.has_exe_wrapper()
|
||||
name : 'printf supports the zero flag correctly')
|
||||
gl_cv_func_printf_flag_zero = run_result.compiled() and run_result.returncode() == 0
|
||||
else
|
||||
if host_system == 'linux'
|
||||
if host_system in ['linux', 'android']
|
||||
gl_cv_func_printf_flag_zero = true
|
||||
elif host_system.startswith ('beos')
|
||||
gl_cv_func_printf_flag_zero = true
|
||||
|
@ -82,7 +82,7 @@ if not meson.is_cross_build() or meson.has_exe_wrapper()
|
||||
name : 'printf supports infinite \'double\' arguments')
|
||||
gl_cv_func_printf_infinite = run_result.compiled() and run_result.returncode() == 0
|
||||
else
|
||||
if host_system == 'linux'
|
||||
if host_system in ['linux', 'android']
|
||||
gl_cv_func_printf_infinite = true
|
||||
elif (host_system.startswith ('freebsd1') or
|
||||
host_system.startswith ('freebsd2') or
|
||||
|
@ -175,7 +175,7 @@ if gl_cv_func_printf_long_double
|
||||
if host_machine.cpu_family() == 'x86_64'
|
||||
gl_cv_func_printf_infinite_long_double = false
|
||||
else
|
||||
if host_system == 'linux'
|
||||
if host_system in ['linux', 'android']
|
||||
gl_cv_func_printf_infinite_long_double = true
|
||||
elif (host_system.startswith ('freebsd1') or
|
||||
host_system.startswith ('freebsd2') or
|
||||
|
@ -609,7 +609,7 @@ endif
|
||||
# When building for Android-20 and earlier, require Meson 0.54.2 or newer.
|
||||
# This is needed, because Meson build versions prior to 0.54.2 return false
|
||||
# positive for stpcpy has_function check when building for legacy Android.
|
||||
if host_system.startswith('android-')
|
||||
if host_system == 'android'
|
||||
android_is_older = cc.compiles('''#if __ANDROID_API__ >= 21
|
||||
#error Android is 21 or newer
|
||||
#endif''')
|
||||
|
Loading…
x
Reference in New Issue
Block a user