Gentoo Archives: gentoo-dev

From: Michael Haubenwallner <haubi@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Re: Can pkg_nofetch determine if a file is already downloaded?
Date: Wed, 17 Oct 2018 16:03:24
Message-Id: bd950b2f-8160-343b-c61f-e98a753cc6c6@gentoo.org
In Reply to: Re: [gentoo-dev] Can pkg_nofetch determine if a file is already downloaded? by "Michał Górny"
1 On 10/15/2018 08:05 PM, Michał Górny wrote:
2 > On Mon, 2018-10-15 at 13:34 +0200, Michael Haubenwallner wrote:
3 >> Hi,
4 >>
5 >> in pkg_nofetch, beyond to "direct the user to download relevant source files",
6 >> I've found it useful to tell the user which filesystem directory to put the
7 >> files into once downloaded.
8 >>
9 >> Beyond that, I've also found it useful to tell the user whether a relevant
10 >> source file is 'already there' or 'still missing'.
11 >>
12 >> Since the EAPI 6 related update to pkg_* phases to not have access to DISTDIR
13 >> (even in earlier EAPI) any more, I'm wondering if both informations are still
14 >> available to pkg_nofetch in one or another way.
15 >>
16 >> Any idea?
17 >>
18 >> Or is my only option to reduce the information to "all these files need to be
19 >> put in your DISTDIR", requiring the user to find out both the right DISTDIR
20 >> and which of the listed files are still missing herself?
21 >>
22 >
23 > How would you know whether the file in DISTDIR is correct and complete?
24 >
25 Well, pkg_nofetch is called only if some files are still missing,
26 so portage really should have checked them before, and eventually
27 renamed invalid files to "checksum_failure", no?
28
29 /haubi/

Replies