Skip to contentSkip to conversation

fixes after Recipe Specific Sysroot

PATCH In review Andrea Adami 1 participant 10 messages Feb 13, 2017

lore
Share & tools
lore
#0 lore raw

cover fixes after Recipe Specific Sysroot

This patchset adds fixes to the klcc-cross recipe which was not behaving after rebuild from sstate for multimachine build (machines of the same arch).

There are small improvements to the recipe as seen in libtool-cross in oe-core.

Other than this we do remove the blacklisting for the recipes in meta-initramfs.

Andrea Adami (9):
klcc-cross: fixes for recipe specific sysroot
klcc-cross: disable packaging using appropriate
klcc-cross: restrict scope of SSTATE_SCAN_FILES
klcc-cross: Use SYSROOT_DIRS to add dirs to stage in sysroot ubi-utils-klibc_1.5.1: remove blacklisting kexecboot(-klibc)_0.6: remove blacklisting initramfs-kexecboot-klibc-image: remove blacklisting klibc-utils_2.0.4: remove blacklisting kexec-tools-klibc_2.0.2: remove blacklisting

 .../images/initramfs-kexecboot-klibc-image.bb      |  2 --
 .../recipes-bsp/kexecboot/kexecboot_0.6.bb         |  3 --
 .../recipes-devtools/klibc/klcc-cross_2.0.4.bb     | 32 +++++++++-------------
 .../recipes-devtools/klibc/klibc-utils_2.0.4.bb    |  2 --
 .../recipes-devtools/mtd/ubi-utils-klibc_1.5.1.bb  |  2 --
 .../kexec/kexec-tools-klibc_2.0.2.bb               |  2 --
 6 files changed, 13 insertions(+), 30 deletions(-)
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/9 klcc-cross: fixes for recipe specific sysroot

The klcc script encodes the paths with custom escaping.
As stated in the patch "Turn the horribly encoded paths into something which sstate can transform using its ususal magic by removing all the crazy escaping".

---
 meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb +7 -5
index 3a4e7b5..15d860a 100644
@@ -17,8 +17,13 @@ do_compile() {
 do_install() {
     install -d ${D}${bindir_crossscripts}/
     install -m 0755 klcc/klcc ${D}${bindir_crossscripts}/${TARGET_PREFIX}klcc
-    # Insert an unencoded path as a comment to trigger the sstate renaming functions
-    sed -i '2i #${STAGING_DIR_TARGET}' ${D}${bindir_crossscripts}/${TARGET_PREFIX}klcc
+    # Turn the horribly encoded paths into something which sstate can transform using its ususal
+    # magic by removing all the crazy escaping.
+    sed -i -e "2i \$TARGETSYSROOT = '${STAGING_DIR_TARGET}';" \
+           -e "2i \$NATIVESYSROOT = '${STAGING_DIR_NATIVE}';" \
+           -e 's#${@d.getVar("STAGING_DIR_NATIVE", True).replace("/", "\\\\/").replace("-", "\\\\-").replace(".", "\\\\.")}#${NATIVESYSROOT}#g;' \
+           -e 's#${@d.getVar("STAGING_DIR_TARGET", True).replace("/", "\\\\/").replace("-", "\\\\-").replace(".", "\\\\.")}#${TARGETSYSROOT}#g' \
+        ${D}${bindir_crossscripts}/${TARGET_PREFIX}klcc
 }
 
 SYSROOT_PREPROCESS_FUNCS += "klcc_sysroot_preprocess"
@@ -35,6 +40,3 @@ deltask do_package_write_deb
 deltask do_package_write_tar
 
 SSTATE_SCAN_FILES = "*"
-EXTRA_STAGING_FIXMES = "MANGLEDSTAGINGDIRTARGET MANGLEDSTAGINGDIR"
-MANGLEDSTAGINGDIR = "${@d.getVar("STAGING_DIR").replace("/", "\\\\/").replace("-", "\\\\-")}"
-MANGLEDSTAGINGDIRTARGET = "${@d.getVar("STAGING_DIR_TARGET").replace("/", "\\\\/").replace("-", "\\\\-")}"
Signature · 1 line
2.7.4
#2 lore raw

PATCH 2/9 klcc-cross: disable packaging using appropriate

In reply to Andrea Adami

Instead of deleting the packaging tasks we simply inherit nopackages.bbclass.
Done that we do set PACKAGES to empty.

---
 meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb | 11 ++++-------
 1 file changed, 4 insertions(+), 7 deletions(-)
meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb +4 -7
index 15d860a..9126975 100644
@@ -3,6 +3,10 @@ SUMMARY = "The klcc crosscompiler for klibc"
 require klibc.inc
 DEPENDS = "klibc"
 
+# no packaging for this crossscript
+PACKAGES = ""
+inherit nopackages
+
 FILESPATH =. "${FILE_DIRNAME}/klibc-${PV}:"
 
 SRC_URI += "file://use-env-for-perl.patch"
@@ -32,11 +36,4 @@ klcc_sysroot_preprocess () {
        sysroot_stage_dir ${D}${bindir_crossscripts} ${SYSROOT_DESTDIR}${bindir_crossscripts}
 }
 
-deltask do_package
-deltask do_packagedata
-deltask do_package_write_ipk
-deltask do_package_write_rpm
-deltask do_package_write_deb
-deltask do_package_write_tar
-
 SSTATE_SCAN_FILES = "*"
Signature · 1 line
2.7.4
#3 lore raw

PATCH 3/9 klcc-cross: restrict scope of SSTATE_SCAN_FILES

In reply to Andrea Adami

As done in libtool-cross from oe-core we prefer to be specific even when there is just one file.

---
 meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb +1 -1
index 9126975..1a68ab4 100644
@@ -36,4 +36,4 @@ klcc_sysroot_preprocess () {
        sysroot_stage_dir ${D}${bindir_crossscripts} ${SYSROOT_DESTDIR}${bindir_crossscripts}
 }
 
-SSTATE_SCAN_FILES = "*"
+SSTATE_SCAN_FILES += "*-klcc"
Signature · 1 line
2.7.4
#4 lore raw

PATCH 4/9 klcc-cross: Use SYSROOT_DIRS to add dirs to stage in sysroot

In reply to Andrea Adami

As done for libtool-cross in oe-core.

---
 meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)
