Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Alex Franco <alejandro.franco@linux.intel.com>
To: openembedded-core@lists.openembedded.org
Cc: paul.eggleton@linux.intel.com
Subject: [PATCH 1/3] Empty image: core-image-empty recipe, Rootfs fix
Date: Wed, 26 Aug 2015 16:57:33 -0500	[thread overview]
Message-ID: <1440626255-29614-2-git-send-email-alejandro.franco@linux.intel.com> (raw)
In-Reply-To: <1440626255-29614-1-git-send-email-alejandro.franco@linux.intel.com>

Added a core-image-empty recipe, as well as a DpkgOpkgRootfs test
which skips the package post installs step, if PACKAGE_INSTALL is
empty.

[YOCTO #7664]

Signed-off-by: Alex Franco <alejandro.franco@linux.intel.com>
---
 meta/lib/oe/rootfs.py                        | 6 +++++-
 meta/recipes-core/images/core-image-empty.bb | 7 +++++++
 2 files changed, 12 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-core/images/core-image-empty.bb

diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py
index 8c8244c..f8cc6eb 100644
--- a/meta/lib/oe/rootfs.py
+++ b/meta/lib/oe/rootfs.py
@@ -585,7 +585,11 @@ class DpkgOpkgRootfs(Rootfs):
 
         pkg_list = []
 
-        pkgs = self._get_pkgs_postinsts(status_file)
+        pkgs = None
+        if not self.d.getVar('PACKAGE_INSTALL', True).strip():
+            bb.note("Building empty image")
+        else:
+            pkgs = self._get_pkgs_postinsts(status_file)
         if pkgs:
             root = "__packagegroup_postinst__"
             pkgs[root] = pkgs.keys()
diff --git a/meta/recipes-core/images/core-image-empty.bb b/meta/recipes-core/images/core-image-empty.bb
new file mode 100644
index 0000000..550567c
--- /dev/null
+++ b/meta/recipes-core/images/core-image-empty.bb
@@ -0,0 +1,7 @@
+SUMMARY = "An empty image."
+IMAGE_INSTALL = ""
+IMAGE_LINGUAS = ""
+PACKAGE_INSTALL = ""
+LICENSE = "MIT"
+
+inherit image
-- 
2.5.0



  reply	other threads:[~2015-08-26 21:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-26 21:57 [PATCH 0/3] Empty-image functionality Alex Franco
2015-08-26 21:57 ` Alex Franco [this message]
2015-08-29 11:18   ` [PATCH 1/3] Empty image: core-image-empty recipe, Rootfs fix Paul Eggleton
2015-09-08 23:20     ` Alex Franco
2015-08-26 21:57 ` [PATCH 2/3] Empty image: package list splitting and iteration Alex Franco
2015-08-26 21:57 ` [PATCH 3/3] Empty image: filesystem allocation Alex Franco
2015-09-11 17:26   ` Benjamin Esquivel
2015-09-11 22:32     ` Richard Purdie
2015-08-28 18:23 ` [PATCH 0/3] Empty-image functionality Aníbal Limón

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1440626255-29614-2-git-send-email-alejandro.franco@linux.intel.com \
    --to=alejandro.franco@linux.intel.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=paul.eggleton@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox