ostree: use tarballs to replace the meta-lat and ostree in manifest

Use the dl_files to download meta-lat 20211214 version tarball, and
ostree 2019.1-1 tarball. No longer need the meta-lat and ostree
repositories in manifest.

Test Plan:

Pass: successfully build ostree-upgrade-mgr, ostree, mttyexec,
      initramfs-ostree, watchdog
Pass: successfully install test
Pass: successfully boot test

Story: 2008846
Task: 44194

Signed-off-by: Yue Tao <Yue.Tao@windriver.com>
Change-Id: Iff7d32c8764068318ccf854551addf1aa880334e
This commit is contained in:
Yue Tao 2021-12-17 11:12:54 +08:00 committed by Yue Tao
parent 1e202dc8d4
commit 9b855ce0af
10 changed files with 91 additions and 31 deletions

View File

@ -2,20 +2,23 @@
LOCAL_DIR=$1 LOCAL_DIR=$1
PKGNAME=watchdog PKGNAME=watchdog
BASE_DIR=${STX_GIT_SRC_DIR} META_LAT_TARBALL=meta-lat.tar.gz
PKG_DIR=${BASE_DIR}/meta-lat/data/debian/${PKGNAME} META_LAT=meta-lat
mkdir -p ${META_LAT}
tar xzvf ${META_LAT_TARBALL} --strip-components 1 -C ${META_LAT}
BASE_DIR=$(realpath ${META_LAT})
PKG_DIR=${BASE_DIR}/data/debian/${PKGNAME}
META_DIR=${PKG_DIR}/metadata_patches META_DIR=${PKG_DIR}/metadata_patches
SRC_DIR=${PKG_DIR}/sources SRC_DIR=${PKG_DIR}/sources
BASE_URL=https://snapshot.debian.org/archive/debian/20200424T151944Z/pool/main/w/${PKGNAME}
MAJOR_VER="5.16" MAJOR_VER="5.16"
REVISION="1" REVISION="1"
VER=${MAJOR_VER}-${REVISION} VER=${MAJOR_VER}-${REVISION}
DSC_FILE=${PKGNAME}_${VER}.dsc DSC_FILE=${PKGNAME}_${VER}.dsc
dget -x ${BASE_URL}/${DSC_FILE}
if [ $? != 0 ]; then dpkg-source -x ${DSC_FILE}
echo "Fail to download ${BASE_URL}/${DSC_FILE}"
exit -1
fi
cd ${LOCAL_DIR} cd ${LOCAL_DIR}
for patch in $(ls ${META_DIR}/*.patch); do for patch in $(ls ${META_DIR}/*.patch); do
patch -p1 < $patch || exit 1 patch -p1 < $patch || exit 1

View File

@ -1,6 +1,12 @@
--- ---
debver: 5.16-1 debver: 5.16-1
dl_hook: dl_hook dl_hook: dl_hook
archive: https://snapshot.debian.org/archive/debian/20200424T151944Z/pool/main/w/watchdog
dl_files:
meta-lat.tar.gz:
topdir: null
url: https://github.com/Wind-River/meta-lat/archive/refs/tags/20211214.tar.gz
md5sum: 38103be48cc97171c0a0a3ecd6713ffe
revision: revision:
dist: $STX_DIST dist: $STX_DIST
PKG_GITREVCOUNT: true PKG_GITREVCOUNT: true

View File

@ -1,9 +1,15 @@
#!/bin/bash #!/bin/bash
set -x
LOCAL_DIR=$1 LOCAL_DIR=$1
PKGNAME=initramfs-ostree PKGNAME=initramfs-ostree
BASE_DIR=$STX_GIT_SRC_DIR/meta-lat/data/debian META_LAT_TARBALL=meta-lat.tar.gz
SRC_DIR=$BASE_DIR/$PKGNAME/sources META_LAT=meta-lat
DEB_DIR=$BASE_DIR/$PKGNAME/metadata/debian
cp -Lr $SRC_DIR $LOCAL_DIR mkdir -p ${META_LAT}
cp -Lr $DEB_DIR $LOCAL_DIR tar xzvf ${META_LAT_TARBALL} --strip-components 1 -C ${META_LAT}
BASE_DIR=$(realpath ${META_LAT})
SRC_DIR=${BASE_DIR}/data/debian/${PKGNAME}/sources
DEB_DIR=${BASE_DIR}/data/debian/${PKGNAME}/metadata/debian
cp -Lr ${SRC_DIR} ${LOCAL_DIR}
cp -Lr ${DEB_DIR} ${LOCAL_DIR}

View File

@ -1,6 +1,11 @@
--- ---
debver: 1.0 debver: 1.0
dl_hook: dl_hook dl_hook: dl_hook
dl_files:
meta-lat.tar.gz:
topdir: null
url: https://github.com/Wind-River/meta-lat/archive/refs/tags/20211214.tar.gz
md5sum: 38103be48cc97171c0a0a3ecd6713ffe
revision: revision:
dist: $STX_DIST dist: $STX_DIST
PKG_GITREVCOUNT: true PKG_GITREVCOUNT: true

View File

@ -2,8 +2,14 @@
LOCAL_DIR=$1 LOCAL_DIR=$1
PKGNAME=mttyexec PKGNAME=mttyexec
BASE_DIR=$STX_GIT_SRC_DIR/meta-lat/data/debian META_LAT_TARBALL=meta-lat.tar.gz
SRC_DIR=$BASE_DIR/$PKGNAME/sources META_LAT=meta-lat
DEB_DIR=$BASE_DIR/$PKGNAME/metadata/debian
cp -Lr $SRC_DIR $LOCAL_DIR mkdir -p ${META_LAT}
cp -Lr $DEB_DIR $LOCAL_DIR tar xzvf ${META_LAT_TARBALL} --strip-components 1 -C ${META_LAT}
BASE_DIR=$(realpath ${META_LAT})
SRC_DIR=${BASE_DIR}/data/debian/${PKGNAME}/sources
DEB_DIR=${BASE_DIR}/data/debian/${PKGNAME}/metadata/debian
cp -Lr ${SRC_DIR} ${LOCAL_DIR}
cp -Lr ${DEB_DIR} ${LOCAL_DIR}

View File

@ -1,6 +1,11 @@
--- ---
debver: 0.1 debver: 0.1
dl_hook: dl_hook dl_hook: dl_hook
dl_files:
meta-lat.tar.gz:
topdir: null
url: https://github.com/Wind-River/meta-lat/archive/refs/tags/20211214.tar.gz
md5sum: 38103be48cc97171c0a0a3ecd6713ffe
revision: revision:
dist: $STX_DIST dist: $STX_DIST
PKG_GITREVCOUNT: true PKG_GITREVCOUNT: true

View File

@ -2,8 +2,14 @@
LOCAL_DIR=$1 LOCAL_DIR=$1
PKGNAME=ostree-upgrade-mgr PKGNAME=ostree-upgrade-mgr
BASE_DIR=$STX_GIT_SRC_DIR/meta-lat/data/debian META_LAT_TARBALL=meta-lat.tar.gz
SRC_DIR=$BASE_DIR/$PKGNAME/sources META_LAT=meta-lat
DEB_DIR=$BASE_DIR/$PKGNAME/metadata/debian
cp -Lr $SRC_DIR $LOCAL_DIR mkdir -p ${META_LAT}
cp -Lr $DEB_DIR $LOCAL_DIR tar xzvf ${META_LAT_TARBALL} --strip-components 1 -C ${META_LAT}
BASE_DIR=$(realpath ${META_LAT})
SRC_DIR=${BASE_DIR}/data/debian/${PKGNAME}/sources
DEB_DIR=${BASE_DIR}/data/debian/${PKGNAME}/metadata/debian
cp -Lr ${SRC_DIR} ${LOCAL_DIR}
cp -Lr ${DEB_DIR} ${LOCAL_DIR}

View File

@ -1,6 +1,11 @@
--- ---
debver: 1.0 debver: 1.0
dl_hook: dl_hook dl_hook: dl_hook
dl_files:
meta-lat.tar.gz:
topdir: null
url: https://github.com/Wind-River/meta-lat/archive/refs/tags/20211214.tar.gz
md5sum: 38103be48cc97171c0a0a3ecd6713ffe
revision: revision:
dist: $STX_DIST dist: $STX_DIST
PKG_GITREVCOUNT: true PKG_GITREVCOUNT: true

View File

@ -1,13 +1,22 @@
#!/bin/bash #!/bin/bash
LOCAL_DIR=$1
PKGNAME=ostree PKGNAME=ostree
BASE_DIR=$STX_GIT_SRC_DIR/ META_LAT_TARBALL=meta-lat.tar.gz
SRC_DIR=$BASE_DIR/$PKGNAME META_LAT=meta-lat
META_DIR=$BASE_DIR/meta-lat/data/debian/$PKGNAME/metadata_patches OSTREE_TARBALL=ostree.tar.gz
PATCHES_DIR=$BASE_DIR/meta-lat/data/debian/$PKGNAME/source_patches OSTREE=$1
cp -Lr $SRC_DIR $LOCAL_DIR
cd $LOCAL_DIR mkdir -p ${META_LAT}
tar xzvf ${META_LAT_TARBALL} --strip-components 1 -C ${META_LAT}
mkdir -p ${OSTREE}
tar xzvf ${OSTREE_TARBALL} --strip-components 1 -C ${OSTREE}
BASE_DIR=$(realpath ${META_LAT})
SRC_DIR=$(realpath ${OSTREE})
META_DIR=${BASE_DIR}/data/debian/${PKGNAME}/metadata_patches
PATCHES_DIR=${BASE_DIR}/data/debian/${PKGNAME}/source_patches
cd ${SRC_DIR}
for patch in `ls ${META_DIR}/*.patch`; do for patch in `ls ${META_DIR}/*.patch`; do
patch -p1 < $patch || exit 1 patch -p1 < $patch || exit 1
done done

View File

@ -1,3 +1,12 @@
--- ---
debver: 2019.1-1 debver: 2019.1-1
dl_files:
meta-lat.tar.gz:
topdir: null
url: https://github.com/Wind-River/meta-lat/archive/refs/tags/20211214.tar.gz
md5sum: 38103be48cc97171c0a0a3ecd6713ffe
ostree.tar.gz:
topdir: null
url: https://salsa.debian.org/debian/ostree/-/archive/debian/2019.1-1/ostree-debian-2019.1-1.tar.gz
md5sum: 31b095f28ceb6278964f69198d3e8a03
dl_hook: dl_hook dl_hook: dl_hook