diff options
author | Peter Kjellerstedt <peter.kjellerstedt@axis.com> | 2017-06-09 21:34:26 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-06-12 23:01:22 +0100 |
commit | d30591b496ea2d347b7ac4d9c0e080289e3fce87 (patch) | |
tree | 4a4a3262f9701ebaa05f29dc43ffcc76a74026db /meta/classes/insane.bbclass | |
parent | 985448c92d4e781b8c375655d03face7c6a62c47 (diff) | |
download | poky-d30591b496ea2d347b7ac4d9c0e080289e3fce87.tar.gz |
insane.bbclass: Improve the handling of runtime file dependencies
This makes the file-rdeps test support:
* versioned dependencies, e.g., "perl (>= 5.000)", and
* package dependencies among the file dependencies, e.g., "perl".
It also ignores all "perl(...)" dependencies since it is expected that
these are generated and handled by rpm itself and there is no reason
to second guess what it is doing.
(From OE-Core rev: 2cbeb6edbfcbd9378a5a79b17f7d31a49e0356ff)
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/insane.bbclass')
-rw-r--r-- | meta/classes/insane.bbclass | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass index 258856266e..fa932ef576 100644 --- a/meta/classes/insane.bbclass +++ b/meta/classes/insane.bbclass | |||
@@ -912,8 +912,9 @@ def package_qa_check_rdepends(pkg, pkgdest, skip, taskdeps, packages, d): | |||
912 | rdep_data = oe.packagedata.read_subpkgdata(pkg, d) | 912 | rdep_data = oe.packagedata.read_subpkgdata(pkg, d) |
913 | for key in rdep_data: | 913 | for key in rdep_data: |
914 | if key.startswith("FILERDEPENDS_"): | 914 | if key.startswith("FILERDEPENDS_"): |
915 | for subkey in rdep_data[key].split(): | 915 | for subkey in bb.utils.explode_deps(rdep_data[key]): |
916 | if subkey not in ignored_file_rdeps: | 916 | if subkey not in ignored_file_rdeps and \ |
917 | not subkey.startswith('perl('): | ||
917 | # We already know it starts with FILERDEPENDS_ | 918 | # We already know it starts with FILERDEPENDS_ |
918 | filerdepends[subkey] = key[13:] | 919 | filerdepends[subkey] = key[13:] |
919 | 920 | ||
@@ -928,11 +929,10 @@ def package_qa_check_rdepends(pkg, pkgdest, skip, taskdeps, packages, d): | |||
928 | sub_rdeps = rdep_data.get("RDEPENDS_" + rdep) | 929 | sub_rdeps = rdep_data.get("RDEPENDS_" + rdep) |
929 | if not sub_rdeps: | 930 | if not sub_rdeps: |
930 | continue | 931 | continue |
931 | for sub_rdep in sub_rdeps.split(): | 932 | for sub_rdep in bb.utils.explode_deps(sub_rdeps): |
932 | if sub_rdep in done: | 933 | if sub_rdep in done: |
933 | continue | 934 | continue |
934 | if not sub_rdep.startswith('(') and \ | 935 | if oe.packagedata.has_subpkgdata(sub_rdep, d): |
935 | oe.packagedata.has_subpkgdata(sub_rdep, d): | ||
936 | # It's a new rdep | 936 | # It's a new rdep |
937 | done.append(sub_rdep) | 937 | done.append(sub_rdep) |
938 | new.append(sub_rdep) | 938 | new.append(sub_rdep) |
@@ -950,11 +950,15 @@ def package_qa_check_rdepends(pkg, pkgdest, skip, taskdeps, packages, d): | |||
950 | filerdepends.pop("/usr/bin/python",None) | 950 | filerdepends.pop("/usr/bin/python",None) |
951 | done.remove(py) | 951 | done.remove(py) |
952 | for rdep in done: | 952 | for rdep in done: |
953 | # The file dependencies may contain package names, e.g., | ||
954 | # perl | ||
955 | filerdepends.pop(rdep,None) | ||
956 | |||
953 | # For Saving the FILERPROVIDES, RPROVIDES and FILES_INFO | 957 | # For Saving the FILERPROVIDES, RPROVIDES and FILES_INFO |
954 | rdep_data = oe.packagedata.read_subpkgdata(rdep, d) | 958 | rdep_data = oe.packagedata.read_subpkgdata(rdep, d) |
955 | for key in rdep_data: | 959 | for key in rdep_data: |
956 | if key.startswith("FILERPROVIDES_") or key.startswith("RPROVIDES_"): | 960 | if key.startswith("FILERPROVIDES_") or key.startswith("RPROVIDES_"): |
957 | for subkey in rdep_data[key].split(): | 961 | for subkey in bb.utils.explode_deps(rdep_data[key]): |
958 | filerdepends.pop(subkey,None) | 962 | filerdepends.pop(subkey,None) |
959 | # Add the files list to the rprovides | 963 | # Add the files list to the rprovides |
960 | if key == "FILES_INFO": | 964 | if key == "FILES_INFO": |