diff options
author | Adrian Freihofer <adrian.freihofer@gmail.com> | 2024-02-08 09:27:32 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-02-08 23:14:51 +0000 |
commit | 5206056589ca6b0671b0009393f526828e2c665a (patch) | |
tree | ffa8d150b44bdad472fb8ab3a1ea2d80c893dab3 /meta/lib/oeqa | |
parent | f58aedff022e5ddd7c9855e3fa4e71040fd5ab1e (diff) | |
download | poky-5206056589ca6b0671b0009393f526828e2c665a.tar.gz |
oeqa/selftest/recipetool: fix for python 3.12
test_recipetool_create_github and test_recipetool_create_github_tarball
fail because the old meson version used by these tests cases does not
run on Python 3.12. The issue is in the dependencies.py which comes with
meson:
ERROR: build/tmp/work/recipetool-3z4osyl7/source/git/mesonbuild/
dependencies.py:777: SyntaxWarning: invalid escape sequence '\.'
Use meson 1.3.1 (what is currently also used on master) as a reference
for these tests.
With this version of meson, recipetool creates recipes named
meson_git.bb or meson_1.3.1.bb. Since this looks more reasonable than
e.g. python3-meson_git.bb the test gets adapted.
(From OE-Core rev: 7374a8a2810a6cf027bfefefe87691a3529123ff)
Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa')
-rw-r--r-- | meta/lib/oeqa/selftest/cases/recipetool.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/meta/lib/oeqa/selftest/cases/recipetool.py b/meta/lib/oeqa/selftest/cases/recipetool.py index 0c296875b2..39114c6762 100644 --- a/meta/lib/oeqa/selftest/cases/recipetool.py +++ b/meta/lib/oeqa/selftest/cases/recipetool.py | |||
@@ -444,14 +444,14 @@ class RecipetoolCreateTests(RecipetoolBase): | |||
444 | # Basic test to see if github URL mangling works | 444 | # Basic test to see if github URL mangling works |
445 | temprecipe = os.path.join(self.tempdir, 'recipe') | 445 | temprecipe = os.path.join(self.tempdir, 'recipe') |
446 | os.makedirs(temprecipe) | 446 | os.makedirs(temprecipe) |
447 | recipefile = os.path.join(temprecipe, 'python3-meson_git.bb') | 447 | recipefile = os.path.join(temprecipe, 'meson_git.bb') |
448 | srcuri = 'https://github.com/mesonbuild/meson;rev=0.32.0' | 448 | srcuri = 'https://github.com/mesonbuild/meson;rev=1.3.1' |
449 | result = runCmd(['recipetool', 'create', '-o', temprecipe, srcuri]) | 449 | result = runCmd(['recipetool', 'create', '-o', temprecipe, srcuri]) |
450 | self.assertTrue(os.path.isfile(recipefile)) | 450 | self.assertTrue(os.path.isfile(recipefile)) |
451 | checkvars = {} | 451 | checkvars = {} |
452 | checkvars['LICENSE'] = set(['Apache-2.0']) | 452 | checkvars['LICENSE'] = set(['Apache-2.0', 'Proprietary', 'Unknown']) |
453 | checkvars['SRC_URI'] = 'git://github.com/mesonbuild/meson;protocol=https;branch=master' | 453 | checkvars['SRC_URI'] = 'git://github.com/mesonbuild/meson;protocol=https;branch=1.3' |
454 | inherits = ['setuptools3'] | 454 | inherits = ['python_setuptools_build_meta'] |
455 | self._test_recipe_contents(recipefile, checkvars, inherits) | 455 | self._test_recipe_contents(recipefile, checkvars, inherits) |
456 | 456 | ||
457 | def test_recipetool_create_python3_setuptools(self): | 457 | def test_recipetool_create_python3_setuptools(self): |
@@ -703,15 +703,15 @@ class RecipetoolCreateTests(RecipetoolBase): | |||
703 | # Basic test to ensure github URL mangling doesn't apply to release tarballs | 703 | # Basic test to ensure github URL mangling doesn't apply to release tarballs |
704 | temprecipe = os.path.join(self.tempdir, 'recipe') | 704 | temprecipe = os.path.join(self.tempdir, 'recipe') |
705 | os.makedirs(temprecipe) | 705 | os.makedirs(temprecipe) |
706 | pv = '0.32.0' | 706 | pv = '1.3.1' |
707 | recipefile = os.path.join(temprecipe, 'python3-meson_%s.bb' % pv) | 707 | recipefile = os.path.join(temprecipe, 'meson_%s.bb' % pv) |
708 | srcuri = 'https://github.com/mesonbuild/meson/releases/download/%s/meson-%s.tar.gz' % (pv, pv) | 708 | srcuri = 'https://github.com/mesonbuild/meson/releases/download/%s/meson-%s.tar.gz' % (pv, pv) |
709 | result = runCmd('recipetool create -o %s %s' % (temprecipe, srcuri)) | 709 | result = runCmd('recipetool create -o %s %s' % (temprecipe, srcuri)) |
710 | self.assertTrue(os.path.isfile(recipefile)) | 710 | self.assertTrue(os.path.isfile(recipefile)) |
711 | checkvars = {} | 711 | checkvars = {} |
712 | checkvars['LICENSE'] = set(['Apache-2.0']) | 712 | checkvars['LICENSE'] = set(['Apache-2.0', 'Proprietary', 'Unknown']) |
713 | checkvars['SRC_URI'] = 'https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${PV}.tar.gz' | 713 | checkvars['SRC_URI'] = 'https://github.com/mesonbuild/meson/releases/download/${PV}/meson-${PV}.tar.gz' |
714 | inherits = ['setuptools3'] | 714 | inherits = ['python_setuptools_build_meta'] |
715 | self._test_recipe_contents(recipefile, checkvars, inherits) | 715 | self._test_recipe_contents(recipefile, checkvars, inherits) |
716 | 716 | ||
717 | def _test_recipetool_create_git(self, srcuri, branch=None): | 717 | def _test_recipetool_create_git(self, srcuri, branch=None): |