diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-01-14 15:50:51 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-01-16 15:35:07 +0000 |
| commit | e5455662a9762fc2cb8859134d855413d84fd265 (patch) | |
| tree | ad7c3c6b258415ab9b92ed4b04a1ce0c2f6c9eb7 /bitbake/lib/bb/parse/parse_py | |
| parent | ca4a8eea6284aad41ec67b375c2a7c7855b5fe11 (diff) | |
| download | poky-e5455662a9762fc2cb8859134d855413d84fd265.tar.gz | |
bitbake: bitbake: Fix Deprecated warnings from regexs
Fix handling of escape characters in regexs and hence fix python
Deprecation warnings which will be problematic in python 3.8.
(Bitbake rev: c1fcc46e2498ddd41425d8756754f814d682aba3)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/parse/parse_py')
| -rw-r--r-- | bitbake/lib/bb/parse/parse_py/BBHandler.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py index f3bf4aa529..9dba5f2334 100644 --- a/bitbake/lib/bb/parse/parse_py/BBHandler.py +++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py | |||
| @@ -38,15 +38,15 @@ from .ConfHandler import include, init | |||
| 38 | # For compatibility | 38 | # For compatibility |
| 39 | bb.deprecate_import(__name__, "bb.parse", ["vars_from_file"]) | 39 | bb.deprecate_import(__name__, "bb.parse", ["vars_from_file"]) |
| 40 | 40 | ||
| 41 | __func_start_regexp__ = re.compile( r"(((?P<py>python)|(?P<fr>fakeroot))\s*)*(?P<func>[\w\.\-\+\{\}\$]+)?\s*\(\s*\)\s*{$" ) | 41 | __func_start_regexp__ = re.compile(r"(((?P<py>python)|(?P<fr>fakeroot))\s*)*(?P<func>[\w\.\-\+\{\}\$]+)?\s*\(\s*\)\s*{$" ) |
| 42 | __inherit_regexp__ = re.compile( r"inherit\s+(.+)" ) | 42 | __inherit_regexp__ = re.compile(r"inherit\s+(.+)" ) |
| 43 | __export_func_regexp__ = re.compile( r"EXPORT_FUNCTIONS\s+(.+)" ) | 43 | __export_func_regexp__ = re.compile(r"EXPORT_FUNCTIONS\s+(.+)" ) |
| 44 | __addtask_regexp__ = re.compile("addtask\s+(?P<func>\w+)\s*((before\s*(?P<before>((.*(?=after))|(.*))))|(after\s*(?P<after>((.*(?=before))|(.*)))))*") | 44 | __addtask_regexp__ = re.compile(r"addtask\s+(?P<func>\w+)\s*((before\s*(?P<before>((.*(?=after))|(.*))))|(after\s*(?P<after>((.*(?=before))|(.*)))))*") |
| 45 | __deltask_regexp__ = re.compile("deltask\s+(?P<func>\w+)") | 45 | __deltask_regexp__ = re.compile(r"deltask\s+(?P<func>\w+)") |
| 46 | __addhandler_regexp__ = re.compile( r"addhandler\s+(.+)" ) | 46 | __addhandler_regexp__ = re.compile(r"addhandler\s+(.+)" ) |
| 47 | __def_regexp__ = re.compile( r"def\s+(\w+).*:" ) | 47 | __def_regexp__ = re.compile(r"def\s+(\w+).*:" ) |
| 48 | __python_func_regexp__ = re.compile( r"(\s+.*)|(^$)|(^#)" ) | 48 | __python_func_regexp__ = re.compile(r"(\s+.*)|(^$)|(^#)" ) |
| 49 | __python_tab_regexp__ = re.compile(" *\t") | 49 | __python_tab_regexp__ = re.compile(r" *\t") |
| 50 | 50 | ||
| 51 | __infunc__ = [] | 51 | __infunc__ = [] |
| 52 | __inpython__ = False | 52 | __inpython__ = False |
