mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
lang/python{27,33,34,35,36}: Make Python curses module work with Unicode
Use readline from ports (USES= readline:port) and patch setup.py to ignore readline from base. The patch is necessary for FreeBSD < 1100000, as after this the readline library became an INTERNALLIB, see base r268461 [1] Link devel/readline against termcapw instead of termcap is part of this change, see ports r444463 [2] Note that this is the **ports** approach for getting Python curses module working with Unicode. The other way is splitting libncurses into separate libncurses and libtinfo in base, for which an open issue exists [3]. Apart from Python language ports, at least www/rtv and sysutils/py-ranger ports have been tested to work correctly (display Unicode) after this change. [1] https://svnweb.freebsd.org/changeset/base/268461 [2] https://svnweb.freebsd.org/changeset/ports/444463 [3] https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=197317 PR: 171246, 197317 Reported by: Vitaly Magerya <vmagerya gmail com> Reviewed by: garga, koobs, miwi, sunpoet Approved by: garga (mentor), sunpoet (python, with hat) Differential Revision: https://reviews.freebsd.org/D11127
This commit is contained in:
parent
ed163be5e0
commit
a4046066e9
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=444534
5 changed files with 45 additions and 10 deletions
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
PORTNAME= python27
|
PORTNAME= python27
|
||||||
PORTVERSION= ${PYTHON_PORTVERSION}
|
PORTVERSION= ${PYTHON_PORTVERSION}
|
||||||
PORTREVISION= 5
|
PORTREVISION= 6
|
||||||
CATEGORIES= lang python ipv6
|
CATEGORIES= lang python ipv6
|
||||||
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
||||||
DISTNAME= Python-${PORTVERSION}
|
DISTNAME= Python-${PORTVERSION}
|
||||||
|
@ -15,7 +15,7 @@ LICENSE= PSFL
|
||||||
|
|
||||||
BROKEN_SSL= openssl-devel
|
BROKEN_SSL= openssl-devel
|
||||||
|
|
||||||
USES= cpe ncurses pathfix pkgconfig readline ssl tar:xz shebangfix
|
USES= cpe ncurses pathfix pkgconfig readline:port ssl tar:xz shebangfix
|
||||||
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
||||||
USE_LDCONFIG= yes
|
USE_LDCONFIG= yes
|
||||||
GNU_CONFIGURE= yes
|
GNU_CONFIGURE= yes
|
||||||
|
@ -115,6 +115,13 @@ PLIST_SUB+= NO_NIS=""
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
|
# readline shared library is present on base before FreeBSD 11 - r268461
|
||||||
|
# force setup.py ignore base and use readline from ports
|
||||||
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000
|
||||||
|
${REINPLACE_CMD} -e \
|
||||||
|
"s|lib_dirs,\ \'readline\'|[\'${LOCALBASE}/lib\',\ \'.\'],\ \'readline\'|" \
|
||||||
|
${WRKSRC}/setup.py
|
||||||
|
.endif
|
||||||
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
||||||
${WRKSRC}/Lib/cgi.py
|
${WRKSRC}/Lib/cgi.py
|
||||||
@${REINPLACE_CMD} -e \
|
@${REINPLACE_CMD} -e \
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
PORTNAME= python33
|
PORTNAME= python33
|
||||||
PORTVERSION= ${PYTHON_PORTVERSION}
|
PORTVERSION= ${PYTHON_PORTVERSION}
|
||||||
PORTREVISION= 9
|
PORTREVISION= 10
|
||||||
CATEGORIES= lang python ipv6
|
CATEGORIES= lang python ipv6
|
||||||
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
||||||
DISTNAME= Python-${PORTVERSION}
|
DISTNAME= Python-${PORTVERSION}
|
||||||
|
@ -16,7 +16,7 @@ LICENSE= PSFL
|
||||||
DEPRECATED= No longer receives bug fixes, only security updates. Please update to Python 3.6
|
DEPRECATED= No longer receives bug fixes, only security updates. Please update to Python 3.6
|
||||||
EXPIRATION_DATE= 2017-09-01
|
EXPIRATION_DATE= 2017-09-01
|
||||||
|
|
||||||
USES= cpe ncurses pathfix pkgconfig readline ssl tar:xz shebangfix
|
USES= cpe ncurses pathfix pkgconfig readline:port ssl tar:xz shebangfix
|
||||||
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
||||||
USE_LDCONFIG= yes
|
USE_LDCONFIG= yes
|
||||||
GNU_CONFIGURE= yes
|
GNU_CONFIGURE= yes
|
||||||
|
@ -108,6 +108,13 @@ PLIST_SUB+= NO_NIS=""
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
|
# readline shared library is present on base before FreeBSD 11 - r268461
|
||||||
|
# force setup.py ignore base and use readline from ports
|
||||||
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000
|
||||||
|
${REINPLACE_CMD} -e \
|
||||||
|
"s|lib_dirs,\ \'readline\'|[\'${LOCALBASE}/lib\',\ \'.\'],\ \'readline\'|" \
|
||||||
|
${WRKSRC}/setup.py
|
||||||
|
.endif
|
||||||
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
||||||
${WRKSRC}/Lib/cgi.py
|
${WRKSRC}/Lib/cgi.py
|
||||||
.if !exists(/usr/bin/ypcat) || defined(WITHOUT_NIS)
|
.if !exists(/usr/bin/ypcat) || defined(WITHOUT_NIS)
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
PORTNAME= python34
|
PORTNAME= python34
|
||||||
PORTVERSION= ${PYTHON_PORTVERSION}
|
PORTVERSION= ${PYTHON_PORTVERSION}
|
||||||
PORTREVISION= 3
|
PORTREVISION= 4
|
||||||
CATEGORIES= lang python ipv6
|
CATEGORIES= lang python ipv6
|
||||||
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
MASTER_SITES= PYTHON/ftp/python/${PORTVERSION}
|
||||||
DISTNAME= Python-${PORTVERSION}
|
DISTNAME= Python-${PORTVERSION}
|
||||||
|
@ -14,7 +14,7 @@ COMMENT= Interpreted object-oriented programming language
|
||||||
|
|
||||||
LICENSE= PSFL
|
LICENSE= PSFL
|
||||||
|
|
||||||
USES= cpe ncurses pathfix pkgconfig readline ssl tar:xz shebangfix
|
USES= cpe ncurses pathfix pkgconfig readline:port ssl tar:xz shebangfix
|
||||||
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
||||||
USE_LDCONFIG= yes
|
USE_LDCONFIG= yes
|
||||||
GNU_CONFIGURE= yes
|
GNU_CONFIGURE= yes
|
||||||
|
@ -117,6 +117,13 @@ PLIST_SUB+= NO_NIS=""
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
|
# readline shared library is present on base before FreeBSD 11 - r268461
|
||||||
|
# force setup.py ignore base and use readline from ports
|
||||||
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000
|
||||||
|
${REINPLACE_CMD} -e \
|
||||||
|
"s|lib_dirs,\ \'readline\'|[\'${LOCALBASE}/lib\',\ \'.\'],\ \'readline\'|" \
|
||||||
|
${WRKSRC}/setup.py
|
||||||
|
.endif
|
||||||
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
||||||
${WRKSRC}/Lib/cgi.py
|
${WRKSRC}/Lib/cgi.py
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
PORTNAME= python
|
PORTNAME= python
|
||||||
PORTVERSION= ${PYTHON_PORTVERSION}
|
PORTVERSION= ${PYTHON_PORTVERSION}
|
||||||
PORTREVISION= 3
|
PORTREVISION= 4
|
||||||
CATEGORIES= lang python ipv6
|
CATEGORIES= lang python ipv6
|
||||||
MASTER_SITES= PYTHON/ftp/python/${PYTHON_PORTVERSION}
|
MASTER_SITES= PYTHON/ftp/python/${PYTHON_PORTVERSION}
|
||||||
PKGNAMESUFFIX= ${PYTHON_SUFFIX}
|
PKGNAMESUFFIX= ${PYTHON_SUFFIX}
|
||||||
|
@ -17,7 +17,7 @@ LICENSE= PSFL
|
||||||
|
|
||||||
BROKEN_SSL= openssl-devel
|
BROKEN_SSL= openssl-devel
|
||||||
|
|
||||||
USES= cpe ncurses pathfix pkgconfig readline ssl tar:xz shebangfix
|
USES= cpe ncurses pathfix pkgconfig readline:port ssl tar:xz shebangfix
|
||||||
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
||||||
USE_LDCONFIG= yes
|
USE_LDCONFIG= yes
|
||||||
GNU_CONFIGURE= yes
|
GNU_CONFIGURE= yes
|
||||||
|
@ -127,6 +127,13 @@ PLIST_SUB+= NO_NIS=""
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
|
# readline shared library is present on base before FreeBSD 11 - r268461
|
||||||
|
# force setup.py ignore base and use readline from ports
|
||||||
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000
|
||||||
|
${REINPLACE_CMD} -e \
|
||||||
|
"s|lib_dirs,\ \'readline\'|[\'${LOCALBASE}/lib\',\ \'.\'],\ \'readline\'|" \
|
||||||
|
${WRKSRC}/setup.py
|
||||||
|
.endif
|
||||||
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
||||||
${WRKSRC}/Lib/cgi.py
|
${WRKSRC}/Lib/cgi.py
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
PORTNAME= python
|
PORTNAME= python
|
||||||
PORTVERSION= ${PYTHON_PORTVERSION}
|
PORTVERSION= ${PYTHON_PORTVERSION}
|
||||||
PORTREVISION= 3
|
PORTREVISION= 4
|
||||||
CATEGORIES= lang python ipv6
|
CATEGORIES= lang python ipv6
|
||||||
MASTER_SITES= PYTHON/ftp/python/${PYTHON_PORTVERSION}
|
MASTER_SITES= PYTHON/ftp/python/${PYTHON_PORTVERSION}
|
||||||
PKGNAMESUFFIX= ${PYTHON_SUFFIX}
|
PKGNAMESUFFIX= ${PYTHON_SUFFIX}
|
||||||
|
@ -15,7 +15,7 @@ COMMENT= Interpreted object-oriented programming language
|
||||||
|
|
||||||
LICENSE= PSFL
|
LICENSE= PSFL
|
||||||
|
|
||||||
USES= cpe ncurses pathfix pkgconfig readline ssl tar:xz shebangfix
|
USES= cpe ncurses pathfix pkgconfig readline:port ssl tar:xz shebangfix
|
||||||
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
PATHFIX_MAKEFILEIN= Makefile.pre.in
|
||||||
USE_LDCONFIG= yes
|
USE_LDCONFIG= yes
|
||||||
GNU_CONFIGURE= yes
|
GNU_CONFIGURE= yes
|
||||||
|
@ -124,6 +124,13 @@ PLIST_SUB+= NO_NIS=""
|
||||||
.endif
|
.endif
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
|
# readline shared library is present on base before FreeBSD 11 - r268461
|
||||||
|
# force setup.py ignore base and use readline from ports
|
||||||
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000
|
||||||
|
${REINPLACE_CMD} -e \
|
||||||
|
"s|lib_dirs,\ \'readline\'|[\'${LOCALBASE}/lib\',\ \'.\'],\ \'readline\'|" \
|
||||||
|
${WRKSRC}/setup.py
|
||||||
|
.endif
|
||||||
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
${REINPLACE_CMD} -e 's|/usr/local/bin/python|${python_CMD}|' \
|
||||||
${WRKSRC}/Lib/cgi.py
|
${WRKSRC}/Lib/cgi.py
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue