Skip to contentSkip to conversation

Hob: Bug fixes: image_types, runqemu/deploy functionality filter, and DISTRO setting

GIT PULL New Dongxiao Xu 2 participants 14 messages Mar 24, 2012 – Mar 27, 2012

lore
Share & tools
lore
#0 lore raw

Hi Richard,

This is the third pull request for Hob bug fixes, please help to review and pull.

Changes from v2:
1) Change the logic in set_distro(), that is, if defaultsetup is selected in Hob advanced setting dialog, we should leave DISTRO variable not set in bitbake server.
2) Add a new patch to avoid hardcode TMPDIR when executing runqemu.

Thanks,
Dongxiao

The following changes since commit 0348ef08db9ac425d83126d2e6eb465adc28b110:

Hob: Change the descriptions for view_recipe_button and view_package_button (2012-03-23 16:09:35 +0000)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dxu4/hob-bugfix
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/hob-bugfix

Dongxiao Xu (9):
Hob: Remove unnecessary PARSE_BBFILES command
Hob: Cleanup for hobeventhandler.py
Hob: Initial an empty label in recipeselectionpage.py
Hob: Change the Hob initialization process
Hob: Fix the workaround to get image types
Hob: Add a supported image type "vmdk"
Hob: runqemu and deployment functionality filter
Hob: Set empty DISTRO if "defaultsetup" is selected
Hob: Avoid getting TMPDIR in hardcode

 lib/bb/ui/crumbs/builder.py             |   23 +++++--
 lib/bb/ui/crumbs/hobeventhandler.py     |   94 ++++++++++++++-----------------
 lib/bb/ui/crumbs/hobwidget.py           |    1 +
 lib/bb/ui/crumbs/imagedetailspage.py    |   44 +++++++++++----
 lib/bb/ui/crumbs/recipeselectionpage.py |    2 +-
 lib/bb/ui/hob.py                        |    2 -
 6 files changed, 94 insertions(+), 72 deletions(-)
Signature · 1 line
1.7.4.1
#2 lore raw

PATCH 2/9 Hob: Cleanup for hobeventhandler.py

---
 lib/bb/ui/crumbs/builder.py         |    2 +-
 lib/bb/ui/crumbs/hobeventhandler.py |   75 ++++++++++++++--------------------
 lib/bb/ui/hob.py                    |    4 +-
 3 files changed, 34 insertions(+), 47 deletions(-)
lib/bb/ui/crumbs/builder.py +1 -1
index 2fe67d9..0faef9b 100755
@@ -409,7 +409,7 @@ class Builder(gtk.Window):
         self.parameters.all_layers = layers
 
     def handler_command_succeeded_cb(self, handler, initcmd):
-        if initcmd == self.handler.LAYERS_REFRESH:
+        if initcmd == self.handler.GENERATE_CONFIGURATION:
             self.image_configuration_page.switch_machine_combo()
         elif initcmd in [self.handler.GENERATE_RECIPES,
                          self.handler.GENERATE_PACKAGES,
lib/bb/ui/crumbs/hobeventhandler.py +31 -44

131 lines not on this page · raw message

lib/bb/ui/hob.py +2 -2
index daa708b..7c147c4 100755
@@ -56,10 +56,10 @@ def main (server = None, eventHandler = None):
     package_model = PackageListModel()
 
     hobHandler = HobHandler(server, recipe_model, package_model)
-    if hobHandler.kick() == False:
-        return 1
     builder = Builder(hobHandler, recipe_model, package_model)
 
+    hobHandler.generate_configuration()
+
     # This timeout function regularly probes the event queue to find out if we
     # have any messages waiting for us.
     gobject.timeout_add(10, event_handle_idle_func, eventHandler, hobHandler)
Signature · 1 line
1.7.4.1
#1 lore raw

PATCH 1/9 Hob: Remove unnecessary PARSE_BBFILES command

In reply to Dongxiao Xu

The ASYNC commands can automatically detect if BB file parsing is needed. Therefore remove this explicit parsing command.

---
 lib/bb/ui/crumbs/hobeventhandler.py |    6 +-----
 1 files changed, 1 insertions(+), 5 deletions(-)
lib/bb/ui/crumbs/hobeventhandler.py +1 -5
index 07cc039..664f866 100644
@@ -62,7 +62,7 @@ class HobHandler(gobject.GObject):
                                      (gobject.TYPE_PYOBJECT,)),
     }
 
