From d74ff59aa8050b9b477b006c60976992dabbd97d Mon Sep 17 00:00:00 2001 From: Robert Yang Date: Tue, 13 May 2025 07:10:14 -0700 Subject: [PATCH] coreutils: Drop 0001-local.mk-fix-cross-compiling-problem.patch The patch is used for fixing: | Makefile:3418: *** Recursive variable 'INSTALL' references itself (eventually). Stop. Now the code and check and set that correctly: if CROSS_COMPILING cu_install_program = @INSTALL@ else cu_install_program = src/ginstall endif So just drop the patch. And also remove the ginstall hack to fix ptest case failure when single-binary is enabled, I can't find the reason on why it was needed from git log. Fixed: install: missing file operand Try 'install --help' for more information. * Reproducer: DISTRO_FEATURES:append = " ptest" EXTRA_IMAGE_FEATURES:append = " ptest-pkgs" IMAGE_INSTALL:append = " coreutils" PACKAGECONFIG:append:pn-coreutils = " single-binary" $ bitbake core-image-sato $ runqemu tmp/deploy/images/qemux86-64/ nographic kvm On target: $ cd /usr/lib/coreutils/ptest $ ./run-ptest ============================================================================ Testsuite summary for GNU coreutils 9.6 ============================================================================ TOTAL: 655 PASS: 529 SKIP: 126 XFAIL: 0 FAIL: 0 XPASS: 0 ERROR: 0 ============================================================================ make[1]: Leaving directory '/usr/lib/coreutils/ptest' (From OE-Core rev: 8728815f74f73723e86ba25b56a66b3fb46d6596) Signed-off-by: Robert Yang Signed-off-by: Richard Purdie --- ...local.mk-fix-cross-compiling-problem.patch | 26 ------------------- meta/recipes-core/coreutils/coreutils_9.6.bb | 3 --- 2 files changed, 29 deletions(-) delete mode 100644 meta/recipes-core/coreutils/coreutils/0001-local.mk-fix-cross-compiling-problem.patch diff --git a/meta/recipes-core/coreutils/coreutils/0001-local.mk-fix-cross-compiling-problem.patch b/meta/recipes-core/coreutils/coreutils/0001-local.mk-fix-cross-compiling-problem.patch deleted file mode 100644 index 97a6357ab9..0000000000 --- a/meta/recipes-core/coreutils/coreutils/0001-local.mk-fix-cross-compiling-problem.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 7cb2d20cfa2a27191255031d231cd41917dcffe8 Mon Sep 17 00:00:00 2001 -From: Chen Qi -Date: Mon, 26 Dec 2016 16:10:35 +0800 -Subject: [PATCH] local.mk: fix cross compiling problem - -We meet the following error when cross compiling. -| Makefile:3418: *** Recursive variable 'INSTALL' references itself (eventually). Stop. -This patch fixes this problem. - -Upstream-Status: Pending - -Signed-off-by: Chen Qi ---- - src/local.mk | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/local.mk b/src/local.mk -index 96ee941..cdd47d6 100644 ---- a/src/local.mk -+++ b/src/local.mk -@@ -704,4 +704,4 @@ cu_install_program = @INSTALL@ - else - cu_install_program = src/ginstall - endif --INSTALL = $(cu_install_program) -c -+INSTALL_PROGRAM = $(cu_install_program) diff --git a/meta/recipes-core/coreutils/coreutils_9.6.bb b/meta/recipes-core/coreutils/coreutils_9.6.bb index 3eb0c6fd1b..a966c4b448 100644 --- a/meta/recipes-core/coreutils/coreutils_9.6.bb +++ b/meta/recipes-core/coreutils/coreutils_9.6.bb @@ -15,7 +15,6 @@ inherit autotools gettext texinfo SRC_URI = "${GNU_MIRROR}/coreutils/${BP}.tar.xz \ file://remove-usr-local-lib-from-m4.patch \ - file://0001-local.mk-fix-cross-compiling-problem.patch \ file://intermittent-testfailure.patch \ file://0001-ls-fix-crash-with-context.patch \ file://0001-cksum-port-to-32-bit-uint_fast32_t.patch \ @@ -184,7 +183,6 @@ RRECOMMENDS:${PN}-dev += "${DEVDEPS}" do_install_ptest () { install -d ${D}${PTEST_PATH}/tests cp -r ${S}/tests/* ${D}${PTEST_PATH}/tests - sed -i 's/ginstall/install/g' `grep -R ginstall ${D}${PTEST_PATH}/tests | awk -F: '{print $1}' | uniq` install -d ${D}${PTEST_PATH}/build-aux install ${S}/build-aux/test-driver ${D}${PTEST_PATH}/build-aux/ install -Dm 0644 ${B}/lib/config.h ${D}${PTEST_PATH}/lib/config.h @@ -198,7 +196,6 @@ do_install_ptest () { sed -i '/^abs_srcdir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile sed -i '/^abs_top_builddir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile sed -i '/^abs_top_srcdir/s/= .*$/= \$\{PWD\}/g' ${D}${PTEST_PATH}/Makefile - sed -i '/^built_programs/s/ginstall/install/g' ${D}${PTEST_PATH}/Makefile sed -i '/^CC =/s/ --sysroot=.*recipe-sysroot/ /g' ${D}${PTEST_PATH}/Makefile sed -i '/^BUILD_LDFLAGS =/d' ${D}${PTEST_PATH}/Makefile chmod -R 777 ${D}${PTEST_PATH}