diff options
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/populate_sdk_base.bbclass | 42 |
1 files changed, 10 insertions, 32 deletions
diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass index 096628b51b..0c17aac251 100644 --- a/meta/classes/populate_sdk_base.bbclass +++ b/meta/classes/populate_sdk_base.bbclass | |||
@@ -27,10 +27,19 @@ EXCLUDE_FROM_WORLD = "1" | |||
27 | SDK_PACKAGING_FUNC ?= "create_shar" | 27 | SDK_PACKAGING_FUNC ?= "create_shar" |
28 | 28 | ||
29 | fakeroot python do_populate_sdk() { | 29 | fakeroot python do_populate_sdk() { |
30 | from oe.sdk import populate_sdk | ||
31 | from oe.manifest import create_manifest, Manifest | ||
32 | |||
30 | pn = d.getVar('PN', True) | 33 | pn = d.getVar('PN', True) |
31 | runtime_mapping_rename("TOOLCHAIN_TARGET_TASK", pn, d) | 34 | runtime_mapping_rename("TOOLCHAIN_TARGET_TASK", pn, d) |
32 | 35 | ||
33 | bb.build.exec_func("populate_sdk_image", d) | 36 | # create target/host SDK manifests |
37 | create_manifest(d, manifest_dir=d.getVar('SDK_DIR', True), | ||
38 | manifest_type=Manifest.MANIFEST_TYPE_SDK_HOST) | ||
39 | create_manifest(d, manifest_dir=d.getVar('SDK_DIR', True), | ||
40 | manifest_type=Manifest.MANIFEST_TYPE_SDK_TARGET) | ||
41 | |||
42 | populate_sdk(d) | ||
34 | 43 | ||
35 | # Handle multilibs in the SDK environment, siteconfig, etc files... | 44 | # Handle multilibs in the SDK environment, siteconfig, etc files... |
36 | localdata = bb.data.createCopy(d) | 45 | localdata = bb.data.createCopy(d) |
@@ -57,37 +66,6 @@ fakeroot python do_populate_sdk() { | |||
57 | bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) | 66 | bb.build.exec_func(d.getVar("SDK_PACKAGING_FUNC", True), d) |
58 | } | 67 | } |
59 | 68 | ||
60 | fakeroot populate_sdk_image() { | ||
61 | rm -rf ${SDK_OUTPUT} | ||
62 | mkdir -p ${SDK_OUTPUT} | ||
63 | |||
64 | # populate_sdk_<image> is required to construct two images: | ||
65 | # SDK_ARCH-nativesdk - contains the cross compiler and associated tooling | ||
66 | # target - contains a target rootfs configured for the SDK usage | ||
67 | # | ||
68 | # the output of populate_sdk_<image> should end up in ${SDK_OUTPUT} it is made | ||
69 | # up of: | ||
70 | # ${SDK_OUTPUT}/<sdk_arch-nativesdk pkgs> | ||
71 | # ${SDK_OUTPUT}/${SDKTARGETSYSROOT}/<target pkgs> | ||
72 | |||
73 | populate_sdk_${IMAGE_PKGTYPE} | ||
74 | |||
75 | # Don't ship any libGL in the SDK | ||
76 | rm -rf ${SDK_OUTPUT}/${SDKPATHNATIVE}${libdir_nativesdk}/libGL* | ||
77 | |||
78 | # Can copy pstage files here | ||
79 | # target_pkgs=`cat ${SDK_OUTPUT}/${SDKTARGETSYSROOT}/var/lib/opkg/status | grep Package: | cut -f 2 -d ' '` | ||
80 | |||
81 | # Fix or remove broken .la files | ||
82 | #rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}/lib/*.la | ||
83 | rm -f ${SDK_OUTPUT}/${SDKPATHNATIVE}${libdir_nativesdk}/*.la | ||
84 | |||
85 | # Link the ld.so.cache file into the hosts filesystem | ||
86 | ln -s /etc/ld.so.cache ${SDK_OUTPUT}/${SDKPATHNATIVE}/etc/ld.so.cache | ||
87 | |||
88 | ${SDK_POSTPROCESS_COMMAND} | ||
89 | } | ||
90 | |||
91 | fakeroot create_sdk_files() { | 69 | fakeroot create_sdk_files() { |
92 | # Setup site file for external use | 70 | # Setup site file for external use |
93 | toolchain_create_sdk_siteconfig ${SDK_OUTPUT}/${SDKPATH}/site-config-${REAL_MULTIMACH_TARGET_SYS} | 71 | toolchain_create_sdk_siteconfig ${SDK_OUTPUT}/${SDKPATH}/site-config-${REAL_MULTIMACH_TARGET_SYS} |