mirror of
https://git.yoctoproject.org/poky
synced 2026-05-09 05:29:32 +00:00
lib: package: Add file_reverse_translate
Adds API to reverse the removal of special characters from file names so it can be correctly done in multiple places without open-coding it. Replace the translation done in the package_rpm.bbclass with the new API (From OE-Core rev: 4cb7e93c624987d146aaf626ce8e99568e938a70) Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
af6d28d2b0
commit
242be0888c
@@ -38,6 +38,7 @@ def filter_nativesdk_deps(srcname, var):
|
||||
|
||||
# Construct per file dependencies file
|
||||
def write_rpm_perfiledata(srcname, d):
|
||||
import oe.package
|
||||
workdir = d.getVar('WORKDIR')
|
||||
packages = d.getVar('PACKAGES')
|
||||
pkgd = d.getVar('PKGD')
|
||||
@@ -53,12 +54,7 @@ def write_rpm_perfiledata(srcname, d):
|
||||
key = "FILE" + varname + ":" + dfile + ":" + pkg
|
||||
deps = filter_nativesdk_deps(srcname, d.getVar(key) or "")
|
||||
depends_dict = bb.utils.explode_dep_versions(deps)
|
||||
file = dfile.replace("@underscore@", "_")
|
||||
file = file.replace("@closebrace@", "]")
|
||||
file = file.replace("@openbrace@", "[")
|
||||
file = file.replace("@tab@", "\t")
|
||||
file = file.replace("@space@", " ")
|
||||
file = file.replace("@at@", "@")
|
||||
file = oe.package.file_reverse_translate(dfile)
|
||||
outfile.write('"' + pkgd + file + '" : "')
|
||||
for dep in depends_dict:
|
||||
ver = depends_dict[dep]
|
||||
|
||||
Reference in New Issue
Block a user