From 9eb47b5d0600cb114098e2044bf9fe70f0fc4b0d Mon Sep 17 00:00:00 2001 From: Major Hayden Date: Thu, 27 May 2021 18:42:37 +0000 Subject: [PATCH] Write warning to >&2 instead of /dev/stderr Writing to /dev/stderr with > or >> does not work properly in a mock chroot. https://bugzilla.redhat.com/show_bug.cgi?id=1965470 Related: rhbz#1950291 --- macros.pyproject | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/macros.pyproject b/macros.pyproject index 70f2aeb..6a54fb8 100644 --- a/macros.pyproject +++ b/macros.pyproject @@ -54,7 +54,7 @@ for site_dir in ${site_dirs[@]}; do done lines=$(wc -l %{pyproject_ghost_distinfo} | cut -f1 -d" ") if [ $lines -ne 1 ]; then - echo -e "\\n\\nWARNING: %%%%pyproject_extras_subpkg won't work without explicit -i or -F, found $lines dist-info directories.\\n\\n" >/dev/stderr + echo -e "\\n\\nWARNING: %%%%pyproject_extras_subpkg won't work without explicit -i or -F, found $lines dist-info directories.\\n\\n" >&2 rm %{pyproject_ghost_distinfo} # any attempt to use this will fail fi }