summaryrefslogtreecommitdiffstats
path: root/meta/recipes-support/diffoscope
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2021-02-23 18:44:22 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2021-02-23 22:31:55 +0000
commit3488a8316891829892bd41a1caacaeeef73da7ef (patch)
tree37871267b32ed102bc5f34176c523e83170ddfa3 /meta/recipes-support/diffoscope
parenta5afd7b1857c0012ab6e3d8bbafa67a96ff9e9e0 (diff)
downloadopenembedded-core-3488a8316891829892bd41a1caacaeeef73da7ef.tar.gz
openembedded-core-3488a8316891829892bd41a1caacaeeef73da7ef.tar.bz2
openembedded-core-3488a8316891829892bd41a1caacaeeef73da7ef.zip
diffoscope: Ensure the correct magic file is used
diffoscope uses libmagic and it was searching in file-native's sysroot for the magic file. Wrap it and set MAGIC in the environment to ensure the file is found correctly and avoid build failures. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-support/diffoscope')
-rw-r--r--meta/recipes-support/diffoscope/diffoscope_167.bb4
1 files changed, 4 insertions, 0 deletions
diff --git a/meta/recipes-support/diffoscope/diffoscope_167.bb b/meta/recipes-support/diffoscope/diffoscope_167.bb
index 9ce59a0ba0..1882d549a4 100644
--- a/meta/recipes-support/diffoscope/diffoscope_167.bb
+++ b/meta/recipes-support/diffoscope/diffoscope_167.bb
@@ -14,4 +14,8 @@ RDEPENDS_${PN} += "binutils vim squashfs-tools python3-libarchive-c python3-magi
# Dependencies don't build for musl
COMPATIBLE_HOST_libc-musl = 'null'
+do_install_append_class-native() {
+ create_wrapper ${D}${bindir}/diffoscope MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc
+}
+
BBCLASSEXTEND = "native"