Created attachment 398610 [details] seabios-1.7.5-r1 logfile sys-firmware/seabios-1.7.5-r1 fails to unpack. I see from the log that it converts seabios_1.7.5-1_all.deb into seabios_1.7.5-1_all.tar.xz. Then it fails because of different extension of the produced file and the required one (.xz is not .gz). May I aske the question? Why do you need to convert .deb into .xz? Isn't easier to do smth like this in the ebuild? src_unpack() { unpack_deb ${A} } src_prepare() { # Do what you want rm, mv, etc. }
FYI to reproduce this you must have non-gnu ar, and must have deb2targz installed. The normal unpack works fine, it's the deb2targz fallback unpack which fails. phase-helpers.sh says: # Unpacking .deb archives can not always be done with # `ar`. For instance on AIX this doesn't work out. # If `ar` is not the GNU binutils version and we have # `deb2targz` installed, prefer it over `ar` for that # reason. We just make sure on AIX `deb2targz` is # installed. ...in case you were wondering how this slipped through the cracks, outright failing @ unpack phase =) Out of curiosity, what does your "ar --version" report? Is this a prefix setup or something?
IDK what ar means. I have app-arch/deb2targz installed for a long time for my personal purposes. The result of "ar --version" command: # ar --version GNU ar (Gentoo 2.24 p1.4) 2.24 Copyright 2013 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License version 3 or (at your option) any later version. This program has absolutely no warranty.
'ar' is an archive tool from binutils which can be used by portage to unpack the .deb file, rather than relying on deb2targz. As I read the unpack function in phase-helpers.sh, it should not even attempt to use deb2targz unless it detects non-GNU ar. The exact test is: if [[ $(ar --version 2>/dev/null) != "GNU ar"* ]] && type -P deb2targz > /dev/null; then ... Somehow this test returns success on your setup, but I don't immediately see why. Then the deb2targz method seems to fall down when the archive inside is .xz rather than .gz
I have just tested under root: # if [[ $(ar --version 2>/dev/null) != "GNU ar"* ]] ; then \ > echo "Inside"; \ > fi The output is empty wich means that it doesn't enter inside this if.
But that's the only place where deb2targz can be called at all, so somehow in the emerge environment it must be passing that test. If you temporarily unmerge deb2targz (or just move /usr/bin/deb2targz out of the way) does seabios emerge successfully?
I now see that this is fixed in portage versions 2.2.16 and later: https://github.com/gentoo/portage/commit/518aedae1b3aa06f796376390118dad89eee31ce
(In reply to Ben Kohler from comment #5) > But that's the only place where deb2targz can be called at all, so somehow > in the emerge environment it must be passing that test. If you temporarily > unmerge deb2targz (or just move /usr/bin/deb2targz out of the way) does > seabios emerge successfully? Yes, it merged after moving /usr/bin/deb2targz to some other place temporarily. Thank you.