From: Petr Kubizňák Date: Wed, 4 Jan 2023 11:45:55 +0000 (+0100) Subject: harfbuzz: remove bindir only if it exists X-Git-Tag: 2023-04-mickledore~833 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=21261072cbe0056e85550a0710de142fab8943e4;p=thirdparty%2Fopenembedded%2Fopenembedded-core.git harfbuzz: remove bindir only if it exists In some scenarios (e.g. when "glib" removed from PACKAGECONFIG), "${D}${bindir}" might not exist which caused `rmdir` to fail. Signed-off-by: Petr Kubizňák Signed-off-by: Alexandre Belloni Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-graphics/harfbuzz/harfbuzz_6.0.0.bb b/meta/recipes-graphics/harfbuzz/harfbuzz_6.0.0.bb index 46ab6a4ca81..ae54bad643f 100644 --- a/meta/recipes-graphics/harfbuzz/harfbuzz_6.0.0.bb +++ b/meta/recipes-graphics/harfbuzz/harfbuzz_6.0.0.bb @@ -30,9 +30,9 @@ PACKAGES =+ "${PN}-icu ${PN}-icu-dev ${PN}-subset" LEAD_SONAME = "libharfbuzz.so" do_install:append() { - # If no tools are installed due to PACKAGECONFIG then this directory is - #still installed, so remove it to stop packaging wanings. - rmdir --ignore-fail-on-non-empty ${D}${bindir} + # If no tools are installed due to PACKAGECONFIG then this directory might + # still be installed, so remove it to stop packaging warnings. + [ ! -d ${D}${bindir} ] || rmdir --ignore-fail-on-non-empty ${D}${bindir} } FILES:${PN}-icu = "${libdir}/libharfbuzz-icu.so.*"