-    (CFG_AVAIL_LAYERS, CFG_PATH_LAYERS, CFG_FILES_DISTRO, CFG_FILES_MACH, CFG_FILES_SDKMACH, FILES_MATCH_CLASS, PARSE_CONFIG, PARSE_BBFILES, GENERATE_TGTS, GENERATE_PACKAGEINFO, BUILD_TARGET_RECIPES, BUILD_TARGET_IMAGE, CMD_END) = range(13)
+    (CFG_AVAIL_LAYERS, CFG_PATH_LAYERS, CFG_FILES_DISTRO, CFG_FILES_MACH, CFG_FILES_SDKMACH, FILES_MATCH_CLASS, PARSE_CONFIG, GENERATE_TGTS, GENERATE_PACKAGEINFO, BUILD_TARGET_RECIPES, BUILD_TARGET_IMAGE, CMD_END) = range(12)
     (LAYERS_REFRESH, GENERATE_RECIPES, GENERATE_PACKAGES, GENERATE_IMAGE, POPULATE_PACKAGEINFO) = range(5)
 
     def __init__(self, server, recipe_model, package_model):
@@ -136,8 +136,6 @@ class HobHandler(gobject.GObject):
             self.server.runCommand(["findFilesMatchingInDir", "rootfs_", "classes"])
         elif next_command == self.PARSE_CONFIG:
             self.server.runCommand(["parseConfigurationFiles", "", ""])
-        elif next_command == self.PARSE_BBFILES:
-            self.server.runCommand(["parseFiles"])
         elif next_command == self.GENERATE_TGTS:
             self.server.runCommand(["generateTargetsTree", "classes/image.bbclass", []])
         elif next_command == self.GENERATE_PACKAGEINFO:
@@ -345,7 +343,6 @@ class HobHandler(gobject.GObject):
         targets.extend(tgts)
         self.recipe_queue = targets
         self.commands_async.append(self.PARSE_CONFIG)
-        self.commands_async.append(self.PARSE_BBFILES)
         self.commands_async.append(self.BUILD_TARGET_RECIPES)
         self.run_next_command(self.GENERATE_PACKAGES)
 
@@ -353,7 +350,6 @@ class HobHandler(gobject.GObject):
         self.package_queue = tgts
         self.toolchain_build = toolchain_build
         self.commands_async.append(self.PARSE_CONFIG)
-        self.commands_async.append(self.PARSE_BBFILES)
         self.commands_async.append(self.BUILD_TARGET_IMAGE)
         self.run_next_command(self.GENERATE_IMAGE)
 
Signature · 1 line
1.7.4.1
#3 lore raw

PATCH 3/9 Hob: Initial an empty label in recipeselectionpage.py

In reply to Dongxiao Xu

When creating label in recipeselectionpage.py, the builder's configuration may not be ready yet, so create an empty label in initialization.

---
 lib/bb/ui/crumbs/recipeselectionpage.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
lib/bb/ui/crumbs/recipeselectionpage.py +1 -1
index 881b2ec..ebdb7c1 100755
@@ -118,7 +118,7 @@ class RecipeSelectionPage (HobPage):
         self.create_visual_elements()
 
     def create_visual_elements(self):
-        self.label = gtk.Label("Recipes included: %s" % len(self.builder.configuration.selected_recipes))
+        self.label = gtk.Label()
         self.eventbox = self.add_onto_top_bar(self.label, 73)
         self.pack_start(self.eventbox, expand=False, fill=False)
         self.pack_start(self.group_align, expand=True, fill=True)
Signature · 1 line
1.7.4.1
#4 lore raw

PATCH 4/9 Hob: Change the Hob initialization process

In reply to Dongxiao Xu

This change allows adding extra inherits before getting all the parameters.

