Hi Jean, Just tested this again, as long as the tarball is there in downloads, it will not redownload. If it starts with a fresh tmp directory, xsct-tarball will reextract to tmp/sysroots-xsct, but will not redownload tarball
Please check again Thanks, Jaewon -----Original Message----- From: [email protected] <[email protected]> On Behalf Of Manjukumar Harthikote Matha Sent: Thursday, March 7, 2019 9:49 AM To: Jean-Francois Dagenais <[email protected]>; [email protected] Subject: Re: [meta-xilinx] [PATCH] xsct-tarball: use fetcher cache > -----Original Message----- > From: [email protected] [mailto:meta-xilinx- > [email protected]] On Behalf Of Jean-Francois Dagenais > Sent: Thursday, March 07, 2019 8:39 AM > To: [email protected] > Subject: [meta-xilinx] [PATCH] xsct-tarball: use fetcher cache > > Without it, whenever a build starts on a fresh tmp directory, the file > is actually downloaded from http://petalinux.xilinx.com each time. > Even though it might be in the local download dir or in the > SOURCE_MIRROR_URL specified mirror. This unnecessarily slows down build > bootstrap and puts burden on xilinx.com servers. > Thanks JFD for the patch > Signed-off-by: Jean-Francois Dagenais <[email protected]> > --- > classes/xsct-tarball.bbclass | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) > > diff --git a/classes/xsct-tarball.bbclass > b/classes/xsct-tarball.bbclass index > c5a1b74..bc321a9 100644 > --- a/classes/xsct-tarball.bbclass > +++ b/classes/xsct-tarball.bbclass > @@ -1,7 +1,7 @@ > XSCT_LOADER ?= "${XSCT_STAGING_DIR}/SDK/${XILINX_VER_MAIN}/bin/xsct" > > -XSCT_URL ?= "http://petalinux.xilinx.com/sswreleases/rel-v2018.3/xsct-trim/" > -XSCT_TARBALL ?= "xsct.tar.xz" > +XSCT_URL ?= > +"http://petalinux.xilinx.com/sswreleases/rel-v2018.3/xsct- > trim/xsct.tar.xz" > +XSCT_TARBALL ?= "xsct_${XILINX_VER_MAIN}.tar.xz" > XSCT_DLDIR ?= "${DL_DIR}/xsct/" > XSCT_STAGING_DIR ?= "${STAGING_DIR}-xsct" > > @@ -70,9 +70,10 @@ python xsct_event_extract() { > localdata = bb.data.createCopy(d) > localdata.setVar('FILESPATH', "") > localdata.setVar('DL_DIR', xsctdldir) > - srcuri = d.expand("${XSCT_URL}${XSCT_TARBALL};md5sum=%s" % > chksum_tar) > + srcuri = d.expand("${XSCT_URL};md5sum=%s;downloadfilename=%s" > + % (chksum_tar, tarballname)) > bb.note("Fetching xsct binary tarball from %s" % srcuri) > - fetcher = bb.fetch2.Fetch([srcuri], localdata, cache=False) > + fetcher = bb.fetch2.Fetch([srcuri], localdata) > fetcher.download() > localpath = fetcher.localpath(srcuri) > if localpath != tarballpath and os.path.exists(localpath) > and not > os.path.exists(tarballpath): > -- > 2.11.0 > > -- > _______________________________________________ > meta-xilinx mailing list > [email protected] > https://lists.yoctoproject.org/listinfo/meta-xilinx -- _______________________________________________ meta-xilinx mailing list [email protected] https://lists.yoctoproject.org/listinfo/meta-xilinx -- _______________________________________________ meta-xilinx mailing list [email protected] https://lists.yoctoproject.org/listinfo/meta-xilinx
