From 03735f27bd63cc12ca4ef00c737cc3d289c8fe23 Mon Sep 17 00:00:00 2001 From: Martin Dietze Date: Sun, 29 Nov 2009 21:12:38 +0100 Subject: mtd-utils.inc: flexible handling of ${mtd_utils} in do_stage and do_install * the include file relies on a given list of utils to be installed, but the list is not correct for all versions which include it * this revision adds a check for the existence of these files before trying to install/stage them --- recipes/mtd/mtd-utils.inc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/recipes/mtd/mtd-utils.inc b/recipes/mtd/mtd-utils.inc index dcf0e7c832..813a09fb13 100644 --- a/recipes/mtd/mtd-utils.inc +++ b/recipes/mtd/mtd-utils.inc @@ -17,7 +17,9 @@ do_stage () { install -m 0644 $f ${STAGING_INCDIR}/mtd/ done for binary in ${mtd_utils}; do - install -m 0755 $binary ${STAGING_BINDIR} + if [ -f $binary ]; then + install -m 0755 $binary ${STAGING_BINDIR} + fi done } @@ -25,7 +27,9 @@ do_install () { install -d ${D}${bindir} install -d ${D}${includedir}/mtd for binary in ${mtd_utils}; do - install -m 0755 $binary ${D}${bindir} + if [ -f $binary ]; then + install -m 0755 $binary ${D}${bindir} + fi done for f in ${S}/include/mtd/*.h; do install -m 0644 $f ${D}${includedir}/mtd -- cgit 1.2.3-korg