diff options
author | Serhey Popovych <serhe.popovych@gmail.com> | 2018-12-14 19:54:34 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-12-15 17:10:52 +0000 |
commit | 2468becd4bac45d2893eba8c322203874c48e27a (patch) | |
tree | 97008811e7ae654f6defb158fe673bed7fdfb907 | |
parent | 76172256e3943c42c56ca41a879d912a5645bd5e (diff) | |
download | poky-2468becd4bac45d2893eba8c322203874c48e27a.tar.gz |
arch-powerpc64.inc: Use elfv2 ABI when building with musl
Historically first PowerPC ABI was big-endian only (elfv1 currently). It
is standard ABI for both 32-bit ppc and 64-bit ppc64 architectures.
With PowerPC little-endian support new ABI was introduced (elfv2) and it
is used primarily with ppc64le target only. While it has support for
big-endian it is not commonly used and elfv1 still preferred.
Musl does support only elfv2 ABI for both LE and BE and does not have
any plans to support elfv1.
Since then to build for powerpc64 with musl new ABI should be used. As
expected it is not compatible with elfv1 but that isn't problem as long
as there is no binary distributed software or assembly code written for
elfv1 ABI.
(From OE-Core rev: 68c9641855199f34aabe1050e863c21830116fe1)
Signed-off-by: Serhey Popovych <serhe.popovych@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/conf/machine/include/powerpc/arch-powerpc64.inc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/meta/conf/machine/include/powerpc/arch-powerpc64.inc b/meta/conf/machine/include/powerpc/arch-powerpc64.inc index f751c6b76c..d9916d43da 100644 --- a/meta/conf/machine/include/powerpc/arch-powerpc64.inc +++ b/meta/conf/machine/include/powerpc/arch-powerpc64.inc | |||
@@ -7,6 +7,9 @@ TUNECONFLICTS[m64] = "m32 nf" | |||
7 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'm64', ' -m64', '', d)}" | 7 | TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'm64', ' -m64', '', d)}" |
8 | TUNE_ARCH .= "${@bb.utils.contains('TUNE_FEATURES', [ 'm64' ], 'powerpc64', '', d)}" | 8 | TUNE_ARCH .= "${@bb.utils.contains('TUNE_FEATURES', [ 'm64' ], 'powerpc64', '', d)}" |
9 | 9 | ||
10 | # musl only supports elfv2 ABI for ppc64 | ||
11 | TUNE_CCARGS .= "${@['', ' -mabi=elfv2']['libc-musl' in d.getVar('OVERRIDES').split(':')]}" | ||
12 | |||
10 | # user mode qemu doesn't support ppc64 | 13 | # user mode qemu doesn't support ppc64 |
11 | MACHINE_FEATURES_BACKFILL_CONSIDERED_append = " ${@bb.utils.contains('TUNE_FEATURES', 'm64', 'qemu-usermode', '', d)}" | 14 | MACHINE_FEATURES_BACKFILL_CONSIDERED_append = " ${@bb.utils.contains('TUNE_FEATURES', 'm64', 'qemu-usermode', '', d)}" |
12 | 15 | ||