pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc Always extract the full Python distfile for modules.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/2a95246e0282
branches:  trunk
changeset: 347159:2a95246e0282
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Wed Jan 08 13:44:41 2020 +0000

description:
Always extract the full Python distfile for modules.

This retires an old "optimisation" that over time has created more
problems than it solved, including various questions from users about
the ignored patch failures.

diffstat:

 databases/py-gdbm/Makefile        |  13 +------------
 databases/py-sqlite3/Makefile     |  13 +------------
 devel/py-curses/Makefile          |  11 +----------
 devel/py-cursespanel/Makefile     |  10 +---------
 devel/py-idle/Makefile            |  10 +---------
 devel/py-readline/Makefile        |  11 +----------
 lang/python/srcdist.mk            |   8 ++------
 textproc/py-cElementTree/Makefile |  12 +-----------
 textproc/py-expat/Makefile        |   8 +-------
 x11/py-Tk/Makefile                |  15 +--------------
 10 files changed, 11 insertions(+), 100 deletions(-)

diffs (truncated from 317 to 300 lines):

diff -r f357f15c1675 -r 2a95246e0282 databases/py-gdbm/Makefile
--- a/databases/py-gdbm/Makefile        Wed Jan 08 13:42:05 2020 +0000
+++ b/databases/py-gdbm/Makefile        Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.40 2019/12/15 14:42:27 adam Exp $
+# $NetBSD: Makefile,v 1.41 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-gdbm-${PY_DISTVERSION}
 PKGREVISION=   1
@@ -8,8 +8,6 @@
 HOMEPAGE=      https://docs.python.org/3/library/dbm.html#module-dbm.gnu
 COMMENT=       Python interface to gdbm - GNU database manager
 
-USE_TOOLS+=    patch
-
 .include "../../lang/python/pyversion.mk"
 .if !empty(PYPKGPREFIX:Mpy3?)
 GDBM_MODNAME=  _gdbm
@@ -17,7 +15,6 @@
 GDBM_MODNAME=  gdbm
 .endif
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/${GDBM_MODNAME}module.c
 PYDISTUTILSPKG=                yes
 
 PY_SETUP_SUBST+=       GDBMPREFIX=${BUILDLINK_PREFIX.gdbm}
@@ -25,14 +22,6 @@
 PLIST_SUBST+=          GDBM_MODNAME=${GDBM_MODNAME}
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       set -e;                                                         \
-       cd ${WRKSRC};                                                   \
-       for f in ${PATCHDIR}/patch-*; do                                \
-               ${PATCH} --batch < "$$f" || ${TRUE};                    \
-       done
-
 .include "../../databases/gdbm/buildlink3.mk"
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
diff -r f357f15c1675 -r 2a95246e0282 databases/py-sqlite3/Makefile
--- a/databases/py-sqlite3/Makefile     Wed Jan 08 13:42:05 2020 +0000
+++ b/databases/py-sqlite3/Makefile     Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.35 2019/11/02 15:38:10 rillig Exp $
+# $NetBSD: Makefile,v 1.36 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-sqlite3-${PY_DISTVERSION}
 PKGREVISION=   15
@@ -9,23 +9,12 @@
 COMMENT=       Built-in sqlite support for Python 2.5 and up
 
 USE_GCC_RUNTIME=       yes
-USE_TOOLS+=            patch
-
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/_sqlite
 
 # part of python itself; using distutils.mk will install a useless egg
 PYDISTUTILSPKG=                yes
 PY_SETUP_SUBST+=       SQLITE_PREFIX=${BUILDLINK_PREFIX.sqlite3}
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       set -e;                                                         \
-       cd ${WRKSRC};                                                   \
-       for f in ${PATCHDIR}/patch-*; do                                \
-               ${PATCH} --batch < "$$f" || ${TRUE};                    \
-       done
-
 .include "../../databases/sqlite3/buildlink3.mk"
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
diff -r f357f15c1675 -r 2a95246e0282 devel/py-curses/Makefile
--- a/devel/py-curses/Makefile  Wed Jan 08 13:42:05 2020 +0000
+++ b/devel/py-curses/Makefile  Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.50 2019/12/15 14:42:27 adam Exp $
+# $NetBSD: Makefile,v 1.51 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-curses-${PY_DISTVERSION}
 PKGREVISION=   5
@@ -8,7 +8,6 @@
 #HOMEPAGE=     https://www.python.org/doc/current/lib/module-curses.html
 COMMENT=       Curses module for Python
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/_cursesmodule.c
 PYDISTUTILSPKG=                yes
 PY_PATCHPLIST=         yes
 
