1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-30 00:20:08 +00:00

recipetool/devtool: Ensure server knows about changed files

Bitbake has changed to require notification when metadata changes in the middle of tinfoil
sessions. Add the required function calls at the places metadata is changed.

(From OE-Core rev: e5574163ab49a8f51b2b34fd37acfd1cad9b7595)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Richard Purdie
2023-09-17 08:41:54 +01:00
parent 022deeb0ef
commit d4f2f8269c
5 changed files with 6 additions and 1 deletions
+1
View File
@@ -587,6 +587,7 @@ def _extract_source(srctree, keep_temp, devbranch, sync, config, basepath, works
preservestampfile = os.path.join(sstate_manifests, 'preserve-stamps') preservestampfile = os.path.join(sstate_manifests, 'preserve-stamps')
with open(preservestampfile, 'w') as f: with open(preservestampfile, 'w') as f:
f.write(d.getVar('STAMP')) f.write(d.getVar('STAMP'))
tinfoil.modified_files()
try: try:
if is_kernel_yocto: if is_kernel_yocto:
# We need to generate the kernel config # We need to generate the kernel config
+1
View File
@@ -429,6 +429,7 @@ def _create_new_recipe(newpv, md5, sha256, srcrev, srcbranch, srcsubdir_old, src
newvalues["LIC_FILES_CHKSUM"] = newlicchksum newvalues["LIC_FILES_CHKSUM"] = newlicchksum
_add_license_diff_to_recipe(fullpath, license_diff) _add_license_diff_to_recipe(fullpath, license_diff)
tinfoil.modified_files()
try: try:
rd = tinfoil.parse_recipe_file(fullpath, False) rd = tinfoil.parse_recipe_file(fullpath, False)
except bb.tinfoil.TinfoilCommandFailed as e: except bb.tinfoil.TinfoilCommandFailed as e:
+2 -1
View File
@@ -300,6 +300,7 @@ def appendfile(args):
perms = '0755' perms = '0755'
install = {args.newfile: (args.targetpath, perms)} install = {args.newfile: (args.targetpath, perms)}
oe.recipeutils.bbappend_recipe(rd, args.destlayer, {args.newfile: sourcepath}, install, wildcardver=args.wildcard_version, machine=args.machine) oe.recipeutils.bbappend_recipe(rd, args.destlayer, {args.newfile: sourcepath}, install, wildcardver=args.wildcard_version, machine=args.machine)
tinfoil.modified_files()
return 0 return 0
else: else:
if alternative_pns: if alternative_pns:
@@ -355,7 +356,7 @@ def appendsrc(args, files, rd, extralines=None):
copyfiles[newfile] = srcfile copyfiles[newfile] = srcfile
oe.recipeutils.bbappend_recipe(rd, args.destlayer, copyfiles, None, wildcardver=args.wildcard_version, machine=args.machine, extralines=extralines) oe.recipeutils.bbappend_recipe(rd, args.destlayer, copyfiles, None, wildcardver=args.wildcard_version, machine=args.machine, extralines=extralines)
tinfoil.modified_files()
def appendsrcfiles(parser, args): def appendsrcfiles(parser, args):
recipedata = _parse_recipe(args.recipe, tinfoil) recipedata = _parse_recipe(args.recipe, tinfoil)
+1
View File
@@ -901,6 +901,7 @@ def create_recipe(args):
f.write('%s\n' % line) f.write('%s\n' % line)
lastline = line lastline = line
log_info_cond('Recipe %s has been created; further editing may be required to make it fully functional' % outfile, args.devtool) log_info_cond('Recipe %s has been created; further editing may be required to make it fully functional' % outfile, args.devtool)
tinfoil.modified_files()
if tempsrc: if tempsrc:
if args.keep_temp: if args.keep_temp:
+1
View File
@@ -49,6 +49,7 @@ def setvar(args):
for patch in patches: for patch in patches:
for line in patch: for line in patch:
sys.stdout.write(line) sys.stdout.write(line)
tinfoil.modified_files()
return 0 return 0