Fix python (and python2) syslog module

Since the syslog api is a wrapper around the native Android logging
system, we need to link the syslog module against liblog. Fixes #41.
This commit is contained in:
Fredrik Fornwall
2015-11-07 17:44:51 -05:00
parent 6da5daba2f
commit 3152547b65
4 changed files with 28 additions and 8 deletions

View File

@@ -1,6 +1,6 @@
diff -u -r ../Python-2.7.10/setup.py ./setup.py
--- ../Python-2.7.10/setup.py 2015-05-23 12:09:25.000000000 -0400
+++ ./setup.py 2015-09-16 20:36:19.281639713 -0400
+++ ./setup.py 2015-11-07 17:34:53.020310751 -0500
@@ -294,6 +294,9 @@
(ext.name, sys.exc_info()[1]))
self.failed.append(ext.name)
@@ -11,3 +11,13 @@ diff -u -r ../Python-2.7.10/setup.py ./setup.py
# Workaround for Mac OS X: The Carbon-based modules cannot be
# reliably imported into a command-line Python
if 'Carbon' in ext.extra_link_args:
@@ -674,7 +677,8 @@
# Lance Ellinghaus's syslog module
# syslog daemon interface
- exts.append( Extension('syslog', ['syslogmodule.c']) )
+ # Termux: Add 'log' android library since we use android logging:
+ exts.append( Extension('syslog', ['syslogmodule.c'], libraries=['log']) )
# George Neville-Neil's timing module:
# Deprecated in PEP 4 http://www.python.org/peps/pep-0004.html