summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--conf/distro/shr.conf12
-rw-r--r--recipes/shr/shr-version.bb16
2 files changed, 17 insertions, 11 deletions
diff --git a/conf/distro/shr.conf b/conf/distro/shr.conf
index 7edc6af465..9f7a9a4948 100644
--- a/conf/distro/shr.conf
+++ b/conf/distro/shr.conf
@@ -78,17 +78,6 @@ PACKAGE_ARCH_pn-keymaps_om-gta02 = "armv4t"
PACKAGE_ARCH_pn-neod_om-gta01 = "armv4t"
PACKAGE_ARCH_pn-neod_om-gta02 = "armv4t"
-# Helper to say what image we built
-SHR_VERSION_FILE = "${IMAGE_ROOTFS}/${sysconfdir}/shr-version"
-ROOTFS_POSTPROCESS_COMMAND += "OLD_PWD=$PWD; cd `dirname '${FILE_DIRNAME}'`; echo Tag Name: `git tag|tail -n 1`> ${SHR_VERSION_FILE};cd $OLD_PWD;"
-ROOTFS_POSTPROCESS_COMMAND += "OLD_PWD=$PWD; cd `dirname '${FILE_DIRNAME}'`; echo VERSION: `git-log -n1 --pretty=oneline|awk '{print $1}'` >> ${SHR_VERSION_FILE}; cd $OLD_PWD;"
-ROOTFS_POSTPROCESS_COMMAND += "OLD_PWD=$PWD; cd `dirname '${FILE_DIRNAME}'`; echo Branch: ` git branch |awk '/*/{print $2}'` >> ${SHR_VERSION_FILE}; cd $OLD_PWD;"
-ROOTFS_POSTPROCESS_COMMAND += "echo Build Host: `cat /etc/hostname` >> ${SHR_VERSION_FILE};"
-ROOTFS_POSTPROCESS_COMMAND += "echo Time Stamp: `date -R` >> ${SHR_VERSION_FILE};"
-
-#Package customization
-EXTRA_OECONF-pn_qemu += " --target-list=arm-linux-user,arm-softmmu"
-
#Illume settings
ILLUME_CONFIG = "e-wm-config-illume-shr"
ILLUME_THEME = "e-wm-theme-illume-gry"
@@ -194,6 +183,7 @@ DISTRO_EXTRA_APPS += '${@base_conditional("DISTRO_TYPE", "release", "", "task-cl
# util-linux-ng-mount util-linux-ng-umount: busybox mount is broken
# angstrom-libc-fixup-hack: fixes an obscure bug with libc.so symlink
DISTRO_EXTRA_RDEPENDS += "\
+ shr-version \
distro-feed-configs \
util-linux-ng-mount util-linux-ng-umount \
angstrom-libc-fixup-hack \
diff --git a/recipes/shr/shr-version.bb b/recipes/shr/shr-version.bb
new file mode 100644
index 0000000000..26618aa5cc
--- /dev/null
+++ b/recipes/shr/shr-version.bb
@@ -0,0 +1,16 @@
+LICENSE = "MIT"
+
+PV = "1.0${DISTRO_VERSION}"
+
+PACKAGES = "${PN}"
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+export METADATA_REVISION
+export METADATA_BRANCH
+
+do_install() {
+ mkdir -p ${D}${sysconfdir}
+ echo "SHR ${DISTRO_VERSION}" > ${D}${sysconfdir}/shr-version
+ echo "Built from branch: ${METADATA_BRANCH}" >> ${D}${sysconfdir}/shr-version
+ echo "Revision: ${METADATA_REVISION}" >> ${D}${sysconfdir}/shr-version
+}