Ticket #51939: python36-pyport.h.patch

File python36-pyport.h.patch, 2.3 KB (added by Ionic (Mihai Moldovan), 8 years ago)

Patch against python36.

  • lang/python36/Portfile

    From 8e9f399375d75ae6c53fa4acad5f9d971a365755 Mon Sep 17 00:00:00 2001
    From: Mihai Moldovan <ionic@ionic.de>
    Date: Mon, 1 Aug 2016 07:52:00 +0200
    Subject: python36: backport patch from #44288. Part of #51939.
    
    ---
     lang/python36/Portfile                          |  4 +++-
     lang/python36/files/patch-Include-pyport.h.diff | 23 +++++++++++++++++++++++
     2 files changed, 26 insertions(+), 1 deletion(-)
     create mode 100644 lang/python36/files/patch-Include-pyport.h.diff
    
    diff --git a/lang/python36/Portfile b/lang/python36/Portfile
    index c88dac1..862cdbd 100644
    a b name python36 
    88
    99# Remember to keep py35-tkinter and py35-gdbm's versions sync'd with this
    1010version                 3.6.0a3
     11revision                1
    1112
    1213epoch                   20160712
    1314
    patchfiles patch-setup.py.diff \ 
    3940                        patch-setup.py-disabled_modules.diff \
    4041                        patch-Lib-ctypes-macholib-dyld.py.diff \
    4142                        patch-libedit.diff \
    42                         omit-local-site-packages.patch
     43                        omit-local-site-packages.patch \
     44                        patch-Include-pyport.h.diff
    4345
    4446depends_lib             port:zlib path:lib/libssl.dylib:openssl \
    4547                        port:sqlite3 port:ncurses \
  • new file lang/python36/files/patch-Include-pyport.h.diff

    diff --git a/lang/python36/files/patch-Include-pyport.h.diff b/lang/python36/files/patch-Include-pyport.h.diff
    new file mode 100644
    index 0000000..52f0d24
    - +  
     1--- Include/pyport.h.old        2016-07-12 05:11:09.000000000 +0200
     2+++ Include/pyport.h    2016-08-01 07:50:40.000000000 +0200
     3@@ -688,6 +688,12 @@ extern pid_t forkpty(int *, char *, stru
     4 #endif
     5 
     6 #ifdef _PY_PORT_CTYPE_UTF8_ISSUE
     7+#ifndef __cplusplus
     8+   /* The workaround below is unsafe in C++ because
     9+    * the <locale> defines these symbols as real functions,
     10+    * with a slightly different signature.
     11+    * See issue #10910
     12+    */
     13 #include <ctype.h>
     14 #include <wctype.h>
     15 #undef isalnum
     16@@ -705,6 +711,7 @@ extern pid_t forkpty(int *, char *, stru
     17 #undef toupper
     18 #define toupper(c) towupper(btowc(c))
     19 #endif
     20+#endif
     21 
     22 
     23 /* Declarations for symbol visibility.