dreambox-image: fix path to opkg libdir for .nfo
[opendreambox.git] / meta-opendreambox / recipes-dreambox / images / dreambox-image-dm7020hdv2.bb
1 IMAGE_PKGTYPE = "ipk"
2
3 require conf/machine/include/dreambox-nand-1024mb-2k.inc
4
5 require dreambox-image.inc
6
7 IMAGE_NAME = "${IMAGE_BASENAME}-${DATETIME}"
8 IMAGE_LINK_NAME = "${IMAGE_BASENAME}"
9
10 do_rootfs_append() {
11     if [ -e ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfi ]; then
12         VER=`grep ^Version: ${IMAGE_ROOTFS}${OPKGLIBDIR}/opkg/info/enigma2.control | cut -d ' ' -f 2`
13         DATE=`date -r ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfi -u '+%F %R'`
14         MD5=`md5sum ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfi | cut -d ' ' -f 1`
15         SHA256=`sha256sum ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfi | cut -d ' ' -f 1`
16         # In addition to the fields below, you may add 'Issuer' and 'Description'.
17         echo "Date: $DATE" > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
18         echo "Enigma2: $VER" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
19         echo "Distro: ${DISTRO_NAME} ${DISTRO_VERSION}" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
20         echo "Machine: Dreambox ${MACHINE}" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
21         echo "Link: ${DISTRO_FEED_URI}" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
22         echo "MD5: $MD5" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
23         echo "SHA256: $SHA256" >> ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.nfo
24     fi
25 }