diff --git a/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch b/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch new file mode 100644 index 0000000000..d545146912 --- /dev/null +++ b/meta/recipes-devtools/squashfs-tools/squashfs-tools/fix-compat.patch @@ -0,0 +1,63 @@ +Define FNM_EXTMATCH if not defined its glibc specific define +include missing sys/stat.h for stat* function declarations + +Upstream-Status: Pending +Signed-off-by: Khem Raj + +Index: squashfs-tools/action.c +=================================================================== +--- squashfs-tools.orig/action.c ++++ squashfs-tools/action.c +@@ -44,6 +44,10 @@ + #include "action.h" + #include "error.h" + ++#if !defined(FNM_EXTMATCH) ++#define FNM_EXTMATCH 0 ++#endif ++ + /* + * code to parse actions + */ +Index: squashfs-tools/mksquashfs.c +=================================================================== +--- squashfs-tools.orig/mksquashfs.c ++++ squashfs-tools/mksquashfs.c +@@ -1286,6 +1286,10 @@ void write_dir(squashfs_inode *inode, st + dir_size + 3, directory_block, directory_offset, NULL, NULL, + dir, 0); + ++#if !defined(FNM_EXTMATCH) ++#define FNM_EXTMATCH 0 ++#endif ++ + #ifdef SQUASHFS_TRACE + { + unsigned char *dirp; +Index: squashfs-tools/pseudo.c +=================================================================== +--- squashfs-tools.orig/pseudo.c ++++ squashfs-tools/pseudo.c +@@ -32,6 +32,7 @@ + #include + #include + #include ++#include + #include + + #include "pseudo.h" +Index: squashfs-tools/unsquashfs.c +=================================================================== +--- squashfs-tools.orig/unsquashfs.c ++++ squashfs-tools/unsquashfs.c +@@ -38,6 +38,10 @@ + #include + #include + ++#ifndef FNM_EXTMATCH ++#define FNM_EXTMATCH 0 ++#endif ++ + struct cache *fragment_cache, *data_cache; + struct queue *to_reader, *to_inflate, *to_writer, *from_writer; + pthread_t *thread, *inflator_thread; diff --git a/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb b/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb index 7aebd00e0b..33ed09ae8a 100644 --- a/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb +++ b/meta/recipes-devtools/squashfs-tools/squashfs-tools_git.bb @@ -13,6 +13,7 @@ SRCREV = "9c1db6d13a51a2e009f0027ef336ce03624eac0d" SRC_URI = "git://github.com/plougher/squashfs-tools.git;protocol=https \ http://downloads.sourceforge.net/sevenzip/lzma465.tar.bz2;name=lzma \ file://0001-mksquashfs.c-get-inline-functions-work-with-C99.patch;striplevel=2 \ + file://fix-compat.patch \ " SRC_URI[lzma.md5sum] = "29d5ffd03a5a3e51aef6a74e9eafb759" SRC_URI[lzma.sha256sum] = "c935fd04dd8e0e8c688a3078f3675d699679a90be81c12686837e0880aa0fa1e"