---
 lib/bb/ui/crumbs/builder.py         |   17 +++++++++++------
 lib/bb/ui/crumbs/hobeventhandler.py |    6 +++++-
 lib/bb/ui/hob.py                    |    2 --
 3 files changed, 16 insertions(+), 9 deletions(-)
lib/bb/ui/crumbs/builder.py +11 -6
index 0faef9b..d348497 100755
@@ -186,11 +186,6 @@ class Builder(gtk.Window):
 
         self.template = None
 
-        # settings
-        params = self.handler.get_parameters()
-        self.configuration = Configuration(params)
-        self.parameters = Parameters(params)
-
         # build step
         self.current_step = None
         self.previous_step = None
@@ -224,6 +219,10 @@ class Builder(gtk.Window):
         self.handler.connect("command-succeeded",        self.handler_command_succeeded_cb)
         self.handler.connect("command-failed",           self.handler_command_failed_cb)
 
+        self.handler.init_cooker()
+        self.handler.set_extra_inherit("image_types")
+        self.handler.parse_config()
+
         self.switch_page(self.MACHINE_SELECTION)
 
     def create_visual_elements(self):
@@ -409,7 +408,13 @@ class Builder(gtk.Window):
         self.parameters.all_layers = layers
 
     def handler_command_succeeded_cb(self, handler, initcmd):
-        if initcmd == self.handler.GENERATE_CONFIGURATION:
+        if initcmd == self.handler.PARSE_CONFIG:
+            # settings
+            params = self.handler.get_parameters()
+            self.configuration = Configuration(params)
+            self.parameters = Parameters(params)
+            self.handler.generate_configuration()
+        elif initcmd == self.handler.GENERATE_CONFIGURATION:
             self.image_configuration_page.switch_machine_combo()
         elif initcmd in [self.handler.GENERATE_RECIPES,
                          self.handler.GENERATE_PACKAGES,
lib/bb/ui/crumbs/hobeventhandler.py +5 -1
index 8094d2d..308ef4d 100644
@@ -62,7 +62,7 @@ class HobHandler(gobject.GObject):
                                      (gobject.TYPE_PYOBJECT,)),
     }
 
-    (GENERATE_CONFIGURATION, GENERATE_RECIPES, GENERATE_PACKAGES, GENERATE_IMAGE, POPULATE_PACKAGEINFO) = range(5)
+    (PARSE_CONFIG, GENERATE_CONFIGURATION, GENERATE_RECIPES, GENERATE_PACKAGES, GENERATE_IMAGE, POPULATE_PACKAGEINFO) = range(6)
     (SUB_PATH_LAYERS, SUB_FILES_DISTRO, SUB_FILES_MACH, SUB_FILES_SDKMACH, SUB_MATCH_CLASS, SUB_PARSE_CONFIG, SUB_GNERATE_TGTS, SUB_GENERATE_PKGINFO, SUB_BUILD_RECIPES, SUB_BUILD_IMAGE) = range(10)
 
     def __init__(self, server, recipe_model, package_model):
@@ -246,6 +246,10 @@ class HobHandler(gobject.GObject):
     def init_cooker(self):
         self.server.runCommand(["initCooker"])
 
+    def parse_config(self):
+        self.commands_async.append(self.SUB_PARSE_CONFIG)
+        self.run_next_command(self.PARSE_CONFIG)
+
     def refresh_layers(self, bblayers):
         self.init_cooker()
         self.set_bblayers(bblayers)
lib/bb/ui/hob.py +0 -2
index 7c147c4..e72ab23 100755
@@ -58,8 +58,6 @@ def main (server = None, eventHandler = None):
     hobHandler = HobHandler(server, recipe_model, package_model)
     builder = Builder(hobHandler, recipe_model, package_model)
 
-    hobHandler.generate_configuration()
-
     # This timeout function regularly probes the event queue to find out if we
     # have any messages waiting for us.
     gobject.timeout_add(10, event_handle_idle_func, eventHandler, hobHandler)
Signature · 1 line
1.7.4.1
#6 lore raw

PATCH 6/9 Hob: Add a supported image type "vmdk"

