diff options
Diffstat (limited to 'meta/classes/libc-package.bbclass')
| -rw-r--r-- | meta/classes/libc-package.bbclass | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/meta/classes/libc-package.bbclass b/meta/classes/libc-package.bbclass index 82d642e15e..0b4c666a74 100644 --- a/meta/classes/libc-package.bbclass +++ b/meta/classes/libc-package.bbclass | |||
| @@ -113,8 +113,8 @@ python package_do_split_gconvs () { | |||
| 113 | def calc_gconv_deps(fn, pkg, file_regex, output_pattern, group): | 113 | def calc_gconv_deps(fn, pkg, file_regex, output_pattern, group): |
| 114 | deps = [] | 114 | deps = [] |
| 115 | f = open(fn, "rb") | 115 | f = open(fn, "rb") |
| 116 | c_re = re.compile('^copy "(.*)"') | 116 | c_re = re.compile(r'^copy "(.*)"') |
| 117 | i_re = re.compile('^include "(\w+)".*') | 117 | i_re = re.compile(r'^include "(\w+)".*') |
| 118 | for l in f.readlines(): | 118 | for l in f.readlines(): |
| 119 | l = l.decode("latin-1") | 119 | l = l.decode("latin-1") |
| 120 | m = c_re.match(l) or i_re.match(l) | 120 | m = c_re.match(l) or i_re.match(l) |
| @@ -128,15 +128,15 @@ python package_do_split_gconvs () { | |||
| 128 | if bpn != 'glibc': | 128 | if bpn != 'glibc': |
| 129 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) | 129 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) |
| 130 | 130 | ||
| 131 | do_split_packages(d, gconv_libdir, file_regex='^(.*)\.so$', output_pattern=bpn+'-gconv-%s', \ | 131 | do_split_packages(d, gconv_libdir, file_regex=r'^(.*)\.so$', output_pattern=bpn+'-gconv-%s', \ |
| 132 | description='gconv module for character set %s', hook=calc_gconv_deps, \ | 132 | description='gconv module for character set %s', hook=calc_gconv_deps, \ |
| 133 | extra_depends=bpn+'-gconv') | 133 | extra_depends=bpn+'-gconv') |
| 134 | 134 | ||
| 135 | def calc_charmap_deps(fn, pkg, file_regex, output_pattern, group): | 135 | def calc_charmap_deps(fn, pkg, file_regex, output_pattern, group): |
| 136 | deps = [] | 136 | deps = [] |
| 137 | f = open(fn, "rb") | 137 | f = open(fn, "rb") |
| 138 | c_re = re.compile('^copy "(.*)"') | 138 | c_re = re.compile(r'^copy "(.*)"') |
| 139 | i_re = re.compile('^include "(\w+)".*') | 139 | i_re = re.compile(r'^include "(\w+)".*') |
| 140 | for l in f.readlines(): | 140 | for l in f.readlines(): |
| 141 | l = l.decode("latin-1") | 141 | l = l.decode("latin-1") |
| 142 | m = c_re.match(l) or i_re.match(l) | 142 | m = c_re.match(l) or i_re.match(l) |
| @@ -150,14 +150,14 @@ python package_do_split_gconvs () { | |||
| 150 | if bpn != 'glibc': | 150 | if bpn != 'glibc': |
| 151 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) | 151 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) |
| 152 | 152 | ||
| 153 | do_split_packages(d, charmap_dir, file_regex='^(.*)\.gz$', output_pattern=bpn+'-charmap-%s', \ | 153 | do_split_packages(d, charmap_dir, file_regex=r'^(.*)\.gz$', output_pattern=bpn+'-charmap-%s', \ |
| 154 | description='character map for %s encoding', hook=calc_charmap_deps, extra_depends='') | 154 | description='character map for %s encoding', hook=calc_charmap_deps, extra_depends='') |
| 155 | 155 | ||
| 156 | def calc_locale_deps(fn, pkg, file_regex, output_pattern, group): | 156 | def calc_locale_deps(fn, pkg, file_regex, output_pattern, group): |
| 157 | deps = [] | 157 | deps = [] |
| 158 | f = open(fn, "rb") | 158 | f = open(fn, "rb") |
| 159 | c_re = re.compile('^copy "(.*)"') | 159 | c_re = re.compile(r'^copy "(.*)"') |
| 160 | i_re = re.compile('^include "(\w+)".*') | 160 | i_re = re.compile(r'^include "(\w+)".*') |
| 161 | for l in f.readlines(): | 161 | for l in f.readlines(): |
| 162 | l = l.decode("latin-1") | 162 | l = l.decode("latin-1") |
| 163 | m = c_re.match(l) or i_re.match(l) | 163 | m = c_re.match(l) or i_re.match(l) |
| @@ -171,13 +171,13 @@ python package_do_split_gconvs () { | |||
| 171 | if bpn != 'glibc': | 171 | if bpn != 'glibc': |
| 172 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) | 172 | d.setVar('RPROVIDES_%s' % pkg, pkg.replace(bpn, 'glibc')) |
| 173 | 173 | ||
| 174 | do_split_packages(d, locales_dir, file_regex='(.*)', output_pattern=bpn+'-localedata-%s', \ | 174 | do_split_packages(d, locales_dir, file_regex=r'(.*)', output_pattern=bpn+'-localedata-%s', \ |
| 175 | description='locale definition for %s', hook=calc_locale_deps, extra_depends='') | 175 | description='locale definition for %s', hook=calc_locale_deps, extra_depends='') |
| 176 | d.setVar('PACKAGES', d.getVar('PACKAGES', False) + ' ' + d.getVar('MLPREFIX', False) + bpn + '-gconv') | 176 | d.setVar('PACKAGES', d.getVar('PACKAGES', False) + ' ' + d.getVar('MLPREFIX', False) + bpn + '-gconv') |
| 177 | 177 | ||
| 178 | use_bin = d.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE") | 178 | use_bin = d.getVar("GLIBC_INTERNAL_USE_BINARY_LOCALE") |
| 179 | 179 | ||
| 180 | dot_re = re.compile("(.*)\.(.*)") | 180 | dot_re = re.compile(r"(.*)\.(.*)") |
| 181 | 181 | ||
| 182 | # Read in supported locales and associated encodings | 182 | # Read in supported locales and associated encodings |
| 183 | supported = {} | 183 | supported = {} |
| @@ -290,7 +290,7 @@ python package_do_split_gconvs () { | |||
| 290 | d.setVar('ALLOW_EMPTY_%s' % pkgname, '1') | 290 | d.setVar('ALLOW_EMPTY_%s' % pkgname, '1') |
| 291 | d.setVar('PACKAGES', '%s %s' % (pkgname, d.getVar('PACKAGES'))) | 291 | d.setVar('PACKAGES', '%s %s' % (pkgname, d.getVar('PACKAGES'))) |
| 292 | rprovides = ' %svirtual-locale-%s' % (mlprefix, legitimize_package_name(name)) | 292 | rprovides = ' %svirtual-locale-%s' % (mlprefix, legitimize_package_name(name)) |
| 293 | m = re.match("(.*)_(.*)", name) | 293 | m = re.match(r"(.*)_(.*)", name) |
| 294 | if m: | 294 | if m: |
| 295 | rprovides += ' %svirtual-locale-%s' % (mlprefix, m.group(1)) | 295 | rprovides += ' %svirtual-locale-%s' % (mlprefix, m.group(1)) |
| 296 | d.setVar('RPROVIDES_%s' % pkgname, rprovides) | 296 | d.setVar('RPROVIDES_%s' % pkgname, rprovides) |
| @@ -356,12 +356,12 @@ python package_do_split_gconvs () { | |||
| 356 | if use_bin in ('compile', 'precompiled'): | 356 | if use_bin in ('compile', 'precompiled'): |
| 357 | lcsplit = d.getVar('GLIBC_SPLIT_LC_PACKAGES') | 357 | lcsplit = d.getVar('GLIBC_SPLIT_LC_PACKAGES') |
| 358 | if lcsplit and int(lcsplit): | 358 | if lcsplit and int(lcsplit): |
| 359 | do_split_packages(d, binary_locales_dir, file_regex='^(.*/LC_\w+)', \ | 359 | do_split_packages(d, binary_locales_dir, file_regex=r'^(.*/LC_\w+)', \ |
| 360 | output_pattern=bpn+'-binary-localedata-%s', \ | 360 | output_pattern=bpn+'-binary-localedata-%s', \ |
| 361 | description='binary locale definition for %s', recursive=True, | 361 | description='binary locale definition for %s', recursive=True, |
| 362 | hook=metapkg_hook, extra_depends='', allow_dirs=True, match_path=True) | 362 | hook=metapkg_hook, extra_depends='', allow_dirs=True, match_path=True) |
| 363 | else: | 363 | else: |
| 364 | do_split_packages(d, binary_locales_dir, file_regex='(.*)', \ | 364 | do_split_packages(d, binary_locales_dir, file_regex=r'(.*)', \ |
| 365 | output_pattern=bpn+'-binary-localedata-%s', \ | 365 | output_pattern=bpn+'-binary-localedata-%s', \ |
| 366 | description='binary locale definition for %s', extra_depends='', allow_dirs=True) | 366 | description='binary locale definition for %s', extra_depends='', allow_dirs=True) |
| 367 | else: | 367 | else: |
