umeshyv via lists.yoctoproject.org <umeshyv=gmail....@lists.yoctoproject.org> schrieb am Mo., 21. Okt. 2024, 18:30:
> Hi, I have requirement where recipe file reads set of .tgz files and it > should store in a location in rootfs and untar them(on freescale board). > Can you please show some pointers. > > SUMMARY = " Tools" > LICENSE = "CLOSED" > > FILESEXTRAPATHS_prepend := "${THISDIR}/files:" > > SRCREV = "${AUTOREV}" > > SRC_URI = "file://tool1.tgz > file://tool2.tgz > file://tool3.tgz > file://tool4.tgz" > The default behavior for tar files is to download them (do_fetch task) and then extract them into WORKDIR (do_unpack task) or into UNPACKDIR if you are on a very new Yocto version. That mean do_install should probably copy files but not call tar. It's simpler than what you are trying :-). You can see what folder structure each of the tasks creates if you look into the WORKDIR of this recipe. You can find WORKDIR e.g. with bitbake-getvar -r recipe-name WORKDIR Adrian > do_install () { > install -d ${IMAGE_ROOTFS}/usr/share/sigma-tools > > for file in ${WORKDIR}/.tgz;do > > tar -xvzf $file -C ${IMAGE_ROOTFS}/usr/share/<folder> > > done > > Alternatively instead of for loop tried below > > tar -xvzf file://tool1.tgz -C ${IMAGE_ROOTFS}/usr/share/<folder> > tar -xvzf file://tool2.tgz -C ${IMAGE_ROOTFS}/usr/share/<folder> > tar -xvzf file://tool3.tgz -C ${IMAGE_ROOTFS}/usr/share/<folder> > tar -xvzf file://tool4.tgz -C ${IMAGE_ROOTFS}/usr/share/<folder> > > But when I build following is the error > > DEBUG: Python function extend_recipe_sysroot finished > DEBUG: Executing shell function do_install > tar (child): Cannot connect to file: resolve failed > gzip: stdin: unexpected end of file > tar: Child returned status 128 > tar: Error is not recoverable: exiting now > > Can you please suggest to resolve errors and provide solutions > > Thanks > > > >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#64072): https://lists.yoctoproject.org/g/yocto/message/64072 Mute This Topic: https://lists.yoctoproject.org/mt/109136100/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-