[oe-commits] [openembedded-core] 47/50: wic: check that filesystem is specified for a rootfs partition

git at git.openembedded.org git at git.openembedded.org
Tue Nov 15 15:21:19 UTC 2016


rpurdie pushed a commit to branch master
in repository openembedded-core.

commit b8c35fcad57810a87aa25ebeb533adf286eed565
Author: Maciej Borzecki <maciej.borzecki at rndity.com>
AuthorDate: Thu Nov 10 13:18:34 2016 +0100

    wic: check that filesystem is specified for a rootfs partition
    
    We explicitly check for --fstype if no source was provided for a
    partition. However, this was not the case for rootfs partitions. Make
    sure to raise an error if filesystem was left unspecified when preparing
    a rootfs partition image.
    
    Signed-off-by: Maciej Borzecki <maciej.borzecki at rndity.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 scripts/lib/wic/partition.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index f383533..ac4c836 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -190,6 +190,10 @@ class Partition():
         if os.path.isfile(rootfs):
             os.remove(rootfs)
 
+        if not self.fstype:
+            msger.error("File system for partition %s not specified in kickstart, " \
+                        "use --fstype option" % (self.mountpoint))
+
         for prefix in ("ext", "btrfs", "vfat", "squashfs"):
             if self.fstype.startswith(prefix):
                 method = getattr(self, "prepare_rootfs_" + prefix)

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list