From: Maxime Roussin-Bélanger Date: Tue, 21 Jun 2022 14:26:19 +0000 (-0400) Subject: libffi: fix native build being not portable X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~3826 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=cddaecac1fdd4d033c2ff8ccaf1d60e1c598d5b7;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git libffi: fix native build being not portable Without `--with-gcc-arch=generic` libffi looks up the cpuid to automatically determine which mtune/march to use. This makes the native sstate-cache unuseable since it's possible to have a newer cpu building the recipe and the library being pulled from another older cpu which doesn't have the instruction. Signed-off-by: Maxime Roussin-Bélanger Signed-off-by: Luca Ceresoli Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-support/libffi/libffi_3.4.2.bb b/meta/recipes-support/libffi/libffi_3.4.2.bb index 733fcc5e6ca..71d9518baf8 100644 --- a/meta/recipes-support/libffi/libffi_3.4.2.bb +++ b/meta/recipes-support/libffi/libffi_3.4.2.bb @@ -19,6 +19,7 @@ UPSTREAM_CHECK_URI = "https://github.com/libffi/libffi/releases/" UPSTREAM_CHECK_REGEX = "libffi-(?P\d+(\.\d+)+)\.tar" EXTRA_OECONF += "--disable-builddir --disable-exec-static-tramp" +EXTRA_OECONF:class-native += "--with-gcc-arch=generic" EXTRA_OEMAKE:class-target = "LIBTOOLFLAGS='--tag=CC'" inherit autotools texinfo multilib_header @@ -33,4 +34,3 @@ FILES:${PN}-dev += "${libdir}/libffi-${PV}" MIPS_INSTRUCTION_SET = "mips" BBCLASSEXTEND = "native nativesdk" -