@@ -20,14 +19,6 @@
 PY_SETUP_SUBST=                NCURSESPREFIX=${BUILDLINK_PREFIX.ncurses}
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       set -e;                                                         \
-       cd ${WRKSRC};                                                   \
-       for f in ${PATCHDIR}/patch-*; do                                \
-               ${PATCH} --batch < "$$f" || ${TRUE};                    \
-       done
-
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
 .include "../../mk/curses.buildlink3.mk"
diff -r f357f15c1675 -r 2a95246e0282 devel/py-cursespanel/Makefile
--- a/devel/py-cursespanel/Makefile     Wed Jan 08 13:42:05 2020 +0000
+++ b/devel/py-cursespanel/Makefile     Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.33 2019/12/15 14:42:27 adam Exp $
+# $NetBSD: Makefile,v 1.34 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-cursespanel-${PY_DISTVERSION}
 PKGREVISION=   4
@@ -13,19 +13,11 @@
 USE_CURSES=    getsyx
 FAKE_NCURSES=  yes
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/_curses_panel.c
 PYDISTUTILSPKG=                yes
 
 PY_SETUP_SUBST=                NCURSESPREFIX=${BUILDLINK_PREFIX.ncurses}
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       (cd ${WRKSRC}; \
-       for f in ${PATCHDIR}/patch-*;do \
-       ${PATCH} --batch <$$f || ${TRUE}; \
-       done)
-
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
 .include "../../mk/curses.buildlink3.mk"
diff -r f357f15c1675 -r 2a95246e0282 devel/py-idle/Makefile
--- a/devel/py-idle/Makefile    Wed Jan 08 13:42:05 2020 +0000
+++ b/devel/py-idle/Makefile    Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.38 2019/11/03 10:18:28 rillig Exp $
+# $NetBSD: Makefile,v 1.39 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-idle-${PY_DISTVERSION}
 CATEGORIES=    devel python
@@ -11,13 +11,6 @@
 
 PY_PATCHPLIST= yes
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       (cd ${WRKSRC}; \
-       for f in ${PATCHDIR}/patch-*;do \
-       ${PATCH} --batch <$$f || ${TRUE}; \
-       done)
-
 #
 # With Python-2.3 and up, the Idle code is part of the base library.
 # We just install a wrapper script. Also, threads are required now.
@@ -31,7 +24,6 @@
 IDLE_NAME=     idle
 .endif
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Tools/scripts/${IDLE_NAME}
 REPLACE_PYTHON=                Tools/scripts/${IDLE_NAME}
 NO_BUILD=              yes
 INSTALLATION_DIRS=     bin
diff -r f357f15c1675 -r 2a95246e0282 devel/py-readline/Makefile
--- a/devel/py-readline/Makefile        Wed Jan 08 13:42:05 2020 +0000
+++ b/devel/py-readline/Makefile        Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.34 2019/12/15 14:42:26 adam Exp $
+# $NetBSD: Makefile,v 1.35 2020/01/08 13:44:41 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-readline-${PY_DISTVERSION}
 CATEGORIES=    devel misc python
@@ -7,8 +7,6 @@
 HOMEPAGE=      https://docs.python.org/3/library/readline.html
 COMMENT=       Line editing support for Python
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/readline.c
-
 USE_GCC_RUNTIME=       yes
 
 PYDISTUTILSPKG=                yes
@@ -16,13 +14,6 @@
 PY_SETUP_SUBST+=       RLRTPREFIX=${BUILDLINK_PREFIX.readline}
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       (cd ${WRKSRC}; \
-       for f in ${PATCHDIR}/patch-*;do \
-       ${PATCH} --batch <$$f || ${TRUE}; \
-       done)
-
 .include "../../devel/readline/buildlink3.mk"
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
diff -r f357f15c1675 -r 2a95246e0282 lang/python/srcdist.mk
--- a/lang/python/srcdist.mk    Wed Jan 08 13:42:05 2020 +0000
+++ b/lang/python/srcdist.mk    Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: srcdist.mk,v 1.39 2019/12/15 14:42:26 adam Exp $
+# $NetBSD: srcdist.mk,v 1.40 2020/01/08 13:44:41 joerg Exp $
 
 .include "../../lang/python/pyversion.mk"
 
@@ -11,10 +11,6 @@
 # This is used for standard modules shipped with Python but build as
 # separate packages.
 
