summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2016-11-16 09:05:45 +1300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-11-23 11:10:14 +0000
commit6e182aaa760c3be689e694e06d9ed0f4b66b1497 (patch)
treede39966cc2e8e85d67368af4a017eaf529961855 /meta
parentf001c6608644a1353cab95e7642162913b90cd35 (diff)
downloadpoky-6e182aaa760c3be689e694e06d9ed0f4b66b1497.tar.gz
devtool: modify: support recipes with only local files as source
The hello-mod recipe is unusual in that it has only local files in SRC_URI and builds these out of ${WORKDIR}. When you use devtool modify on it, devtool puts all of those files in an "oe-local-files" subdirectory of the source tree, which is not ${S} (or ${B}) any more and thus building the recipe afterwards fails. It's a bit of a hack, but symlink the files in oe-local-files into the source tree (and commit the symlinks with an ignored commit so that the repo is clean) to work around the problem. We only do this at time of extraction, so any files added to or removed from oe-local-files after that won't be handled, but I think there's a limit to how far we should go to support these kinds of recipes - ultimately they are anomalies. I initially tried a hacky workaround where I set effectively set B = "${WORKDIR}" and that allowed it to build, but other things such as the LIC_FILES_CHKSUM checks still broke because they expected to find files in ${S}. Another hack where I set the sourcetree to point to the oe-local-files subdirectory works for hello-mod but not for makedevs since whilst that is similar, unlike hello-mod it does in fact have files in the source tree (since it has a patch that adds COPYING) and thus the same issue occurred. Also tweak one of the tests that tries devtool modify / update-recipe on the makedevs recipe to try building it since that would have caught this issue. Fixes [YOCTO #10616]. (From OE-Core rev: 857c06d6a1d161bf5a01311d07758bd4241929a3) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/lib/oeqa/selftest/devtool.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/devtool.py b/meta/lib/oeqa/selftest/devtool.py
index 2a08721336..7db286fc15 100644
--- a/meta/lib/oeqa/selftest/devtool.py
+++ b/meta/lib/oeqa/selftest/devtool.py
@@ -874,6 +874,8 @@ class DevtoolTests(DevtoolBase):
874 result = runCmd('devtool modify %s -x %s' % (testrecipe, tempdir)) 874 result = runCmd('devtool modify %s -x %s' % (testrecipe, tempdir))
875 # Check git repo 875 # Check git repo
876 self._check_src_repo(tempdir) 876 self._check_src_repo(tempdir)
877 # Try building just to ensure we haven't broken that
878 bitbake("%s" % testrecipe)
877 # Edit / commit local source 879 # Edit / commit local source
878 runCmd('echo "/* Foobar */" >> oe-local-files/makedevs.c', cwd=tempdir) 880 runCmd('echo "/* Foobar */" >> oe-local-files/makedevs.c', cwd=tempdir)
879 runCmd('echo "Foo" > oe-local-files/new-local', cwd=tempdir) 881 runCmd('echo "Foo" > oe-local-files/new-local', cwd=tempdir)