diff options
Diffstat (limited to 'meta/recipes-devtools/gcc/libgcc-common.inc')
-rw-r--r-- | meta/recipes-devtools/gcc/libgcc-common.inc | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/meta/recipes-devtools/gcc/libgcc-common.inc b/meta/recipes-devtools/gcc/libgcc-common.inc index 8a13f542c1..74e9faa528 100644 --- a/meta/recipes-devtools/gcc/libgcc-common.inc +++ b/meta/recipes-devtools/gcc/libgcc-common.inc | |||
@@ -64,18 +64,18 @@ addtask multilib_install after do_install before do_package do_populate_sysroot | |||
64 | fakeroot python do_multilib_install() { | 64 | fakeroot python do_multilib_install() { |
65 | import re | 65 | import re |
66 | 66 | ||
67 | multilibs = d.getVar('MULTILIB_VARIANTS', True) | 67 | multilibs = d.getVar('MULTILIB_VARIANTS') |
68 | if not multilibs or bb.data.inherits_class('nativesdk', d): | 68 | if not multilibs or bb.data.inherits_class('nativesdk', d): |
69 | return | 69 | return |
70 | 70 | ||
71 | binv = d.getVar('BINV', True) | 71 | binv = d.getVar('BINV') |
72 | 72 | ||
73 | mlprefix = d.getVar('MLPREFIX', True) | 73 | mlprefix = d.getVar('MLPREFIX') |
74 | if ('%slibgcc' % mlprefix) != d.getVar('PN', True): | 74 | if ('%slibgcc' % mlprefix) != d.getVar('PN'): |
75 | return | 75 | return |
76 | 76 | ||
77 | if mlprefix: | 77 | if mlprefix: |
78 | orig_tune = d.getVar('DEFAULTTUNE_MULTILIB_ORIGINAL', True) | 78 | orig_tune = d.getVar('DEFAULTTUNE_MULTILIB_ORIGINAL') |
79 | orig_tune_params = get_tune_parameters(orig_tune, d) | 79 | orig_tune_params = get_tune_parameters(orig_tune, d) |
80 | orig_tune_baselib = orig_tune_params['baselib'] | 80 | orig_tune_baselib = orig_tune_params['baselib'] |
81 | orig_tune_bitness = orig_tune_baselib.replace('lib', '') | 81 | orig_tune_bitness = orig_tune_baselib.replace('lib', '') |
@@ -83,10 +83,10 @@ fakeroot python do_multilib_install() { | |||
83 | orig_tune_bitness = '32' | 83 | orig_tune_bitness = '32' |
84 | 84 | ||
85 | src = '../../../' + orig_tune_baselib + '/' + \ | 85 | src = '../../../' + orig_tune_baselib + '/' + \ |
86 | d.getVar('TARGET_SYS_MULTILIB_ORIGINAL', True) + '/' + binv + '/' | 86 | d.getVar('TARGET_SYS_MULTILIB_ORIGINAL') + '/' + binv + '/' |
87 | 87 | ||
88 | dest = d.getVar('D', True) + d.getVar('libdir', True) + '/' + \ | 88 | dest = d.getVar('D') + d.getVar('libdir') + '/' + \ |
89 | d.getVar('TARGET_SYS', True) + '/' + binv + '/' + orig_tune_bitness | 89 | d.getVar('TARGET_SYS') + '/' + binv + '/' + orig_tune_bitness |
90 | 90 | ||
91 | if os.path.lexists(dest): | 91 | if os.path.lexists(dest): |
92 | os.unlink(dest) | 92 | os.unlink(dest) |
@@ -95,7 +95,7 @@ fakeroot python do_multilib_install() { | |||
95 | 95 | ||
96 | 96 | ||
97 | for ml in multilibs.split(): | 97 | for ml in multilibs.split(): |
98 | tune = d.getVar('DEFAULTTUNE_virtclass-multilib-' + ml, True) | 98 | tune = d.getVar('DEFAULTTUNE_virtclass-multilib-' + ml) |
99 | if not tune: | 99 | if not tune: |
100 | bb.warn('DEFAULTTUNE_virtclass-multilib-%s is not defined. Skipping...' % ml) | 100 | bb.warn('DEFAULTTUNE_virtclass-multilib-%s is not defined. Skipping...' % ml) |
101 | continue | 101 | continue |
@@ -118,11 +118,11 @@ fakeroot python do_multilib_install() { | |||
118 | libcextension = '' | 118 | libcextension = '' |
119 | 119 | ||
120 | src = '../../../' + tune_baselib + '/' + \ | 120 | src = '../../../' + tune_baselib + '/' + \ |
121 | tune_arch + d.getVar('TARGET_VENDOR', True) + 'ml' + ml + \ | 121 | tune_arch + d.getVar('TARGET_VENDOR') + 'ml' + ml + \ |
122 | '-' + d.getVar('TARGET_OS', True) + libcextension + '/' + binv + '/' | 122 | '-' + d.getVar('TARGET_OS') + libcextension + '/' + binv + '/' |
123 | 123 | ||
124 | dest = d.getVar('D', True) + d.getVar('libdir', True) + '/' + \ | 124 | dest = d.getVar('D') + d.getVar('libdir') + '/' + \ |
125 | d.getVar('TARGET_SYS', True) + '/' + binv + '/' + tune_bitness | 125 | d.getVar('TARGET_SYS') + '/' + binv + '/' + tune_bitness |
126 | 126 | ||
127 | if os.path.lexists(dest): | 127 | if os.path.lexists(dest): |
128 | os.unlink(dest) | 128 | os.unlink(dest) |
@@ -131,7 +131,7 @@ fakeroot python do_multilib_install() { | |||
131 | 131 | ||
132 | def get_original_os(d): | 132 | def get_original_os(d): |
133 | vendoros = d.expand('${TARGET_ARCH}${ORIG_TARGET_VENDOR}-${TARGET_OS}') | 133 | vendoros = d.expand('${TARGET_ARCH}${ORIG_TARGET_VENDOR}-${TARGET_OS}') |
134 | for suffix in [d.getVar('ABIEXTENSION', True), d.getVar('LIBCEXTENSION', True)]: | 134 | for suffix in [d.getVar('ABIEXTENSION'), d.getVar('LIBCEXTENSION')]: |
135 | if suffix and vendoros.endswith(suffix): | 135 | if suffix and vendoros.endswith(suffix): |
136 | vendoros = vendoros[:-len(suffix)] | 136 | vendoros = vendoros[:-len(suffix)] |
137 | # Arm must use linux-gnueabi not linux as only the former is accepted by gcc | 137 | # Arm must use linux-gnueabi not linux as only the former is accepted by gcc |
@@ -144,11 +144,11 @@ BASETARGET_SYS = "${@get_original_os(d)}" | |||
144 | 144 | ||
145 | addtask extra_symlinks after do_multilib_install before do_package do_populate_sysroot | 145 | addtask extra_symlinks after do_multilib_install before do_package do_populate_sysroot |
146 | fakeroot python do_extra_symlinks() { | 146 | fakeroot python do_extra_symlinks() { |
147 | targetsys = d.getVar('BASETARGET_SYS', True) | 147 | targetsys = d.getVar('BASETARGET_SYS') |
148 | 148 | ||
149 | if targetsys != d.getVar('TARGET_SYS', True): | 149 | if targetsys != d.getVar('TARGET_SYS'): |
150 | dest = d.getVar('D', True) + d.getVar('libdir', True) + '/' + targetsys | 150 | dest = d.getVar('D') + d.getVar('libdir') + '/' + targetsys |
151 | src = d.getVar('TARGET_SYS', True) | 151 | src = d.getVar('TARGET_SYS') |
152 | if not os.path.lexists(dest) and os.path.lexists(d.getVar('D', True) + d.getVar('libdir', True)): | 152 | if not os.path.lexists(dest) and os.path.lexists(d.getVar('D') + d.getVar('libdir')): |
153 | os.symlink(src, dest) | 153 | os.symlink(src, dest) |
154 | } | 154 | } |