In reply to Dongxiao Xu
---
 lib/bb/ui/crumbs/hobwidget.py |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
lib/bb/ui/crumbs/hobwidget.py +1 -0
index 020c5e2..1213b11 100644
@@ -82,6 +82,7 @@ class hcc:
         "cpio"          : ["cpio"],
         "cpio.gz"       : ["cpio.gz"],
         "cpio.xz"       : ["cpio.xz"],
+        "vmdk"          : ["vmdk"],
         "cpio.lzma"     : ["cpio.lzma"],
     }
 
Signature · 1 line
1.7.4.1
#5 lore raw

PATCH 5/9 Hob: Fix the workaround to get image types

In reply to Dongxiao Xu
---
 lib/bb/ui/crumbs/hobeventhandler.py |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
lib/bb/ui/crumbs/hobeventhandler.py +1 -2
index 308ef4d..ec3e0ef 100644
@@ -430,8 +430,7 @@ class HobHandler(gobject.GObject):
 
         params["image_fstypes"] = self.server.runCommand(["getVariable", "IMAGE_FSTYPES"]) or ""
 
-        # walkaround
-        params["image_types"] = " ".join(hcc.SUPPORTED_IMAGE_TYPES.keys()).lstrip(" ")
+        params["image_types"] = self.server.runCommand(["getVariable", "IMAGE_TYPES"]) or ""
 
         params["conf_version"] = self.server.runCommand(["getVariable", "CONF_VERSION"]) or ""
         params["lconf_version"] = self.server.runCommand(["getVariable", "LCONF_VERSION"]) or ""
Signature · 1 line
1.7.4.1
#7 lore raw

PATCH 7/9 Hob: runqemu and deployment functionality filter

In reply to Dongxiao Xu

Implement the filter for runqemu and deployment functionality.

runqemu
1) suffix should be in the list of RUNNABLE_IMAGE_TYPES.
2) machine should match the pattern of RUNNABLE_MACHINE_PATTERNS.

deployment:
1) suffix should be in the list of DEPLOYMENT_IMAGE_TYPES.

---
 lib/bb/ui/crumbs/builder.py          |    3 ++
 lib/bb/ui/crumbs/hobeventhandler.py  |    4 +++
 lib/bb/ui/crumbs/imagedetailspage.py |   44 +++++++++++++++++++++++++--------
 3 files changed, 40 insertions(+), 11 deletions(-)
lib/bb/ui/crumbs/builder.py +3 -0
index d348497..2984490 100755
@@ -135,6 +135,9 @@ class Parameters:
         self.image_names = []
         self.image_addr = params["image_addr"]
         self.image_types = params["image_types"].split()
+        self.runnable_image_types = params["runnable_image_types"].split()
+        self.runnable_machine_patterns = params["runnable_machine_patterns"].split()
+        self.deployable_image_types = params["deployable_image_types"].split()
 
 class Builder(gtk.Window):
 
lib/bb/ui/crumbs/hobeventhandler.py +4 -0
index ec3e0ef..4b8aabc 100644
@@ -434,4 +434,8 @@ class HobHandler(gobject.GObject):
 
         params["conf_version"] = self.server.runCommand(["getVariable", "CONF_VERSION"]) or ""
         params["lconf_version"] = self.server.runCommand(["getVariable", "LCONF_VERSION"]) or ""
+
+        params["runnable_image_types"] = self.server.runCommand(["getVariable", "RUNNABLE_IMAGE_TYPES"]) or ""
+        params["runnable_machine_patterns"] = self.server.runCommand(["getVariable", "RUNNABLE_MACHINE_PATTERNS"]) or ""
+        params["deployable_image_types"] = self.server.runCommand(["getVariable", "DEPLOYABLE_IMAGE_TYPES"]) or ""
         return params
lib/bb/ui/crumbs/imagedetailspage.py +33 -11

68 lines not on this page · raw message

Signature · 1 line
1.7.4.1
#8 lore raw

PATCH 8/9 Hob: Set empty DISTRO if "defaultsetup" is selected

In reply to Dongxiao Xu

