diff --git a/spirv_glsl.cpp b/spirv_glsl.cpp index 8f464dcc..af538493 100644 --- a/spirv_glsl.cpp +++ b/spirv_glsl.cpp @@ -172,6 +172,11 @@ void CompilerGLSL::init() const struct lconv *conv = localeconv(); if (conv && conv->decimal_point) current_locale_radix_character = *conv->decimal_point; +#elif defined(__ANDROID__) && __ANDROID_API__ < 26 + // nl_langinfo is not supported on this platform, fall back to the worse alternative. + const struct lconv *conv = localeconv(); + if (conv && conv->decimal_point) + current_locale_radix_character = *conv->decimal_point; #else // localeconv, the portable function is not MT safe ... const char *decimal_point = nl_langinfo(RADIXCHAR);