1 |
José Fonseca wrote: |
2 |
> On Tue, Nov 12, 2002 at 01:29:44AM +0100, Marko Mikulicic wrote: > |
3 |
> |
4 |
> ...but becare full with these - you should keep them because they're |
5 |
> really not defined on the above files and the getting the last one wrong |
6 |
> will lead to the deletion of all files in distfiles...! |
7 |
oh. I didn't checked. I just thought it was from there. |
8 |
|
9 |
Now that I'm looking better I've seen: |
10 |
portage.settings["PORTAGE_CACHEDIR"] in /usr/bin/emerge |
11 |
rsync (or sync). From what is the portage cache built ? |
12 |
Since it is a cache it should mean that i caches some other |
13 |
information wich remains present on disk, and the cache could be rebuilt |
14 |
at any instant. |
15 |
Obviously it doesnt cache /var/db/pkg because overlay ebuild are listed |
16 |
there. Where |
17 |
is the base data (meta-) which /usr/portage/metadata/cache caches ? |
18 |
This also should solve the errors Johannes and me are getting. |
19 |
for example: |
20 |
|
21 |
$ qpkg linux-headers -I -v |
22 |
sys-kernel/linux-headers-2.4.19 |
23 |
|
24 |
but /usr/portage/metadata/cache/sys-kernel/linux-headers-2.4.19 doesn't |
25 |
exist |
26 |
|
27 |
> |
28 |
> The way the script work is first get the list of all sources related |
29 |
> with the installed files from portache cache, merge it with the list of |
30 |
> sources in distfiles, and delete those which are unique - i.e., only are |
31 |
> in distfiles. |
32 |
> There are two caveats with this procedure: |
33 |
> - it will delete sources of packages in PORTAGE_OVERLAY, if you have |
34 |
I don't understand why packages in PORTAGE_OVERLAY are not put in the |
35 |
/usr/portage/metadata/cache. |
36 |
They are in /var/db/pkg/ and should be treaten like any other ebuild. |
37 |
|
38 |
> - if the cache is busted (or can't be found), the most probable outcome |
39 |
> is that all files in distfiles get deleted... so a good idea is to |
40 |
> replace 'rm' by 'echo' to get an idea of what is gonna be deleted. |
41 |
I guess that simplicity or elegance would be completely destroyed |
42 |
when introducing commandline parsing for the gentooish --pretend (or at |
43 |
least only '-p') |
44 |
option. However, my opinion is that first we should have a working |
45 |
script that helps |
46 |
somebody who knows what he want, and then |
47 |
|
48 |
> |
49 |
> These two caveats could be overcomed by getting the sources directly |
50 |
> from the installed ebuilds, but that would be terribly slow compared |
51 |
> with this, due to the parsing of all ebuilds. |
52 |
yes, because of the ${P} or ${PN} or who knows what other triks are in |
53 |
ther (for example |
54 |
xfree 4.2.1 X_DRIVERS, MS_FONT_URLS, ....). you should evaluate the |
55 |
ebuild in order |
56 |
to resolve local script variables; not a simple sed. And then evaluating |
57 |
the script is not so |
58 |
simple because of "inherits" and other commands not defined there. I had |
59 |
some problems |
60 |
while writting emerge-rsync (it will be there in the next gentoolkit). |
61 |
I think your choice is not only the faster but also it will work with |
62 |
all packages which |
63 |
have passed emerge. Why duplicate the work. Emerge produced the output, |
64 |
why don't use it. |
65 |
I think that the question about portage overlay is not to be solved here |
66 |
but with a more general solution. |
67 |
|
68 |
Marko |
69 |
|
70 |
|
71 |
-- |
72 |
gentoo-dev@g.o mailing list |