[Python-checkins] cpython (merge 3.4 -> 3.5): Issue #23652: Merge with 3.4

zach.ware python-checkins at python.org
Sun Aug 2 04:39:55 CEST 2015


https://hg.python.org/cpython/rev/a99f17c752d8
changeset:   97195:a99f17c752d8
branch:      3.5
parent:      97190:bf14b74d6fc0
parent:      97194:c18a18b65a49
user:        Zachary Ware <zachary.ware at gmail.com>
date:        Sat Aug 01 21:38:04 2015 -0500
summary:
  Issue #23652: Merge with 3.4

files:
  Misc/NEWS              |   4 ++++
  Modules/selectmodule.c |  11 +++++++++++
  2 files changed, 15 insertions(+), 0 deletions(-)


diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -13,6 +13,10 @@
 Library
 -------
 
+- Issue #23652: Make it possible to compile the select module against the
+  libc headers from the Linux Standard Base, which do not include some
+  EPOLL macros.  Patch by Matt Frank.
+
 - Issue #22932: Fix timezones in email.utils.formatdate.
   Patch from Dmitry Shachnev.
 
diff --git a/Modules/selectmodule.c b/Modules/selectmodule.c
--- a/Modules/selectmodule.c
+++ b/Modules/selectmodule.c
@@ -2479,11 +2479,22 @@
     PyModule_AddIntMacro(m, EPOLLONESHOT);
 #endif
     /* PyModule_AddIntConstant(m, "EPOLL_RDHUP", EPOLLRDHUP); */
+
+#ifdef EPOLLRDNORM
     PyModule_AddIntMacro(m, EPOLLRDNORM);
+#endif
+#ifdef EPOLLRDBAND
     PyModule_AddIntMacro(m, EPOLLRDBAND);
+#endif
+#ifdef EPOLLWRNORM
     PyModule_AddIntMacro(m, EPOLLWRNORM);
+#endif
+#ifdef EPOLLWRBAND
     PyModule_AddIntMacro(m, EPOLLWRBAND);
+#endif
+#ifdef EPOLLMSG
     PyModule_AddIntMacro(m, EPOLLMSG);
+#endif
 
 #ifdef EPOLL_CLOEXEC
     PyModule_AddIntMacro(m, EPOLL_CLOEXEC);

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list