quickpkg: Fix incorrect BINPKG_COMPRESS_FLAGS split.
Bug: https://bugs.gentoo.org/857933
Signed-off-by: Sheng Yu <syu.os@protonmail.com>
Closes: https://github.com/gentoo/portage/pull/857
Signed-off-by: Sam James <sam@gentoo.org>
diff --git a/NEWS b/NEWS
index 129416f..6345314 100644
--- a/NEWS
+++ b/NEWS
@@ -16,6 +16,8 @@
started to show on every emerge, but is harmless and left over
from many years ago). Bug #858407.
+* quickpkg: Fix quoting/splitting of BINPKG_COMPRESS_FLAGS arguments. Bug #857933.
+
* estrip: fix double prefix (regression from "don't call estrip twice" fix
in 3.0.31). Bug #858818.
diff --git a/bin/quickpkg b/bin/quickpkg
index b4ad433..773c1c0 100755
--- a/bin/quickpkg
+++ b/bin/quickpkg
@@ -167,10 +167,7 @@
% (binpkg_compression, missing_package)
)
return 1
- cmd = [
- varexpand(x, mydict=settings)
- for x in shlex_split(compression["compress"])
- ]
+ cmd = shlex_split(varexpand(compression["compress"], mydict=settings))
# Filter empty elements that make Popen fail
cmd = [x for x in cmd if x != ""]
with open(binpkg_tmpfile, "wb") as fobj: