summaryrefslogtreecommitdiffstats
path: root/meta/classes/package.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2021-09-29 12:30:59 (GMT)
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-10-02 22:09:22 (GMT)
commita543230b342cfc900caeb2703a314b7cbbb2eacc (patch)
tree42c447455255f15c7c49d2f9730d97199caf32dd /meta/classes/package.bbclass
parentb6e74ba64ebc5d18e40fd01ef87ca3fde6f33249 (diff)
downloadpoky-a543230b342cfc900caeb2703a314b7cbbb2eacc.tar.gz
package: Ensure pclist files are deterministic and don't use full paths
Currently the pkgconfig pclist files contain full paths which are build host specific and the order of entries is not deterministic. Fix both these issues so the files are deterministic. (From OE-Core rev: e422e29bca4af3ab4073e04490f38b05cd7c38c0) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/package.bbclass')
-rw-r--r--meta/classes/package.bbclass6
1 files changed, 3 insertions, 3 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 460997a..985dfac 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -2112,12 +2112,12 @@ python package_do_pkgconfig () {
2112 for pkg in packages.split(): 2112 for pkg in packages.split():
2113 pkgconfig_provided[pkg] = [] 2113 pkgconfig_provided[pkg] = []
2114 pkgconfig_needed[pkg] = [] 2114 pkgconfig_needed[pkg] = []
2115 for file in pkgfiles[pkg]: 2115 for file in sorted(pkgfiles[pkg]):
2116 m = pc_re.match(file) 2116 m = pc_re.match(file)
2117 if m: 2117 if m:
2118 pd = bb.data.init() 2118 pd = bb.data.init()
2119 name = m.group(1) 2119 name = m.group(1)
2120 pkgconfig_provided[pkg].append(name) 2120 pkgconfig_provided[pkg].append(os.path.basename(name))
2121 if not os.access(file, os.R_OK): 2121 if not os.access(file, os.R_OK):
2122 continue 2122 continue
2123 with open(file, 'r') as f: 2123 with open(file, 'r') as f:
@@ -2140,7 +2140,7 @@ python package_do_pkgconfig () {
2140 pkgs_file = os.path.join(shlibswork_dir, pkg + ".pclist") 2140 pkgs_file = os.path.join(shlibswork_dir, pkg + ".pclist")
2141 if pkgconfig_provided[pkg] != []: 2141 if pkgconfig_provided[pkg] != []:
2142 with open(pkgs_file, 'w') as f: 2142 with open(pkgs_file, 'w') as f:
2143 for p in pkgconfig_provided[pkg]: 2143 for p in sorted(pkgconfig_provided[pkg]):
2144 f.write('%s\n' % p) 2144 f.write('%s\n' % p)
2145 2145
2146 # Go from least to most specific since the last one found wins 2146 # Go from least to most specific since the last one found wins