hob: remove meta-hob layer
cover hob: remove meta-hob layer
Meta-hob layer contains only a hob-toolchain (a basic toolchain) and a hob-image.bb (an image with a single line: inherit image). Instead of hob-toolchain I've used meta-toolchain, and for hob-image.bb, I have created one in build dir. The custom images saved in this layer will now be placed into build dir.
Cristiana Voicu (5):
hob: replace hob-toolchain with meta-toolchain
hob: create a base hob image used to create custom images
hob: remove the rest of meta-hob
hob: remove the code that adds hob layer to bblayers
hob: append bbfiles to bblayers.conf instead of local.conf
bitbake/lib/bb/ui/crumbs/builder.py | 5 +++-- bitbake/lib/bb/ui/crumbs/hobeventhandler.py | 16 +++++++++------- bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py | 2 +- bitbake/lib/bb/ui/crumbs/imagedetailspage.py | 2 +- meta-hob/COPYING.MIT | 17 ----------------- meta-hob/conf/layer.conf | 15 --------------- meta-hob/recipes-core/images/hob-image.bb | 1 - meta-hob/recipes-core/meta/hob-toolchain.bb | 9 --------- 8 files changed, 14 insertions(+), 53 deletions(-) delete mode 100644 meta-hob/COPYING.MIT delete mode 100644 meta-hob/conf/layer.conf delete mode 100644 meta-hob/recipes-core/images/hob-image.bb delete mode 100644 meta-hob/recipes-core/meta/hob-toolchain.bb
Signature · 1 line
1.7.9.5
PATCH 1/5 hob: replace hob-toolchain with meta-toolchain
In order to remove meta-hob, hob-toolchain was removed. In hob, it was replaced with meta-toolchain.
--- bitbake/lib/bb/ui/crumbs/builder.py | 2 +- meta-hob/recipes-core/meta/hob-toolchain.bb | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) delete mode 100644 meta-hob/recipes-core/meta/hob-toolchain.bb
bitbake/lib/bb/ui/crumbs/builder.py +1 -1
@@ -374,7 +374,7 @@ class Builder(gtk.Window): super(Builder, self).__init__() self.hob_image = "hob-image" - self.hob_toolchain = "hob-toolchain" + self.hob_toolchain = "meta-toolchain" # handler self.handler = hobHandler
meta-hob/recipes-core/meta/hob-toolchain.bb deleted +0 -9
@@ -1,9 +0,0 @@ -DESCRIPTION = "dummy toolchain" -LICENSE = "MIT" - -PR = "r0" - -LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \ - file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" - -inherit populate_sdk
Signature · 1 line
1.7.9.5
PATCH 2/5 hob: create a base hob image used to create custom images
In reply to Cristiana VoicuIn order to remove hob-image.bb from meta-hob, a hob-image.bb should be created somewhere in the build directory. I've saved it in build/recipes/images directory, and moved the templates to recipes/images/custom (here are those templates saved by the user).
The image is created when hob starts. Also it appends to BBFILES the directory where it is created.
Removed images directory from meta-hob.
--- bitbake/lib/bb/ui/crumbs/builder.py | 3 ++- bitbake/lib/bb/ui/crumbs/hobeventhandler.py | 9 ++++++++- bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py | 2 +- bitbake/lib/bb/ui/crumbs/imagedetailspage.py | 2 +- meta-hob/recipes-core/images/hob-image.bb | 1 - 5 files changed, 12 insertions(+), 5 deletions(-) delete mode 100644 meta-hob/recipes-core/images/hob-image.bb
bitbake/lib/bb/ui/crumbs/builder.py +2 -1
@@ -441,7 +441,8 @@ class Builder(gtk.Window): self.handler.connect("recipe-populated", self.handler_recipe_populated_cb) self.handler.connect("package-populated", self.handler_package_populated_cb) - self.handler.append_to_bbfiles("${TOPDIR}/recipes/images/*.bb") + self.handler.append_to_bbfiles("${TOPDIR}/recipes/images/custom/*.bb") + self.handler.generate_hob_base_image() self.initiate_new_build_async() signal.signal(signal.SIGINT, self.event_handle_SIGINT)
bitbake/lib/bb/ui/crumbs/hobeventhandler.py +8 -1
@@ -440,9 +440,16 @@ class HobHandler(gobject.GObject): self.run_next_command(self.GENERATE_IMAGE) def generate_new_image(self, image, base_image, package_queue, description): - base_image = self.runCommand(["matchFile", self.base_image + ".bb"]) + if base_image: + base_image = self.runCommand(["matchFile", self.base_image + ".bb"]) self.runCommand(["generateNewImage", image, base_image, package_queue, False, description]) + def generate_hob_base_image(self): + image_dir = self.get_topdir() + "/recipes/images/" + self.ensure_dir(image_dir) + self.generate_new_image(image_dir+"hob-image.bb", None, [], "") + self.append_to_bbfiles(image_dir + "*.bb") + def ensure_dir(self, directory): self.runCommand(["ensureDir", directory])
bitbake/lib/bb/ui/crumbs/imageconfigurationpage.py +1 -1
@@ -378,7 +378,7 @@ class ImageConfigurationPage (HobPage): selected_image = self.image_combo.get_active_text() if selected_image == self.__custom_image__: topdir = self.builder.get_topdir() - images_dir = topdir + "/recipes/images/" + images_dir = topdir + "/recipes/images/custom/" self.builder.ensure_dir(images_dir) dialog = RetrieveImageDialog(images_dir, "Select from my image recipes",
bitbake/lib/bb/ui/crumbs/imagedetailspage.py +1 -1
@@ -632,7 +632,7 @@ class ImageDetailsPage (HobPage): def save_button_clicked_cb(self, button): topdir = self.builder.get_topdir() - images_dir = topdir + "/recipes/images/" + images_dir = topdir + "/recipes/images/custom/" self.builder.ensure_dir(images_dir) self.name_field_template = self.builder.image_configuration_page.custom_image_selected
meta-hob/recipes-core/images/hob-image.bb deleted +0 -1
@@ -1 +0,0 @@ -inherit image
Signature · 1 line
1.7.9.5
PATCH 3/5 hob: remove the rest of meta-hob
In reply to Cristiana Voicu--- meta-hob/COPYING.MIT | 17 ----------------- meta-hob/conf/layer.conf | 15 --------------- 2 files changed, 32 deletions(-) delete mode 100644 meta-hob/COPYING.MIT delete mode 100644 meta-hob/conf/layer.conf
meta-hob/COPYING.MIT deleted +0 -17
@@ -1,17 +0,0 @@ -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE.
meta-hob/conf/layer.conf deleted +0 -15
@@ -1,15 +0,0 @@ -# We have a conf and classes directory, add to BBPATH -BBPATH .= ":${LAYERDIR}" - -# We have recipes-* directories, add to BBFILES -BBFILES += "${LAYERDIR}/recipes-*/*/*.bb" - -BBFILE_COLLECTIONS += "hob" -BBFILE_PATTERN_hob = "^${LAYERDIR}/" -BBFILE_PRIORITY_hob = "1" - -# This should only be incremented on significant changes that will -# cause compatibility issues with other layers -LAYERVERSION_hob = "1" - -LAYERDEPENDS_hob = "core"
Signature · 1 line
1.7.9.5
PATCH 4/5 hob: remove the code that adds hob layer to bblayers
In reply to Cristiana Voicu--- bitbake/lib/bb/ui/crumbs/hobeventhandler.py | 5 ----- 1 file changed, 5 deletions(-)
bitbake/lib/bb/ui/crumbs/hobeventhandler.py +0 -5
@@ -515,13 +515,8 @@ class HobHandler(gobject.GObject): # retrieve the parameters from bitbake params = {} params["core_base"] = self.runCommand(["getVariable", "COREBASE"]) or "" - hob_layer = params["core_base"] + "/meta-hob" params["layer"] = self.runCommand(["getVariable", "BBLAYERS"]) or "" params["layers_non_removable"] = self.runCommand(["getVariable", "BBLAYERS_NON_REMOVABLE"]) or "" - if hob_layer not in params["layer"].split(): - params["layer"] += (" " + hob_layer) - if hob_layer not in params["layers_non_removable"].split(): - params["layers_non_removable"] += (" " + hob_layer) params["dldir"] = self.runCommand(["getVariable", "DL_DIR"]) or "" params["machine"] = self.runCommand(["getVariable", "MACHINE"]) or "" params["distro"] = self.runCommand(["getVariable", "DISTRO"]) or "defaultsetup"
Signature · 1 line
1.7.9.5
PATCH 5/5 hob: append bbfiles to bblayers.conf instead of local.conf
In reply to Cristiana Voicu--- bitbake/lib/bb/ui/crumbs/hobeventhandler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
bitbake/lib/bb/ui/crumbs/hobeventhandler.py +1 -1
@@ -509,7 +509,7 @@ class HobHandler(gobject.GObject): bbfiles = self.runCommand(["getVariable", "BBFILES", "False"]) or "" bbfiles = bbfiles.split() if val not in bbfiles: - self.append_var_in_file("BBFILES", val, "local.conf") + self.append_var_in_file("BBFILES", val, "bblayers.conf") def get_parameters(self): # retrieve the parameters from bitbake
Signature · 1 line
1.7.9.5