meta-initramfs/recipes-devtools/klibc/klcc-cross_2.0.4.bb +1 -6
index 1a68ab4..b285b2e 100644
@@ -30,10 +30,5 @@ do_install() {
         ${D}${bindir_crossscripts}/${TARGET_PREFIX}klcc
 }
 
-SYSROOT_PREPROCESS_FUNCS += "klcc_sysroot_preprocess"
-
-klcc_sysroot_preprocess () {
-       sysroot_stage_dir ${D}${bindir_crossscripts} ${SYSROOT_DESTDIR}${bindir_crossscripts}
-}
-
+SYSROOT_DIRS += "${bindir_crossscripts}"
 SSTATE_SCAN_FILES += "*-klcc"
Signature · 1 line
2.7.4
#5 lore raw

PATCH 5/9 ubi-utils-klibc_1.5.1: remove blacklisting

In reply to Andrea Adami

Recipe does build with the pending changes for meta-initramfs.

---
 meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_1.5.1.bb | 2 --
 1 file changed, 2 deletions(-)
meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc_1.5.1.bb +0 -2
index 81fae97..8ca1ca7 100644
@@ -48,5 +48,3 @@ FILES_ubirename-klibc = "${sbindir}/ubirename"
 FILES_ubirmvol-klibc = "${sbindir}/ubirmvol"
 FILES_ubirsvol-klibc = "${sbindir}/ubirsvol"
 FILES_ubiupdatevol-klibc = "${sbindir}/ubiupdatevol"
-
-PNBLACKLIST[ubi-utils-klibc] ?= "Fails to build with RSS http://errors.yoctoproject.org/Errors/Details/130665/"
Signature · 1 line
2.7.4
#6 lore raw

PATCH 6/9 kexecboot(-klibc)_0.6: remove blacklisting

In reply to Andrea Adami

Recipe does build with the pending changes for meta-initramfs.

---
 meta-initramfs/recipes-bsp/kexecboot/kexecboot_0.6.bb | 3 ---
 1 file changed, 3 deletions(-)
meta-initramfs/recipes-bsp/kexecboot/kexecboot_0.6.bb +0 -3
index a695ea6..45095f3 100644
@@ -73,6 +73,3 @@ pkg_postinst_${PN} () {
 }
 
 BBCLASSEXTEND = "klibc"
-
-PNBLACKLIST[kexecboot] ?= "Fails to build with RSS http://errors.yoctoproject.org/Errors/Details/132823/"
-PNBLACKLIST[kexecboot-klibc] ?= "Fails to build with RSS http://errors.yoctoproject.org/Errors/Details/132853/"
Signature · 1 line
2.7.4
#7 lore raw

h[meta-initramfs][PATCH 7/9] initramfs-kexecboot-klibc-image: remove blacklisting

In reply to Andrea Adami

Recipe does build with the pending changes for meta-initramfs.

---
 meta-initramfs/recipes-bsp/images/initramfs-kexecboot-klibc-image.bb | 2 --
 1 file changed, 2 deletions(-)
meta-initramfs/recipes-bsp/images/initramfs-kexecboot-klibc-image.bb +0 -2
index 8010c91..6b845bd 100644
@@ -10,5 +10,3 @@ python () {
     if d.getVar('TARGET_ARCH') == "nios2":
         raise bb.parse.SkipPackage("'nios2' not supported arch")
 }
-
-PNBLACKLIST[initramfs-kexecboot-klibc-image] ?= "Runtime depends on blacklisted kexecboot-klibc"
Signature · 1 line
2.7.4
#8 lore raw

PATCH 8/9 klibc-utils_2.0.4: remove blacklisting

In reply to Andrea Adami

Recipe does build with the pending changes for meta-initramfs.

---
 meta-initramfs/recipes-devtools/klibc/klibc-utils_2.0.4.bb | 2 --
 1 file changed, 2 deletions(-)
meta-initramfs/recipes-devtools/klibc/klibc-utils_2.0.4.bb +0 -2
index ebf43bd..06e71cb 100644
@@ -12,5 +12,3 @@ require klibc-utils.inc
 require klibc.inc
 
 DEPENDS = "klibc"
-
-PNBLACKLIST[klibc-utils] ?= "Fails to build with RSS http://errors.yoctoproject.org/Errors/Details/130679/"
Signature · 1 line
2.7.4
#9 lore raw

PATCH 9/9 kexec-tools-klibc_2.0.2: remove blacklisting

In reply to Andrea Adami

Recipe does build with the pending changes for meta-initramfs.

---
 meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_2.0.2.bb | 2 --
 1 file changed, 2 deletions(-)
meta-initramfs/recipes-kernel/kexec/kexec-tools-klibc_2.0.2.bb +0 -2
index 0e97046..c9fec25 100644
@@ -38,5 +38,3 @@ PACKAGES =+ "kexec-klibc kdump-klibc"
 
 FILES_kexec-klibc = "${sbindir}/kexec"
 FILES_kdump-klibc = "${sbindir}/kdump"
-
-PNBLACKLIST[kexec-tools-klibc] ?= "Fails to build with RSS http://errors.yoctoproject.org/Errors/Details/130674/"
Signature · 1 line
2.7.4