Commit Graph

17 Commits

Author SHA1 Message Date
Peter Kjellerstedt 254bfb1071 recipes: Make use of the new bb.utils.filter() function
(From OE-Core rev: 0a1427bf9aeeda6bee2cc0af8da4ea5fd90aef6f)

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-03-01 11:17:45 +00:00
Joshua Lock c4e2c59088 meta: 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\)

(From OE-Core rev: 7c552996597faaee2fbee185b250c0ee30ea3b5f)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-16 10:23:23 +00:00
Markus Lehtonen edc92ea8de python-smartpm: use md5 as the digest for rpm_sys channel
Use md5 sum instead of mtime as the "digest" method for rpm_sys channel.
The digest is used to determine if the channel has been updated. It was
found out that mtime was not a reliable digest. On some systems mtime
of the rpm db does not get updated after every transaction if transactions
(smart install / remove commands) are fired in quick succession. As a
consequence smartpm cache and rpm db get out of sync.

[YOCTO #10244]

(From OE-Core rev: e7267b4e78461e71a1175f93e2eb5e90272c2b47)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-09-14 22:22:13 +01:00
Ming Liu bba1b911c8 Use PYTHON_SITEPACKAGES_DIR insted of hard-coded *site-packages*
For thoese recipes that are inheriting python*-dir.bbclass, there is
already a PYTHON_SITEPACKAGES_DIR present, use that definition replacing
redundant "${libdir}/python*/site-packages".

(From OE-Core rev: e7d842673952aa4aaa141f64958bc1344dbe8210)

Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-17 10:35:42 +01:00
Mariano Lopez 909e2120d4 python-smartpm_git.bb: Add patch for debugging random errors
This will add a patch to debug random errors seen in the
autobuilders, it won't solve the errors, but will give us
a better idea of what is happening.

[YOCTO #8383]

(From OE-Core rev: c52a7e910a3a52a7455a2409d9ade449bbbd66d4)

Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-10 10:46:30 +01:00
mingli.yu@windriver.com f02f0edeaa python-smartpm: add support to check signatures
RPMv5 has removed support for _RPMVSF_NOSIGNATURES,
the flag can be replaced with a flags set:
"RPMVSF_NODSAHEADER|RPMVSF_NORSAHEADER|RPMVSF_NODSA
RPMVSF_NORSA"

(From OE-Core rev: 5c0c1b8a64643ad7130b17b5dfce9cecffa6d962)

Signed-off-by: Haiqing Bai <Haiqing.Bai@windriver.com>
Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-07-26 08:56:29 +01:00
Richard Purdie 66b484fbc6 python-smartpm: Avoid locale issue with bitbake python3
(From OE-Core rev: fa2ca7660e8f3279736624aa2493b4ca952ae466)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-22 16:11:12 +01:00
Klauer, Daniel e44c849769 python-smartpm: Remove unnecessary error reporting improvement patch
The error reporting improvements were merged upstream (smartpm 406541f569)
and refactored later (smartpm 20af0aac33), yet a part of the patch was
kept here (oe-core 5fc580fc44).

Due to the upstream refactoring the patch still applies cleanly, but it
isn't actually needed. The added changes are duplicate or dead code.

(From OE-Core rev: f1cfa9ab5d79198671275cea2c9864ce0cbcb9f0)

Signed-off-by: Daniel Klauer <daniel.klauer@gin.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:18 +01:00
Klauer, Daniel be0cabf816 python-smartpm: Don't ignore error if RPM transaction fails without problems
SmartPM could misinterpret RPM transaction error as success,
if ts.run() (RPM Python API) returns an empty problems list.

This could happen for example if the RPM database is partially corrupted
such that the transaction does not have any problems like conflicts or
missing dependencies, but still can't be committed.

The added patch fixes the problem in the upstream sources;
one of the existing patches has to be adjusted to still apply.

(From OE-Core rev: 1dc5f5d5c844585eec114be9480e0e4d8e60d09c)

Signed-off-by: Daniel Klauer <daniel.klauer@gin.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:18 +01:00
Klauer, Daniel e89c6c4aa6 python-smartpm: Fix channel command --remove-all option (again)
SmartPM's --remove-all option was unusable, because the fix from
commit 03266e89a6 was lost in commit 5fc580fc44. Thus, add a new
patch to fix --remove-all.

It seems like the previous fix was lost by mistake:
Upstream merged the *old* version of the patch (smartpm 406541f569),
and when SmartPM in oe-core was upgraded to the new upstream release,
the --remove-all fix from the *new* patch was not carried over.

(From OE-Core rev: ba2adda60dd34b6a8feba413e3207dd8e4580294)

Signed-off-by: Daniel Klauer <daniel.klauer@gin.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-05-19 09:05:18 +01:00
Joshua Lock 03fce7358d smartpm: remove rpm4 patch
The RPM4 support we added to SMART doesn't appear to work, remove
it as part of the removal of RPM4 from OE-Core.

Refresh the smart-add-for-rpm-ignoresize-check.patch which was
applied after smart-rpm4-fixes.patch and doesn't apply cleanly once
that patch is removed.

(From OE-Core rev: e1108fa41742e726aa578d0298fa6397b2663ff3)

Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-20 23:12:29 +00:00
Ross Burton 455ff32426 meta: more removals of redunant FILES_${PN}-dbg
In some recipes overly-split -dbg packages were merged into PN-dbg.  Unless
there's a very good reason, recipes should have a single -dev and -dbg package.

(From OE-Core rev: a3b000643898d7402b9e57c02e8d10e677cc9722)

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-12-16 11:56:30 +00:00
Robert Yang e788961cd8 smart:cache.py: getPackages() matches name + arch
It only matched name ony in the past, for example:
smart install busybox (matched)
but:
smart install busybox@core2_64 (didn't match)

The installation is very slow when no match since it would seach all the
packages in the repo, and what we use mostly in oe-core is the second
case, so the installation is very slow when install COMPLEMENTARY
packages such as the task do_populate_sdk.

This patch makes it match both.

* Speed up
  MACHINE = "qemux86-64"
  - When multilib enabled:
    $ bitbake core-image-sato -cpopulate_sdk
    time: 6m5s -> 2m34s (Reduce 57% )

    $ bitbake core-image-minimal -cpopulate_sdk
    time: 2m1s -> 1m26s (Reduce 28% )

    $ bitbake core-image-sato-sdk
    time: 10m15s -> 7m12s (Reduce 29% )

  - When multilib NOT enabled:
    $ bitbake core-image-sato -cpopulate_sdk
    time: 4m25s -> 2m28s (Reduce 44% )

[YOCTO #8389]

(From OE-Core rev: dae4149009be722943cc7deec7f03e87b77ea59b)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-10-01 15:07:49 +01:00
Kai Kang 363bec05e6 smartpm: set noprogress for pycurl
Set NOPROGRESS for pycurl just as same as default operation in pycurl
module itself. If set NOPROGRESS with 0 for pycurl, it causes dead lock
issue of Python GIL when call smart library by python gui just like
pygtk.

(From OE-Core rev: 0d1f99fe1446edfb8864cbbc5a8b0059391c9bbc)

Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-08-01 07:34:06 +01:00
Richard Purdie 350b73f240 python-smartpm: Improve warnings/errors consistency
Sadly, smart is not deterministic so the same build can go down multiple different
pathways. We'd expect to see the same warnings however depending on the pathway
taken, it may or may not warn, particularly with Recommends since they're optional.

For example, where a Recommended package is available but has Conflicts, we'd expect
to see an warning that we couldn't install it. Some code paths silently hide this
(its a LOCKED_CONFLICT). We add printing of warnings for this case.

Also, if there are two compatible feeds available (e.g. i586 and core2_32), this
changes the code path from direct _install() to _pending() since there are multiple
providers. This patch adds warning handling to _pending() so we don't hit hard
failures there. This is as seen with the mysterious libspeexdsp failures for x86-lsb
on the autobuilder.

(From OE-Core rev: ab1eb2432b9a9823335450fd12476e910a95a2aa)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-20 10:40:41 +01:00
Randy Witt 76993861a1 python-smartpm: Have native smart use nativepython
Currently when trying to use smart via devshell or in the bitbake
environment, it will fail without inheriting pythonnative. Since the
native tools should "just work" use nativepython in the shebang line for
smart.

(From OE-Core rev: 4d4d9e8aa68a185b330ffbdb2e084b31fa6a6451)

Signed-off-by: Randy Witt <randy.e.witt@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-12 22:55:46 +01:00
Robert Yang 05b02d27d2 python-smartpm: 1.4.1 -> 1.5
* Remove the following patches since the are already in the source:
smart-config-ignore-all-recommends.patch
smart-conflict-provider.patch
smart-dflags.patch
smart-filename-NAME_MAX.patch
smart-flag-exclude-packages.patch
smart-flag-ignore-recommends.patch
smart-metadata-match.patch
smart-multilib-fixes.patch
smart-rpm-extra-macros.patch
smart-rpm-md-parse.patch
smart-rpm-root.patch
smart-tmpdir.patch
smart-yaml-error.patch

* Update the following patches, part of the code are already in the
  source:
smart-attempt.patch
smart-improve-error-reporting.patch
smart-recommends.patch
smartpm-rpm5-nodig.patch

* Use github and git repo as the SRC_URI.

(From OE-Core rev: 5fc580fc444e45d00de0e50d32b6e6e0b2e6b7ea)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-07-09 18:00:18 +01:00