From 21917a63abd74039dead6006cd3ef3d29915d530 Mon Sep 17 00:00:00 2001 From: Adrian Freihofer Date: Sun, 22 Sep 2024 17:43:14 +0200 Subject: devtool: drop S = WORKDIR workaround Dropping support for S = WORKDIR allows to drop this ugly workaround. With S = WORKDIR it was possible to refer to a file via oe-local-files symlink or via direct file path. Ensuring the pseudo database is consistent for both paths was extra complicated and required this bad function. Really nice to drop it now! (From OE-Core rev: 2b799fdf267f44c26797593984d9828c4fd0fd31) Signed-off-by: Adrian Freihofer Signed-off-by: Richard Purdie --- scripts/lib/devtool/ide_sdk.py | 38 -------------------------------------- 1 file changed, 38 deletions(-) (limited to 'scripts/lib/devtool/ide_sdk.py') diff --git a/scripts/lib/devtool/ide_sdk.py b/scripts/lib/devtool/ide_sdk.py index 65873b088d..350a8b02ca 100755 --- a/scripts/lib/devtool/ide_sdk.py +++ b/scripts/lib/devtool/ide_sdk.py @@ -712,42 +712,6 @@ class RecipeModified: binaries.append(abs_name[d_len:]) return sorted(binaries) - def gen_delete_package_dirs(self): - """delete folders of package tasks - - This is a workaround for and issue with recipes having their sources - downloaded as file:// - This likely breaks pseudo like: - path mismatch [3 links]: ino 79147802 db - .../build/tmp/.../cmake-example/1.0/package/usr/src/debug/ - cmake-example/1.0-r0/oe-local-files/cpp-example-lib.cpp - .../build/workspace/sources/cmake-example/oe-local-files/cpp-example-lib.cpp - Since the files are anyway outdated lets deleted them (also from pseudo's db) to workaround this issue. - """ - cmd_lines = ['#!/bin/sh'] - - # Set up the appropriate environment - newenv = dict(os.environ) - for varvalue in self.fakerootenv.split(): - if '=' in varvalue: - splitval = varvalue.split('=', 1) - newenv[splitval[0]] = splitval[1] - - # Replicate the environment variables from bitbake - for var, val in newenv.items(): - if not RecipeModified.is_valid_shell_variable(var): - continue - cmd_lines.append('%s="%s"' % (var, val)) - cmd_lines.append('export %s' % var) - - # Delete the folders - pkg_dirs = ' '.join([os.path.join(self.workdir, d) for d in [ - "package", "packages-split", "pkgdata", "sstate-install-package", "debugsources.list", "*.spec"]]) - cmd = "%s rm -rf %s" % (self.fakerootcmd, pkg_dirs) - cmd_lines.append('%s || { "%s failed"; exit 1; }' % (cmd, cmd)) - - return self.write_script(cmd_lines, 'delete_package_dirs') - def gen_deploy_target_script(self, args): """Generate a script which does what devtool deploy-target does @@ -785,8 +749,6 @@ class RecipeModified: """Generate a script which does install and deploy""" cmd_lines = ['#!/bin/bash'] - cmd_lines.append(self.gen_delete_package_dirs()) - # . oe-init-build-env $BUILDDIR # Note: Sourcing scripts with arguments requires bash cmd_lines.append('cd "%s" || { echo "cd %s failed"; exit 1; }' % ( -- cgit v1.2.3-54-g00ecf