[WIP] bpo-32654: Fixes for Android API 19#5305
Conversation
* Declare mmap() prototype on API < 21 * Avoid setlocale(LC_ALL, NULL) in Py_Main() on API < 20 * pystrtod.c: avoid localeconv() on API < 21 * _Py_GetLocaleconvNumeric(): avoid localeconv() on API < 20, use hardcoded values.
* _Py_GetLocaleconvNumeric(): use an empty string for thousands_sep and grouping * Fix pystrtod.c: really don't call localeconv() on old Android
|
@yan12125: Would you mind to review and/or test this PR? I'm not sure that we should support Android API 19, see: https://bugs.python.org/issue32654#msg310682 |
Sorry, I may not be able to for now. I don't have a working android-19 device, and I don't think testing on an emulator can give trustworthy results. In my experience there are lots of bugs occur on emulators only. |
The question is not if this PR is enough to fix all API 19 issues, just if it doesn't make things worse :-D |
|
Oh, of course it won't be worse than crash immediately after startup :) I can have a check on emulators, possibly this weekend. |
| fail_pos = NULL; | ||
|
|
||
| locale_data = localeconv(); | ||
| #if defined(__ANDROID_API__) and __ANDROID_API__ < 21 |
hardcoded values.
https://bugs.python.org/issue32654