Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 136792 - [PATCH] unpack for non-distdir with absolute path, makeself bin|sh|run support
Summary: [PATCH] unpack for non-distdir with absolute path, makeself bin|sh|run support
Status: RESOLVED WONTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Ebuild Support (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-06-14 08:42 UTC by Stefan Schweizer (RETIRED)
Modified: 2007-02-11 15:15 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
unpack-add-makeself.patch (unpack-add-makeself.patch,3.44 KB, patch)
2006-06-14 08:42 UTC, Stefan Schweizer (RETIRED)
Details | Diff
unpack.patch (unpack.patch,1.99 KB, patch)
2006-06-18 02:10 UTC, Stefan Schweizer (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Schweizer (RETIRED) gentoo-dev 2006-06-14 08:42:03 UTC
Hi,

the initial author of the googleearth ebuild(on CC) inspired me to add support to unpack even files that are not in DISTDIR but have no realtive path. It is simple and backwards-compatible.

second part is unification, ${srcdir}/${x} -> ${srcdir}${x} everywhere.

third part is support for makeself-generated .bin, .sh and .run files. It is majorly copied from eutils.eclass. See
grep "unpack_makeself" /usr/portage/games-*/*/*.ebuild for current useage. I think it should be done in ebuild.sh to allow it to be used more widely.
Does not break any non-Makeself bin|sh|run - it just vecho's there.
It only dies when it has detected a Makeself bin|sh|run and is unable to unpack it.
Comment 1 Stefan Schweizer (RETIRED) gentoo-dev 2006-06-14 08:42:32 UTC
Created attachment 89170 [details, diff]
unpack-add-makeself.patch
Comment 2 Zac Medico gentoo-dev 2006-06-14 10:55:31 UTC
(In reply to comment #0)
> third part is support for makeself-generated .bin, .sh and .run files. It is
> majorly copied from eutils.eclass. See
> grep "unpack_makeself" /usr/portage/games-*/*/*.ebuild for current useage. I
> think it should be done in ebuild.sh to allow it to be used more widely.

I'd rather not include makeself support in ebuild.sh.  What's wrong with using eutils for that?  My inclination is that portage internals should be more minimal,  with support for extensibility via things such as eclasses and profile.bashrcs.
Comment 3 Zac Medico gentoo-dev 2006-06-18 00:18:50 UTC
(In reply to comment #0)
> to unpack even files that are not in DISTDIR but have no realtive path.

Why would you want to unpack a file with an absolute path?
Comment 4 Stefan Schweizer (RETIRED) gentoo-dev 2006-06-18 02:10:33 UTC
Created attachment 89451 [details, diff]
unpack.patch

New patch - uses app-arch/unmakeself, adds rpm support(copied from rpm.eclass), adds TAR support.
Comment 5 Tristan Heaven (RETIRED) gentoo-dev 2006-06-18 12:44:02 UTC
What's the best way to unpack files from an archive, which was one of the files unpacked from an archive in ${A}, into a specific directory?

It would just be nice if there was an easier way than this:

unpack ${A}
cd "${S}"
mkdir data
cd data
unpack ./../data.tar
Comment 6 Marius Mauch (RETIRED) gentoo-dev 2006-06-18 13:28:21 UTC
I'm with Zac on this one, we should rather move the unpack code (together with most of the helpers and some other stuff) into the tree.
Comment 7 SpanKY gentoo-dev 2006-06-18 15:44:33 UTC
yeah, i think rpm and makeself support is good where it is (rpm.eclass / eutils.eclass)

also, unmakeself isnt even in the tree ...
Comment 8 Mike Auty (RETIRED) gentoo-dev 2006-07-08 05:58:57 UTC
I'm very much for the very first part of this patch (the ability to unpack from absolute locations).  The biggest reason for this is for the installation of files from CD locations.  cdrom_get_cds from eutils lets you form an absolute (but not predictable in a relative manner) path to the file to unpack.  It'd be much nicer to do:

unpack ${CD_ROOT}/${TARBALL}

than to do the rather dirty:

cd ${WORKDIR}
cp ${CD_ROOT}/${TARBALL}
unpack "./${TARBALL}"

I realise at the moment there's only about two ebuilds that use the cdrom functions, but for it to make it into eutils, we must've had more in the past, and for all the vmware-*-tools ebuilds (where VM ship it as a "virutal CD" that gets mounted upon request) it'd be nice to have this.

I'd tend to agree that the stuff that's already in eutils is probably best kept there.
Comment 9 Stefan Schweizer (RETIRED) gentoo-dev 2006-09-01 06:54:13 UTC
OK,

so the plan is basically 
move all unpack code from /usr/lib/portage/bin/ebuild.sh to ${PORTDIR}/bin/unpack-0.sh
and change ebuild.sh to contain
source ${PORTDIR}/bin/unpack-0.sh

then add the features there. Probably more code could be moved and the file called ebuild-0.sh ( the -0 is to allow a -1 for incompatible changes )

So what is holding this change back now? :)
What is it that I need to do to get this solved?
Comment 10 Stefan Schweizer (RETIRED) gentoo-dev 2007-02-11 11:23:32 UTC
obviously no one from portage cares here .. and no one wants to say it
Comment 11 SpanKY gentoo-dev 2007-02-11 12:46:22 UTC
does it make you feel better if i say i dont care ?
Comment 12 Stefan Schweizer (RETIRED) gentoo-dev 2007-02-11 13:00:47 UTC
allows me to not spend any time on this any more. Get it out of the list of the bugs I filed, too
Comment 13 Mike Auty (RETIRED) gentoo-dev 2007-02-11 15:15:35 UTC
It's a pity, I was rather looking forward to being able to unpack absolute paths, it's hit me a few times...