In Hob advanced setting, if "defaultsetup" is selected, we need to leave DISTRO variable not set in bitbake server.

Otherwise, defaultsetup.conf will be parsed twice, causing TMPDIR and its related variables mess up.

---
 lib/bb/ui/crumbs/hobeventhandler.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
lib/bb/ui/crumbs/hobeventhandler.py +2 -1
index 4b8aabc..e342811 100644
@@ -274,7 +274,8 @@ class HobHandler(gobject.GObject):
         self.server.runCommand(["setVariable", "IMAGE_FSTYPES", " ".join(image_fstypes).lstrip(" ")])
 
     def set_distro(self, distro):
-        self.server.runCommand(["setVariable", "DISTRO", distro])
+        if distro != "defaultsetup":
+            self.server.runCommand(["setVariable", "DISTRO", distro])
 
     def set_package_format(self, format):
         package_classes = ""
Signature · 1 line
1.7.4.1
#9 lore raw

PATCH 9/9 Hob: Avoid getting TMPDIR in hardcode

In reply to Dongxiao Xu

We should get TMPDIR from bitbake server instead of hardcode.

---
 lib/bb/ui/crumbs/builder.py         |    3 ++-
 lib/bb/ui/crumbs/hobeventhandler.py |    1 +
 2 files changed, 3 insertions(+), 1 deletions(-)
lib/bb/ui/crumbs/builder.py +2 -1
index 2984490..7b6c116 100755
@@ -138,6 +138,7 @@ class Parameters:
         self.runnable_image_types = params["runnable_image_types"].split()
         self.runnable_machine_patterns = params["runnable_machine_patterns"].split()
         self.deployable_image_types = params["deployable_image_types"].split()
+        self.tmpdir = params["tmpdir"]
 
 class Builder(gtk.Window):
 
@@ -813,7 +814,7 @@ class Builder(gtk.Window):
 
         if response == gtk.RESPONSE_YES:
             source_env_path = os.path.join(self.parameters.core_base, "oe-init-build-env")
-            tmp_path = os.path.join(os.getcwd(), "tmp")
+            tmp_path = self.parameters.tmpdir
             if os.path.exists(image_path) and os.path.exists(kernel_path) \
                and os.path.exists(source_env_path) and os.path.exists(tmp_path):
                 cmdline = "/usr/bin/xterm -e "
lib/bb/ui/crumbs/hobeventhandler.py +1 -0
index e342811..8042fbd 100644
@@ -439,4 +439,5 @@ class HobHandler(gobject.GObject):
         params["runnable_image_types"] = self.server.runCommand(["getVariable", "RUNNABLE_IMAGE_TYPES"]) or ""
         params["runnable_machine_patterns"] = self.server.runCommand(["getVariable", "RUNNABLE_MACHINE_PATTERNS"]) or ""
         params["deployable_image_types"] = self.server.runCommand(["getVariable", "DEPLOYABLE_IMAGE_TYPES"]) or ""
+        params["tmpdir"] = self.server.runCommand(["getVariable", "TMPDIR"]) or ""
         return params
Signature · 1 line
1.7.4.1
#10 lore raw
In reply to Dongxiao Xu
Quoted 19 lines · Dongxiao Xu

Hi Richard,

This is the third pull request for Hob bug fixes, please help to review and pull.

Changes from v2:
1) Change the logic in set_distro(), that is, if defaultsetup is selected in Hob advanced setting dialog, we should leave DISTRO variable not set in bitbake server.
2) Add a new patch to avoid hardcode TMPDIR when executing runqemu.

Thanks,
Dongxiao

The following changes since commit 0348ef08db9ac425d83126d2e6eb465adc28b110:

Hob: Change the descriptions for view_recipe_button and view_package_button (2012-03-23 16:09:35 +0000)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dxu4/hob-bugfix
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/hob-bugfix

Quoted 10 lines

