[meta-intel] [PATCH 2/5] canterbury-corpus: rationalise unpack logic
Ong, Boon Leong
boon.leong.ong at intel.com
Tue May 20 15:37:19 PDT 2014
> -----Original Message-----
> From: meta-intel-bounces at yoctoproject.org [mailto:meta-intel-
> bounces at yoctoproject.org] On Behalf Of Ross Burton
> Sent: Wednesday, May 21, 2014 12:18 AM
> To: meta-intel at yoctoproject.org
> Subject: [meta-intel] [PATCH 2/5] canterbury-corpus: rationalise unpack logic
>
> Instead of manually unpacking, use the subdir parameter to put the tarball
> into the right directory.
>
> Signed-off-by: Ross Burton <ross.burton at intel.com>
Acked-by: Ong Boon Leong <boon.leong.ong at intel.com>
> ---
> .../canterbury-corpus/canterbury-corpus.bb | 16 +++-------------
> 1 file changed, 3 insertions(+), 13 deletions(-)
>
> diff --git a/common/recipes-corpus/canterbury-corpus/canterbury-corpus.bb
> b/common/recipes-corpus/canterbury-corpus/canterbury-corpus.bb
> index d15ad15..564dbdb 100644
> --- a/common/recipes-corpus/canterbury-corpus/canterbury-corpus.bb
> +++ b/common/recipes-corpus/canterbury-corpus/canterbury-corpus.bb
> @@ -10,25 +10,15 @@ LIC_FILES_CHKSUM =
> "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425
>
> PR = "r0"
>
> -S = "${WORKDIR}/canterbury-corpus"
> -
> -SRC_URI = "http://corpus.canterbury.ac.nz/resources/cantrbry.tar.gz"
> -
> +SRC_URI =
> "http://corpus.canterbury.ac.nz/resources/cantrbry.tar.gz;subdir=${BP}"
Agree on the above approach and it is cleaner after reading through bin_package.bbclass
> SRC_URI[md5sum] = "442e56cfffdf460d25b0b91650a55908"
> SRC_URI[sha256sum] =
> "f140e8a5b73d3f53198555a63bfb827889394a42f20825df33c810c3d5e3f8fb"
>
> -do_unpack () {
> - mkdir -p ${S}
> - tar -xf ${DL_DIR}/cantrbry.tar.gz -C ${S}
> -}
> -
> -do_unpack_append () {
> - rm -rf ${S}/patches
> -}
> -
> FILES_${PN} = "/lib/firmware/*"
>
> do_install () {
> + rm -rf ${S}/patches
> +
> install -d ${D}${base_libdir}/firmware
> install -m 644 ${S}/* ${D}${base_libdir}/firmware }
> --
> 1.7.10.4
>
> --
> _______________________________________________
> meta-intel mailing list
> meta-intel at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/meta-intel
More information about the meta-intel
mailing list