-.  if ${_PYTHON_VERSION} != 27
-EXTRACT_ELEMENTS+=     ${PYSUBDIR}/Modules/clinic
-.  endif
-
 # Standard modules depend on their own version
 BUILDLINK_API_DEPENDS.${PYPACKAGE}+=   ${PYPACKAGE}>=${PY_DISTVERSION}
 BUILDLINK_ABI_DEPENDS.${PYPACKAGE}+=   ${PYPACKAGE}>=${PY_DISTVERSION}
@@ -23,5 +19,5 @@
        ${SED} ${PY_SETUP_SUBST:S/=/@!/:S/$/!g/:S/^/ -e s!@/} \
                <${FILESDIR}/setup.py >${WRKSRC}/setup.py
 
-post-extract: python-std-patchsetup
+post-patch: python-std-patchsetup
 .endif
diff -r f357f15c1675 -r 2a95246e0282 textproc/py-cElementTree/Makefile
--- a/textproc/py-cElementTree/Makefile Wed Jan 08 13:42:05 2020 +0000
+++ b/textproc/py-cElementTree/Makefile Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.16 2020/01/03 08:03:59 adam Exp $
+# $NetBSD: Makefile,v 1.17 2020/01/08 13:44:42 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-cElementTree-${PY_DISTVERSION}
 CATEGORIES=    textproc python
@@ -7,10 +7,7 @@
 HOMEPAGE=      http://www.effbot.org/zone/celementtree.htm
 COMMENT=       C implementation of Python ElementTree API
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/_elementtree.c
-
 USE_GCC_RUNTIME=       yes
-USE_TOOLS+=            patch
 
 PYDISTUTILSPKG=                yes
 PY_SETUP_SUBST+=       EXPATPREFIX=${BUILDLINK_DIR}
@@ -18,13 +15,6 @@
 
 PYSETUPINSTALLARGS+=   --install-lib ${PREFIX}/${PYLIB}/lib-dynload
 
-# ignore errors due to missing files (EXTRACT_ELEMENTS!)
-do-patch:
-       (cd ${WRKSRC}; \
-       for f in ${PATCHDIR}/patch-*;do \
-       ${PATCH} --batch <$$f || ${TRUE}; \
-       done)
-
 .include "../../textproc/expat/buildlink3.mk"
 .include "../../lang/python/extension.mk"
 .include "../../lang/python/srcdist.mk"
diff -r f357f15c1675 -r 2a95246e0282 textproc/py-expat/Makefile
--- a/textproc/py-expat/Makefile        Wed Jan 08 13:42:05 2020 +0000
+++ b/textproc/py-expat/Makefile        Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.29 2019/11/04 21:43:45 rillig Exp $
+# $NetBSD: Makefile,v 1.30 2020/01/08 13:44:42 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-expat-${PY_DISTVERSION}
 CATEGORIES=    textproc python
@@ -7,12 +7,6 @@
 HOMEPAGE=      https://www.python.org/
 COMMENT=       Python interface to expat
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/pyexpat.c
-.include "../../lang/python/pyversion.mk"
-.if ${_PYTHON_VERSION} != 27
-EXTRACT_ELEMENTS+=     ${PYSUBDIR}/Modules/clinic/pyexpat.c.h
-.endif
-
 USE_GCC_RUNTIME=       yes
 
 PYDISTUTILSPKG=                yes
diff -r f357f15c1675 -r 2a95246e0282 x11/py-Tk/Makefile
--- a/x11/py-Tk/Makefile        Wed Jan 08 13:42:05 2020 +0000
+++ b/x11/py-Tk/Makefile        Wed Jan 08 13:44:41 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.69 2020/01/03 06:24:42 adam Exp $
+# $NetBSD: Makefile,v 1.70 2020/01/08 13:44:42 joerg Exp $
 
 PKGNAME=       ${PYPKGPREFIX}-Tk-${PY_DISTVERSION}
 PKGREVISION=   5
@@ -11,8 +11,6 @@
 
 USE_GCC_RUNTIME=       yes
 
-EXTRACT_ELEMENTS=      ${PYSUBDIR}/Modules/_tkinter.c \
-                       ${PYSUBDIR}/Modules/tkappinit.c
 PYDISTUTILSPKG=                yes
 PY_SETUP_SUBST+=       BLPREFIX=${LOCALBASE}
 PY_SETUP_SUBST+=       TCLRTPREFIX=${BUILDLINK_PREFIX.tcl}
@@ -30,17 +28,6 @@



Home | Main Index | Thread Index | Old Index