Dongxiao Xu (9):
Hob: Remove unnecessary PARSE_BBFILES command
Hob: Cleanup for hobeventhandler.py
Hob: Initial an empty label in recipeselectionpage.py
Hob: Change the Hob initialization process
Hob: Fix the workaround to get image types
Hob: Add a supported image type "vmdk"
Hob: runqemu and deployment functionality filter
Hob: Set empty DISTRO if "defaultsetup" is selected
Hob: Avoid getting TMPDIR in hardcode

Merged to master, thanks.

I do have some concerns around the "runqemu and deployment functionality filter" in that I'd prefer it if we treated the RUNNABLE_MACHINE_PATTERNS as a proper regexp and matched it against MACHINE rather than the image name. I'd prefer to see if behave like COMPATIBLE_MACHINE for example.

This is a detail we can fix in subsequent patches though.

Cheers,

Richard

#11 lore raw
Quoted 31 lines · Richard Purdie
Quoted 19 lines · Dongxiao Xu

Hi Richard,

This is the third pull request for Hob bug fixes, please help to review and pull.

Changes from v2:
1) Change the logic in set_distro(), that is, if defaultsetup is selected in Hob advanced setting dialog, we should leave DISTRO variable not set in bitbake server.
2) Add a new patch to avoid hardcode TMPDIR when executing runqemu.

Thanks,
Dongxiao

The following changes since commit 0348ef08db9ac425d83126d2e6eb465adc28b110:

Hob: Change the descriptions for view_recipe_button and view_package_button (2012-03-23 16:09:35 +0000)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dxu4/hob-bugfix
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/hob-bugfix

Quoted 10 lines

Dongxiao Xu (9):
Hob: Remove unnecessary PARSE_BBFILES command
Hob: Cleanup for hobeventhandler.py
Hob: Initial an empty label in recipeselectionpage.py
Hob: Change the Hob initialization process
Hob: Fix the workaround to get image types
Hob: Add a supported image type "vmdk"
Hob: runqemu and deployment functionality filter
Hob: Set empty DISTRO if "defaultsetup" is selected
Hob: Avoid getting TMPDIR in hardcode

Quoted 7 lines

Merged to master, thanks.

I do have some concerns around the "runqemu and deployment functionality filter" in that I'd prefer it if we treated the RUNNABLE_MACHINE_PATTERNS as a proper regexp and matched it against MACHINE rather than the image name. I'd prefer to see if behave like COMPATIBLE_MACHINE for example.

We can change the RUNNABLE_MACHINE_PATTERNS to be regexp style, but maybe we still need to match it with image name, since we will have two ways to access to the image details page:
1) Through a normal build, where we are able to get the MACHINE variable.
2) Through clicking "My images" button and load an already built image, from which we could not get the MACHINE variable but only image name.

BTW, to implement the filter functionality, we still have a pending patch for OE-Core that is not in master yet, see:

http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=dxu4/hob-bugfix-oecore&id=10968f8c0cf425011983ef7e0fe4c14b7da5ef74

Thanks,
Dongxiao

Quoted 7 lines

This is a detail we can fix in subsequent patches though.

Cheers,

Richard

#12 lore raw
Quoted 40 lines · Dongxiao
Quoted 31 lines · Richard Purdie
Quoted 19 lines · Dongxiao Xu

Hi Richard,

This is the third pull request for Hob bug fixes, please help to review and pull.

Changes from v2:
1) Change the logic in set_distro(), that is, if defaultsetup is selected in Hob advanced setting dialog, we should leave DISTRO variable not set in bitbake server.
2) Add a new patch to avoid hardcode TMPDIR when executing runqemu.

Thanks,
Dongxiao

The following changes since commit 0348ef08db9ac425d83126d2e6eb465adc28b110:

Hob: Change the descriptions for view_recipe_button and view_package_button (2012-03-23 16:09:35 +0000)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dxu4/hob-bugfix
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/hob-bugfix

Quoted 10 lines

Dongxiao Xu (9):
Hob: Remove unnecessary PARSE_BBFILES command
Hob: Cleanup for hobeventhandler.py
Hob: Initial an empty label in recipeselectionpage.py
Hob: Change the Hob initialization process
Hob: Fix the workaround to get image types
Hob: Add a supported image type "vmdk"
Hob: runqemu and deployment functionality filter
Hob: Set empty DISTRO if "defaultsetup" is selected
Hob: Avoid getting TMPDIR in hardcode

