diff options
author | Robert Yang <liezhi.yang@windriver.com> | 2018-11-23 19:04:52 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-01-08 20:14:42 +0000 |
commit | 38887e6c1a649d16f5666a4ffe4ab2b90ee94741 (patch) | |
tree | e1695f539875731e2a2660f34575dc29140ceed6 /meta/recipes-core/busybox | |
parent | bc246384a10c6a0a2ec7a2dc3503361c1975394f (diff) | |
download | poky-38887e6c1a649d16f5666a4ffe4ab2b90ee94741.tar.gz |
recipes: Remove tab indentations in python code
Use 4 spaces to replace a tab.
(From OE-Core rev: cbb6743d46752481782789fa1a0dfade11057114)
(From OE-Core rev: 42ebdc7253c3a319d671a7f924603d85a22bbb4e)
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/busybox')
-rw-r--r-- | meta/recipes-core/busybox/busybox.inc | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/meta/recipes-core/busybox/busybox.inc b/meta/recipes-core/busybox/busybox.inc index 09433dd824..0c0d26ed3a 100644 --- a/meta/recipes-core/busybox/busybox.inc +++ b/meta/recipes-core/busybox/busybox.inc | |||
@@ -55,35 +55,35 @@ inherit cml1 systemd update-rc.d ptest | |||
55 | 55 | ||
56 | # internal helper | 56 | # internal helper |
57 | def busybox_cfg(feature, tokens, cnf, rem): | 57 | def busybox_cfg(feature, tokens, cnf, rem): |
58 | if type(tokens) == type(""): | 58 | if type(tokens) == type(""): |
59 | tokens = [tokens] | 59 | tokens = [tokens] |
60 | rem.extend(['/^[# ]*' + token + '[ =]/d' for token in tokens]) | 60 | rem.extend(['/^[# ]*' + token + '[ =]/d' for token in tokens]) |
61 | if feature: | 61 | if feature: |
62 | cnf.extend([token + '=y' for token in tokens]) | 62 | cnf.extend([token + '=y' for token in tokens]) |
63 | else: | 63 | else: |
64 | cnf.extend(['# ' + token + ' is not set' for token in tokens]) | 64 | cnf.extend(['# ' + token + ' is not set' for token in tokens]) |
65 | 65 | ||
66 | # Map distro features to config settings | 66 | # Map distro features to config settings |
67 | def features_to_busybox_settings(d): | 67 | def features_to_busybox_settings(d): |
68 | cnf, rem = ([], []) | 68 | cnf, rem = ([], []) |
69 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IPV6', cnf, rem) | 69 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IPV6', cnf, rem) |
70 | busybox_cfg(True, 'CONFIG_LFS', cnf, rem) | 70 | busybox_cfg(True, 'CONFIG_LFS', cnf, rem) |
71 | busybox_cfg(True, 'CONFIG_FDISK_SUPPORT_LARGE_DISKS', cnf, rem) | 71 | busybox_cfg(True, 'CONFIG_FDISK_SUPPORT_LARGE_DISKS', cnf, rem) |
72 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'nls', True, False, d), 'CONFIG_LOCALE_SUPPORT', cnf, rem) | 72 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'nls', True, False, d), 'CONFIG_LOCALE_SUPPORT', cnf, rem) |
73 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv4', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV4', cnf, rem) | 73 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv4', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV4', cnf, rem) |
74 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV6', cnf, rem) | 74 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'ipv6', True, False, d), 'CONFIG_FEATURE_IFUPDOWN_IPV6', cnf, rem) |
75 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'wifi', True, False, d), 'CONFIG_RFKILL', cnf, rem) | 75 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'wifi', True, False, d), 'CONFIG_RFKILL', cnf, rem) |
76 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'bluetooth', True, False, d), 'CONFIG_RFKILL', cnf, rem) | 76 | busybox_cfg(bb.utils.contains('DISTRO_FEATURES', 'bluetooth', True, False, d), 'CONFIG_RFKILL', cnf, rem) |
77 | return "\n".join(cnf), "\n".join(rem) | 77 | return "\n".join(cnf), "\n".join(rem) |
78 | 78 | ||
79 | # X, Y = ${@features_to_busybox_settings(d)} | 79 | # X, Y = ${@features_to_busybox_settings(d)} |
80 | # unfortunately doesn't seem to work with bitbake, workaround: | 80 | # unfortunately doesn't seem to work with bitbake, workaround: |
81 | def features_to_busybox_conf(d): | 81 | def features_to_busybox_conf(d): |
82 | cnf, rem = features_to_busybox_settings(d) | 82 | cnf, rem = features_to_busybox_settings(d) |
83 | return cnf | 83 | return cnf |
84 | def features_to_busybox_del(d): | 84 | def features_to_busybox_del(d): |
85 | cnf, rem = features_to_busybox_settings(d) | 85 | cnf, rem = features_to_busybox_settings(d) |
86 | return rem | 86 | return rem |
87 | 87 | ||
88 | configmangle = '/CONFIG_EXTRA_CFLAGS/d; \ | 88 | configmangle = '/CONFIG_EXTRA_CFLAGS/d; \ |
89 | ' | 89 | ' |