The decompretion of tar.gz is changed to gzip -d -c -- foo.tar.gz but pigz does not support --. So the extraction is broken with portage when set USE="symlink".
I would say, it is pigz which needs to be fixed instead of using dirty workarounds in portage...
I've emailed the author about this with a patch that works-for-me (tm). Should we open another bug to have pigz -r1'd for now or wait for upstream to release a new version?
(In reply to comment #2) > I've emailed the author about this with a patch that works-for-me (tm). > > Should we open another bug to have pigz -r1'd for now or wait for upstream to > release a new version? > Please attach the patch here.
Created attachment 245951 [details, diff] Patch to stop option handling after --
Thanks for reporting. Applied the patch to pigz-2.1.6-r1. Since portage is masked I consider this bug fixed even though the fix is only in testing. Note that I've contacted upstream about this issue back in April (see bug 312967) and the reply was that this is already fixed and will be included in the next version.
(1) If no problems were discovered with the patch so far, I suggest stabilizing 2.1.6-r1, because otherwise zgrep and zless are broken (they supply -- to gzip). (2) "-c" option doesn't ignore non-gz suffix. So I suggest extending the patch to handle that (because upstream appears rather slow), because "-c" requiring gz suffix breaks update-pciids (sys-apps/pciutils), which invokes gzip -cdfq -- /usr/share/misc/pci.ids.gz.neww via zgrep. See /bin/zcat (just runs gzip -cd) and info about zcat in gzip manual: "zcat will uncompress files that have the correct magic number whether they have a .gz suffix or not." Same is apparently true for zgrep / zless.
Both the original issue and the -cdf one were fixed upstream in the official git repository, see http://github.com/madler/pigz/commits/master for commits bb6cfb9362a670c14549 and d52e2aa69c1cf5da28d5.
That's great, but in the meanwhile, a stable Gentoo system can have non-working zgrep, which fails silently in all kinds of scripts. I think this is serious.
Sure this is serious, but I don't quite seem to get your point. Is is that those two patches should be cherry-picked/backported for inclusion in an -r2 or that the current git status should be put into an ebuild? Dror, what's your perspective on this? Imho, both are viable options before more users get affected by this bug.