summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/linuxloader.bbclass29
1 files changed, 17 insertions, 12 deletions
diff --git a/meta/classes/linuxloader.bbclass b/meta/classes/linuxloader.bbclass
index e2876cec7a..ec0e0556dd 100644
--- a/meta/classes/linuxloader.bbclass
+++ b/meta/classes/linuxloader.bbclass
@@ -1,27 +1,31 @@
1def get_musl_loader(d): 1def get_musl_loader_arch(d):
2 import re 2 import re
3 dynamic_loader = None 3 ldso_arch = None
4 4
5 targetarch = d.getVar("TARGET_ARCH") 5 targetarch = d.getVar("TARGET_ARCH")
6 if targetarch.startswith("microblaze"): 6 if targetarch.startswith("microblaze"):
7 dynamic_loader = "${base_libdir}/ld-musl-microblaze${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el' ,d)}.so.1" 7 ldso_arch = "microblaze${@bb.utils.contains('TUNE_FEATURES', 'bigendian', '', 'el' ,d)}"
8 elif targetarch.startswith("mips"): 8 elif targetarch.startswith("mips"):
9 dynamic_loader = "${base_libdir}/ld-musl-mips${ABIEXTENSION}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1" 9 ldso_arch = "mips${ABIEXTENSION}${MIPSPKGSFX_BYTE}${MIPSPKGSFX_R6}${MIPSPKGSFX_ENDIAN}${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}"
10 elif targetarch == "powerpc": 10 elif targetarch == "powerpc":
11 dynamic_loader = "${base_libdir}/ld-musl-powerpc${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1" 11 ldso_arch = "powerpc${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}"
12 elif targetarch == "powerpc64": 12 elif targetarch == "powerpc64":
13 dynamic_loader = "${base_libdir}/ld-musl-powerpc64.so.1" 13 ldso_arch = "powerpc64"
14 elif targetarch == "x86_64": 14 elif targetarch == "x86_64":
15 dynamic_loader = "${base_libdir}/ld-musl-x86_64.so.1" 15 ldso_arch = "x86_64"
16 elif re.search("i.86", targetarch): 16 elif re.search("i.86", targetarch):
17 dynamic_loader = "${base_libdir}/ld-musl-i386.so.1" 17 ldso_arch = "i386"
18 elif targetarch.startswith("arm"): 18 elif targetarch.startswith("arm"):
19 dynamic_loader = "${base_libdir}/ld-musl-arm${ARMPKGSFX_ENDIAN}${ARMPKGSFX_EABI}.so.1" 19 ldso_arch = "arm${ARMPKGSFX_ENDIAN}${ARMPKGSFX_EABI}"
20 elif targetarch.startswith("aarch64"): 20 elif targetarch.startswith("aarch64"):
21 dynamic_loader = "${base_libdir}/ld-musl-aarch64${ARMPKGSFX_ENDIAN_64}.so.1" 21 ldso_arch = "aarch64${ARMPKGSFX_ENDIAN_64}"
22 elif targetarch.startswith("riscv64"): 22 elif targetarch.startswith("riscv64"):
23 dynamic_loader = "${base_libdir}/ld-musl-riscv64${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}.so.1" 23 ldso_arch = "riscv64${@['', '-sf'][d.getVar('TARGET_FPU') == 'soft']}"
24 return dynamic_loader 24 return ldso_arch
25
26def get_musl_loader(d):
27 import re
28 return "/lib/ld-musl-" + get_musl_loader_arch(d) + ".so.1"
25 29
26def get_glibc_loader(d): 30def get_glibc_loader(d):
27 import re 31 import re
@@ -62,4 +66,5 @@ def get_linuxloader(d):
62 66
63get_linuxloader[vardepvalue] = "${@get_linuxloader(d)}" 67get_linuxloader[vardepvalue] = "${@get_linuxloader(d)}"
64get_musl_loader[vardepvalue] = "${@get_musl_loader(d)}" 68get_musl_loader[vardepvalue] = "${@get_musl_loader(d)}"
69get_musl_loader_arch[vardepvalue] = "${@get_musl_loader_arch(d)}"
65get_glibc_loader[vardepvalue] = "${@get_glibc_loader(d)}" 70get_glibc_loader[vardepvalue] = "${@get_glibc_loader(d)}"