summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/ui
diff options
context:
space:
mode:
authorJoshua Lock <josh@linux.intel.com>2011-08-18 17:50:22 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-08-23 10:00:34 -0700
commit5c34022a11fb4f30101d2336cd03c7ea1270ac52 (patch)
tree213eb1c8d4a0f4bd73e73e07bd02b0aa24d5d236 /bitbake/lib/bb/ui
parentba6366082185fb61eeec0c74a0464b8d2a81e244 (diff)
downloadpoky-5c34022a11fb4f30101d2336cd03c7ea1270ac52.tar.gz
bb/ui/hob: warn and prevent image build if no IMAGE_FSTYPE is set
If IMAGE_FSTYPE is empty and the user has opted to build an image warn them and prevent the build. Fixes [YOCTO #1267] (Bitbake rev: 023edbe6d04f25c7e0e7b615eb06cd3727c665cb) Signed-off-by: Joshua Lock <josh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/ui')
-rw-r--r--bitbake/lib/bb/ui/hob.py17
1 files changed, 16 insertions, 1 deletions
diff --git a/bitbake/lib/bb/ui/hob.py b/bitbake/lib/bb/ui/hob.py
index e02f48c93d..105b0ef121 100644
--- a/bitbake/lib/bb/ui/hob.py
+++ b/bitbake/lib/bb/ui/hob.py
@@ -437,7 +437,22 @@ class MainWindow (gtk.Window):
437 elif response == gtk.RESPONSE_OK: 437 elif response == gtk.RESPONSE_OK:
438 rep.base_image = "empty" 438 rep.base_image = "empty"
439 439
440 if build_image: 440 # Ensure at least one value is set in IMAGE_FSTYPES.
441 have_selected_fstype = False
442 if (len(self.prefs.selected_image_types) and
443 len(self.prefs.selected_image_types[0])):
444 have_selected_fstype = True
445
446 if build_image and not have_selected_fstype:
447 lbl = "<b>No image output type selected</b>\nThere is no image output"
448 lbl = lbl + " selected for the build. Please set an output image type"
449 lbl = lbl + " in the preferences (Edit -> Preferences)."
450 dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
451 dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
452 dialog.run()
453 dialog.destroy()
454 return
455 elif build_image:
441 self.handler.make_temp_dir() 456 self.handler.make_temp_dir()
442 recipepath = self.handler.get_temp_recipe_path(rep.base_image) 457 recipepath = self.handler.get_temp_recipe_path(rep.base_image)
443 image_name = recipepath.rstrip(".bb") 458 image_name = recipepath.rstrip(".bb")