From cbc30d22d239d55dd2ed6258ea0dd52f9f43ad65a0253f344ad059747a9ebbf7 Mon Sep 17 00:00:00 2001 From: Dominique Leuenberger Date: Mon, 11 May 2020 11:25:42 +0000 Subject: [PATCH] Accepting request 799984 from Base:System - add coreutils-use-python3.patch to minimally port away from python 2.x use of pyinotify in the testsuite OBS-URL: https://build.opensuse.org/request/show/799984 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/coreutils?expand=0&rev=133 --- coreutils-use-python3.patch | 24 ++++++++++++++++++++++++ coreutils.changes | 6 ++++++ coreutils.spec | 8 ++++++-- 3 files changed, 36 insertions(+), 2 deletions(-) create mode 100644 coreutils-use-python3.patch diff --git a/coreutils-use-python3.patch b/coreutils-use-python3.patch new file mode 100644 index 0000000..1cbb22a --- /dev/null +++ b/coreutils-use-python3.patch @@ -0,0 +1,24 @@ +--- tests/du/move-dir-while-traversing.sh ++++ tests/du/move-dir-while-traversing.sh +@@ -20,9 +20,9 @@ + print_ver_ du + require_trap_signame_ + +-# We use a python-inotify script, so... +-python -m pyinotify -h > /dev/null \ +- || skip_ 'python inotify package not installed' ++# We use a python3-inotify script, so... ++python3 -m pyinotify -h > /dev/null \ ++ || skip_ 'python3 inotify package not installed' + + # Move a directory "up" while du is processing its sub-directories. + # While du is processing a hierarchy .../B/C/D/... this script +@@ -33,7 +33,7 @@ + # rename syscall before du finishes processing the subtree under D/. + + cat <<'EOF' > inotify-watch-for-dir-access.py +-#!/usr/bin/env python ++#!/usr/bin/env python3 + import pyinotify as pn + import os,sys + diff --git a/coreutils.changes b/coreutils.changes index 63492aa..7e8b818 100644 --- a/coreutils.changes +++ b/coreutils.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon May 4 08:05:15 UTC 2020 - Dirk Mueller + +- add coreutils-use-python3.patch to minimally port away from + python 2.x use of pyinotify in the testsuite + ------------------------------------------------------------------- Mon Mar 9 07:17:46 UTC 2020 - Bernhard Voelker diff --git a/coreutils.spec b/coreutils.spec index c867060..289628b 100644 --- a/coreutils.spec +++ b/coreutils.spec @@ -54,7 +54,9 @@ BuildRequires: gcc-PIE BuildRequires: acl BuildRequires: gdb BuildRequires: perl-Expect -BuildRequires: python-pyinotify +BuildRequires: python +BuildRequires: python3 +BuildRequires: python3-pyinotify BuildRequires: strace BuildRequires: timezone # Some tests need the 'bin' user. @@ -134,7 +136,8 @@ Patch301: coreutils-skip-gnulib-test-tls.patch # tests: shorten extreme-expensive factor tests Patch303: coreutils-tests-shorten-extreme-factor-tests.patch - +# Stop using Python 2.x +Patch304: coreutils-use-python3.patch Patch500: coreutils-disable_tests.patch Patch501: coreutils-test_without_valgrind.patch @@ -193,6 +196,7 @@ This package contains the documentation for the GNU Core Utilities. %endif %patch303 +%patch304 %patch500 %patch501