abort/resume package builds could be a bit more controlled
georgeb at linuxfromscratch.org
Sat May 27 16:08:56 PDT 2006
Jeremy Huntwork wrote:
> On Sat, May 27, 2006 at 04:38:29PM -0600, Gerard Beekmans wrote:
>> Jeremy Huntwork wrote:
>>> Well, that won't work because then there's nothing to determine how to
>>> possibly remove any previous source directory for the next package.
>>> Hrm..., I need to think this through a bit more...
>> What do you mean by that? Why would /tmp/unpacked need to remain when
>> the source and/or build directories have been removed already?
> We don't store the name of the unpacked source directory anywhere as
> static data. How do you know what directory vim unpacks as otherwise?
> What we do is something like this:
> cd $(SRC); tar -xvf `ls -t $(1) | head -n1` > /tmp/unpacked
> That unpacks the source directory and spits out the name of the
> directory it just unpacked to /tmp/unpacked.
> So, if we want to remove any possible source directories before we start
> building a package, and we're not going to either unpack the directory
> first or store that static data somewhere, how are we going to know what
> directory to remove?
I suggested to Greg Schafer, a few years ago, that you could extract
the package directory name by 'listing the contents' and trimming the
top entry. I believe he ended up with the cmd DIR=$(bunzip2 -dc $1 |
tar tf - | head -n 1 ) and then he stripped $DIR . Would this be helpful?
> One possible solution is to keep that information in the LFS book for
> any package that doesn't do the default of pkgname-vers. Tcl and vim
> come to mind. And as Chris already commented in another thread, having
> that information in the book as an entity could be useful for other
> purposes as well. See the current vim instructions.
More information about the alfs-discuss