mirror of
https://git.yoctoproject.org/poky
synced 2026-05-09 05:29:32 +00:00
package_rpm: Do not replace square brackets in %files
This reverts commit f95adb749619e70920c6cc6cd01c6d02cd348fd8. At some point RPM stopped treating "[]?" characters in quoted text as a glob This causes rpmbuild error [1] in oe-core if package contains filenames with such characters [Yocto #13746]. Reverting commit which replaces "[]" with "?" fixes the issue. It should be safe now becuase rpm tries to use filename directly if not found by glob [2]. [1] | error: File not found: /mnt/builds/yocto/build/build/tmp/work/core2-64-poky-linux/testrpm/0.0.1-r0/package/42 All-Time Classics (E) ?v1.1?.cht | File not found: /mnt/builds/yocto/build/build/tmp/work/core2-64-poky-linux/testrpm/0.0.1-r0/package/42 All-Time Classics (E) ?v1.1?.cht | [2] https://github.com/rpm-software-management/rpm/commit/c16c70cbd6b31cd93541d5c22d23ba98d212ad3d (From OE-Core rev: 9916212b4810280108107d94cd2c0cd3e07ae6ed) Signed-off-by: Pavel Zhukov <pavel.zhukov@huawei.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
f2fb3c54a3
commit
48124db7ca
@@ -199,8 +199,6 @@ python write_specfile () {
|
|||||||
if path.endswith("DEBIAN") or path.endswith("CONTROL"):
|
if path.endswith("DEBIAN") or path.endswith("CONTROL"):
|
||||||
continue
|
continue
|
||||||
path = path.replace("%", "%%%%%%%%")
|
path = path.replace("%", "%%%%%%%%")
|
||||||
path = path.replace("[", "?")
|
|
||||||
path = path.replace("]", "?")
|
|
||||||
|
|
||||||
# Treat all symlinks to directories as normal files.
|
# Treat all symlinks to directories as normal files.
|
||||||
# os.walk() lists them as directories.
|
# os.walk() lists them as directories.
|
||||||
@@ -220,8 +218,6 @@ python write_specfile () {
|
|||||||
if dir == "CONTROL" or dir == "DEBIAN":
|
if dir == "CONTROL" or dir == "DEBIAN":
|
||||||
continue
|
continue
|
||||||
dir = dir.replace("%", "%%%%%%%%")
|
dir = dir.replace("%", "%%%%%%%%")
|
||||||
dir = dir.replace("[", "?")
|
|
||||||
dir = dir.replace("]", "?")
|
|
||||||
# All packages own the directories their files are in...
|
# All packages own the directories their files are in...
|
||||||
target.append('%dir "' + path + '/' + dir + '"')
|
target.append('%dir "' + path + '/' + dir + '"')
|
||||||
else:
|
else:
|
||||||
@@ -236,8 +232,6 @@ python write_specfile () {
|
|||||||
if file == "CONTROL" or file == "DEBIAN":
|
if file == "CONTROL" or file == "DEBIAN":
|
||||||
continue
|
continue
|
||||||
file = file.replace("%", "%%%%%%%%")
|
file = file.replace("%", "%%%%%%%%")
|
||||||
file = file.replace("[", "?")
|
|
||||||
file = file.replace("]", "?")
|
|
||||||
if conffiles.count(path + '/' + file):
|
if conffiles.count(path + '/' + file):
|
||||||
target.append('%config "' + path + '/' + file + '"')
|
target.append('%config "' + path + '/' + file + '"')
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user