From 590eb981f63692a7cd712e81095f348d6ca267a2 Mon Sep 17 00:00:00 2001
From: Martin Kelly <mkelly@xevo.com>
Date: Mon, 17 Jul 2017 10:31:01 -0700
Subject: [PATCH] agl-devel: auto-add drivers for vmdk images

Currently, if you build a vmdk file, you also need to manually add in
drivers to make your image fast (vbox/vmware drivers). We can make this
automatic so that when you build a vmdk, drivers are automatically added
in. Using this approach, both vbox and vmware drivers are added, which
is more than is generally necessary, but it means that a single vmdk
image can support many use cases, and the same image can be distributed
to many developers.

For developer images, this seems like a good tradeoff because
convenience is more important than disk space/bloat for developers. For
production, we leave this option off to reduce unneeded components.

Change-Id: I8139a3ed94599c1732ea8b58bbc735c0de594234
Signed-off-by: Martin Kelly <mkelly@xevo.com>
Reviewed-on: https://gerrit.automotivelinux.org/gerrit/10223
Tested-by: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
ci-image-build: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
ci-image-boot-test: Jenkins Job builder account <agl-jobbuilder@automotivelinux.org>
Reviewed-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org>
---
 meta-agl/conf/include/agl-devel.inc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta-agl/conf/include/agl-devel.inc b/meta-agl/conf/include/agl-devel.inc
index 9610fd8fd..f75f4be3b 100644
--- a/meta-agl/conf/include/agl-devel.inc
+++ b/meta-agl/conf/include/agl-devel.inc
@@ -4,6 +4,8 @@ IMAGE_INSTALL_append = " \
     packagegroup-agl-devel \
 "
 
+IMAGE_INSTALL_append = "${@bb.utils.contains('IMAGE_FSTYPES', 'vmdk', ' open-vm-tools vboxguestdrivers', '', d)}"
+
 # disable install of debug files in SDK
 # initial value: SDKIMAGE_FEATURES="dev-pkgs dbg-pkgs staticdev-pkgs"
 SDKIMAGE_FEATURES="dev-pkgs"
-- 
2.16.6