Patchwork [v3,2/3] core-image-directfb: Use 'distro_features_check' class

login
register
mail settings
Submitter Otavio Salvador
Date Sept. 4, 2013, 9:39 p.m.
Message ID <1378330751-29127-2-git-send-email-otavio@ossystems.com.br>
Download mbox | patch
Permalink /patch/57371/
State New
Headers show

Comments

Otavio Salvador - Sept. 4, 2013, 9:39 p.m.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
Changes in v3: None
Changes in v2: None

 meta/recipes-graphics/images/core-image-directfb.bb | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)

Patch

diff --git a/meta/recipes-graphics/images/core-image-directfb.bb b/meta/recipes-graphics/images/core-image-directfb.bb
index 3a74e94..b6187eb 100644
--- a/meta/recipes-graphics/images/core-image-directfb.bb
+++ b/meta/recipes-graphics/images/core-image-directfb.bb
@@ -6,16 +6,13 @@  PR="r0"
 LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \
                     file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
 
-inherit core-image
+inherit core-image distro_features_check
+
+REQUIRED_DISTRO_FEATURES = "directfb"
+CONFLICT_DISTRO_FEATURES = "x11"
 
 IMAGE_INSTALL += "\
 	${CORE_IMAGE_BASE_INSTALL} \
 	packagegroup-core-basic \
 	packagegroup-core-directfb \
 "
-
-python __anonymous () {
-	packages = d.getVar('DISTRO_FEATURES', True).split()
-	if "x11" in packages:
-		raise bb.parse.SkipPackage("FEATURE \"x11\" is in DISTRO_FEATURES, Please remove \"x11\" from DISTRO_FEATURES, use \"directfb\" instead of it\n")
-}