Quoted 7 lines

Merged to master, thanks.

I do have some concerns around the "runqemu and deployment functionality filter" in that I'd prefer it if we treated the RUNNABLE_MACHINE_PATTERNS as a proper regexp and matched it against MACHINE rather than the image name. I'd prefer to see if behave like COMPATIBLE_MACHINE for example.

Quoted 7 lines

We can change the RUNNABLE_MACHINE_PATTERNS to be regexp style, but maybe we still need to match it with image name, since we will have two ways to access to the image details page:
1) Through a normal build, where we are able to get the MACHINE variable.
2) Through clicking "My images" button and load an already built image, from which we could not get the MACHINE variable but only image name.

Ok, that is a good point, thanks.

Can we reliably extract the machine name from the image name? I'm thinking if regexps are involved they could use the start/end markers (^ $) which could get confusing if its matching the whole image name...

Quoted 4 lines

BTW, to implement the filter functionality, we still have a pending patch for OE-Core that is not in master yet, see:

http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=dxu4/hob-bugfix-oecore&id=10968f8c0cf425011983ef7e0fe4c14b7da5ef74

That is on my to merge list, thanks.

Richard

#13 lore raw
Quoted 49 lines · Richard Purdie
Quoted 40 lines · Dongxiao
Quoted 31 lines · Richard Purdie
Quoted 19 lines · Dongxiao Xu

Hi Richard,

This is the third pull request for Hob bug fixes, please help to review and pull.

Changes from v2:
1) Change the logic in set_distro(), that is, if defaultsetup is selected in Hob advanced setting dialog, we should leave DISTRO variable not set in bitbake server.
2) Add a new patch to avoid hardcode TMPDIR when executing runqemu.

Thanks,
Dongxiao

The following changes since commit 0348ef08db9ac425d83126d2e6eb465adc28b110:

Hob: Change the descriptions for view_recipe_button and view_package_button (2012-03-23 16:09:35 +0000)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dxu4/hob-bugfix
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dxu4/hob-bugfix

Quoted 10 lines

Dongxiao Xu (9):
Hob: Remove unnecessary PARSE_BBFILES command
Hob: Cleanup for hobeventhandler.py
Hob: Initial an empty label in recipeselectionpage.py
Hob: Change the Hob initialization process
Hob: Fix the workaround to get image types
Hob: Add a supported image type "vmdk"
Hob: runqemu and deployment functionality filter
Hob: Set empty DISTRO if "defaultsetup" is selected
Hob: Avoid getting TMPDIR in hardcode

Quoted 7 lines

Merged to master, thanks.

I do have some concerns around the "runqemu and deployment functionality filter" in that I'd prefer it if we treated the RUNNABLE_MACHINE_PATTERNS as a proper regexp and matched it against MACHINE rather than the image name. I'd prefer to see if behave like COMPATIBLE_MACHINE for example.

Quoted 7 lines

We can change the RUNNABLE_MACHINE_PATTERNS to be regexp style, but maybe we still need to match it with image name, since we will have two ways to access to the image details page:
1) Through a normal build, where we are able to get the MACHINE variable.
2) Through clicking "My images" button and load an already built image, from which we could not get the MACHINE variable but only image name.

Quoted 5 lines

Ok, that is a good point, thanks.

Can we reliably extract the machine name from the image name? I'm thinking if regexps are involved they could use the start/end markers (^ $) which could get confusing if its matching the whole image name...

That makes sense, and it is also what I am going to change for the current code.

Quoted 7 lines
Quoted 5 lines

BTW, to implement the filter functionality, we still have a pending patch for OE-Core that is not in master yet, see:

http://git.yoctoproject.org/cgit/cgit.cgi/poky-contrib/commit/?h=dxu4/hob-bugfix-oecore&id=10968f8c0cf425011983ef7e0fe4c14b7da5ef74

That is on my to merge list, thanks.

Thanks,
Dongxiao

Quoted 3 lines

Richard