summaryrefslogtreecommitdiffstats
path: root/meta/classes/multilib_header.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2022-08-10 14:35:29 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-08-12 15:27:17 +0100
commitfd1517e2b51a170f2427122c6b95396db251d827 (patch)
treedabfe3e631339c2fc99a9ee7febb0f9c128e325e /meta/classes/multilib_header.bbclass
parent10317912ee319ccf7f83605d438b5cbf9663f296 (diff)
downloadpoky-fd1517e2b51a170f2427122c6b95396db251d827.tar.gz
classes: Update classes to match new bitbake class scope functionality
Move classes to classes-global or classes-recipe as appropriate to take advantage of new bitbake functionality to check class scope/usage. (From OE-Core rev: f5c128008365e141082c129417eb72d2751e8045) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/multilib_header.bbclass')
-rw-r--r--meta/classes/multilib_header.bbclass58
1 files changed, 0 insertions, 58 deletions
diff --git a/meta/classes/multilib_header.bbclass b/meta/classes/multilib_header.bbclass
deleted file mode 100644
index 33f7e027f0..0000000000
--- a/meta/classes/multilib_header.bbclass
+++ /dev/null
@@ -1,58 +0,0 @@
1#
2# Copyright OpenEmbedded Contributors
3#
4# SPDX-License-Identifier: MIT
5#
6
7inherit siteinfo
8
9# If applicable on the architecture, this routine will rename the header and
10# add a unique identifier to the name for the ABI/bitsize that is being used.
11# A wrapper will be generated for the architecture that knows how to call
12# all of the ABI variants for that given architecture.
13#
14oe_multilib_header() {
15
16 case ${HOST_OS} in
17 *-musl*)
18 return
19 ;;
20 *)
21 esac
22 # For MIPS: "n32" is a special case, which needs to be
23 # distinct from both 64-bit and 32-bit.
24 case ${TARGET_ARCH} in
25 mips*) case "${MIPSPKGSFX_ABI}" in
26 "-n32")
27 ident=n32
28 ;;
29 *)
30 ident=${SITEINFO_BITS}
31 ;;
32 esac
33 ;;
34 *) ident=${SITEINFO_BITS}
35 esac
36 for each_header in "$@" ; do
37 if [ ! -f "${D}/${includedir}/$each_header" ]; then
38 bberror "oe_multilib_header: Unable to find header $each_header."
39 continue
40 fi
41 stem=$(echo $each_header | sed 's#\.h$##')
42 # if mips64/n32 set ident to n32
43 mv ${D}/${includedir}/$each_header ${D}/${includedir}/${stem}-${ident}.h
44
45 sed -e "s#ENTER_HEADER_FILENAME_HERE#${stem}#g" ${COREBASE}/scripts/multilib_header_wrapper.h > ${D}/${includedir}/$each_header
46 done
47}
48
49# Dependencies on arch variables like MIPSPKGSFX_ABI can be problematic.
50# We don't need multilib headers for native builds so brute force things.
51oe_multilib_header:class-native () {
52 return
53}
54
55# Nor do we need multilib headers for nativesdk builds.
56oe_multilib_header:class-nativesdk () {
57 return
58}