Date: Thu, 10 Jun 2021 14:48:50 GMT From: Po-Chuan Hsieh <sunpoet@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: 86439d81a884 - main - sysutils/py-scandir: Fix build with Python 3.9+ Message-ID: <202106101448.15AEmoQJ049577@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=86439d81a884725cf6a022e518d9d02f94898d3c commit 86439d81a884725cf6a022e518d9d02f94898d3c Author: Po-Chuan Hsieh <sunpoet@FreeBSD.org> AuthorDate: 2021-06-10 14:30:17 +0000 Commit: Po-Chuan Hsieh <sunpoet@FreeBSD.org> CommitDate: 2021-06-10 14:46:16 +0000 sysutils/py-scandir: Fix build with Python 3.9+ PR: 256272 Reported by: John W. O'Brien <john@saltant.com> --- sysutils/py-scandir/files/patch-_scandir.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/sysutils/py-scandir/files/patch-_scandir.c b/sysutils/py-scandir/files/patch-_scandir.c new file mode 100644 index 000000000000..a0dfd94c9f96 --- /dev/null +++ b/sysutils/py-scandir/files/patch-_scandir.c @@ -0,0 +1,14 @@ +--- _scandir.c.orig 2018-08-02 16:17:16 UTC ++++ _scandir.c +@@ -660,7 +660,11 @@ _pystat_fromstructstat(STRUCT_STAT *st) + return v; + } + ++#if PY_MAJOR_VERSION >= 3 && PY_MINOR_VERSION >= 9 ++const char * const PyStructSequence_UnnamedField = "unnamed field"; ++#else + char *PyStructSequence_UnnamedField = "unnamed field"; ++#endif + + PyDoc_STRVAR(stat_result__doc__, + "stat_result: Result from stat, fstat, or lstat.\n\n\
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202106101448.15AEmoQJ049577>