Skip to content

Commit 9288ed5

Browse files
titoopacam
authored andcommitted
fix missing gethostbyname_r on Android 5.1 (https://bugs.python.org/issue26857)
1 parent 10351c2 commit 9288ed5

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

pythonforandroid/recipes/python2/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ class Python2Recipe(GuestPythonRecipe):
2929
# is_api_lt(21)), # Todo: this should be tested
3030
'patches/fix-missing-extensions.patch',
3131
'patches/fix-filesystem-default-encoding.patch',
32+
'patches/fix-gethostbyaddr.patch',
3233
'patches/fix-posix-declarations.patch',
3334
'patches/fix-pwd-gecos.patch']
3435

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
--- Python-2.7.15/Modules/socketmodule.c.orig 2017-12-29 01:40:09.915694810 +0100
2+
+++ Python-2.7.15/Modules/socketmodule.c 2017-12-29 01:40:36.967694486 +0100
3+
@@ -156,6 +156,9 @@
4+
On the other hand, not all Linux versions agree, so there the settings
5+
computed by the configure script are needed! */
6+
7+
+/* Android hack, same reason are what is described above */
8+
+#undef HAVE_GETHOSTBYNAME_R
9+
+
10+
#ifndef linux
11+
# undef HAVE_GETHOSTBYNAME_R_3_ARG
12+
# undef HAVE_GETHOSTBYNAME_R_5_ARG

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy