image: update LZMA_XZ_OPTIONS with new squashfs4 tool
[openwrt/staging/aparcar.git] / tools / squashfskit4 / patches / 0010-portability.patch
1 --- a/squashfs-tools/xattr.c
2 +++ b/squashfs-tools/xattr.c
3 @@ -113,6 +113,7 @@ static int get_prefix(struct xattr_list
4
5 static int read_xattrs_from_system(char *filename, struct xattr_list **xattrs)
6 {
7 +#if defined(linux)
8 ssize_t size, vsize;
9 char *xattr_names, *p;
10 int i;
11 @@ -222,6 +223,10 @@ failed:
12 free(xattr_list);
13 free(xattr_names);
14 return 0;
15 +#else
16 + *xattrs = NULL;
17 + return 0;
18 +#endif
19 }
20
21
22 --- a/squashfs-tools/unsquashfs_xattr.c
23 +++ b/squashfs-tools/unsquashfs_xattr.c
24 @@ -34,6 +34,7 @@ extern int user_xattrs;
25
26 void write_xattr(char *pathname, unsigned int xattr)
27 {
28 +#if defined(linux)
29 unsigned int count;
30 struct xattr_list *xattr_list;
31 int i;
32 @@ -136,4 +137,5 @@ void write_xattr(char *pathname, unsigne
33 }
34
35 free_xattr(xattr_list, count);
36 +#endif
37 }