Commit Graph

9 Commits

Author SHA1 Message Date
Ross Burton
9c032d3dd9 bitbake: layerindex: don't use shell=True when cloning
(Bitbake rev: cb4aab7406dc8aefb646b37330b722cf9060ad73)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-11-23 16:10:37 +00:00
Mark Hatle
cbf41cbe55 bitbake: bitbake-layers: disable parsing for layerindex commands
These don't need to access recipe information, so let's not waste the
user's time parsing all recipes.

(Bitbake rev: 6a242a399ae93393c3fc60eda541c1f8f77fed57)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-08-02 10:18:27 +01:00
Mark Hatle
ddfcda7ec3 bitbake: bblayers/layerindex.py: Switch to use the new layerindexlib class
Display changes:
The output will now include references to the layers that the user already
has on their system.  It does this by querying the cooker derived index.

The code that enables this behavior is labeled as 'TODO' currently.  As
part of the work we need to make a final determination if this is the
desired output.

Also changed the default branch to no longer define itself as 'master'.

When the user does NOT set a branch, the default is now the
'LAYERSERIES_CORENAMES', and if that doesn't exist 'master'.  This is
subtly different in behavior, but more consistent with user expectations.

(Bitbake rev: 478c4b5489943f756ae03d6b6d3b5d665cedbce0)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-08-02 10:18:27 +01:00
Mark Hatle
0dea950931 bitbake: bblayers/layerindex.py: Fix addition of layers
When a layer is added it needs to be in a list, otherwise the system will
error such as:

    Specified layer directory / doesn't contain a conf/layer.conf file

Additionally, instead of calling the add layer function over and over, it
is better to add all of the new content in one command.  Otherwise the
order is important as the system now checks if the layer can be added.  For
instance, trying to add meta-python:

   Layer                Required by          Git repository                                          Subdirectory
   ===================================================================================================================
   meta-python          -                    git://git.openembedded.org/meta-openembedded            meta-python
   meta-oe              meta-python          git://git.openembedded.org/meta-openembedded            meta-oe
   openembedded-core    meta-python          git://git.openembedded.org/openembedded-core            meta
   Adding layer "meta-python" (.../oe-core/meta-openembedded/meta-python) to conf/bblayers.conf
   ERROR: Layer 'meta-python' depends on layer 'openembedded-layer', but this layer is not enabled in your configuration

The system would try to add meta-python before the dependent meta-oe.  Adding
them both at the same time resolves this issue.

(Bitbake rev: 8aeaabf13db645f33495e00b82117327e153d70a)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2018-08-02 10:18:27 +01:00
Jeremy A. Puhlman
801188bbd9 bitbake: Add args.force to localargs before do_add_layer
Adding layer "meta-signing-key" to conf/bblayers.conf
Traceback (most recent call last):
  File "/local/build/project/build/poky/bitbake/bin/bitbake-layers",
line 103, in <module>
    ret = main()
  File "/local/build/project/build/poky/bitbake/bin/bitbake-layers",
line 96, in main
    return args.func(args)
  File
"/local/build/project/build/poky/bitbake/lib/bblayers/layerindex.py",
line 250, in do_layerindex_fetch
    self.do_add_layer(localargs)
  File
"/local/build/project/build/poky/bitbake/lib/bblayers/action.py", line
44, in do_add_layer
    if not (args.force or notadded):
AttributeError: 'Namespace' object has no attribute 'force'

(Bitbake rev: 4325f7a7df67eaf4b51af03b453e84bf88fae408)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-10-07 23:20:41 +01:00
Paul Eggleton
1485a5517a bitbake: bitbake-layers: fix layerindex-fetch for Python 3
The data we read from an HTTPConnection comes in the form of bytes, but
we need it as a string, so in Python 3 we need to decode it (missed in
the Python 3 migration).

(Bitbake rev: 7e6a3cd1472e1a1c8304b46611e1676914a68b59)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-22 11:35:22 +00:00
Joshua Lock
1fce7ecbbb bitbake: bitbake: remove True option to getVar calls
getVar() now defaults to expanding by default, thus remove the True
option from getVar() calls with a regex search and replace.

Search made with the following regex: getVar ?\(( ?[^,()]*), True\)

(Bitbake rev: 3b45c479de8640f92dd1d9f147b02e1eecfaadc8)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-11-30 15:48:09 +00:00
Richard Purdie
0f2c59367a bitbake: bitbake: Convert to python 3
Various misc changes to convert bitbake to python3 which don't warrant
separation into separate commits.

(Bitbake rev: d0f904d407f57998419bd9c305ce53e5eaa36b24)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-06-02 08:24:02 +01:00
Christopher Larson
6bbe4fe48c bitbake: bitbake-layers: convert to plugin-based
This uses bb.utils.load_plugins, based on the plugin handling in recipetool
and devtool in oe-core.

(Bitbake rev: 5e542df9b966a99b5a5b8aa7cf6100174aff54b2)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-17 21:16:35 +01:00