1 Description: Fix build problem on mips*
2 Make sure required defines are set on mips.
3 Author: YunQiang Su <wzssyqa@gmail.com>
4 Bug-Debian: https://bugs.debian.org/824190
5 Bug: https://github.com/zfsonlinux/zfs/pull/4712
6 Reviewed-By: Petter Reinholdtsen <pere@hungry.com>
7 Last-Update: 2016-05-25
8 Applied-upstream: https://github.com/zfsonlinux/zfs/commit/2493dca54e18b24bcd8b7ff5432f4dc51dddc472
10 Index: zfs-linux-0.6.5.6/lib/libspl/include/sys/isa_defs.h
11 ===================================================================
12 --- zfs-linux-0.6.5.6.orig/lib/libspl/include/sys/isa_defs.h
13 +++ zfs-linux-0.6.5.6/lib/libspl/include/sys/isa_defs.h
14 @@ -172,7 +172,24 @@ extern "C" {
16 #define _SUNOS_VTOC_16
18 -#else /* Currently x86_64, i386, arm, powerpc, s390, and sparc are supported */
19 +/* MIPS arch specific defines */
20 +#elif defined(__mips__)
22 +#if defined(__MIPSEB__)
24 +#elif defined(__MIPSEL__)
25 +#define _LITTLE_ENDIAN
27 +#error MIPS no endian specified
34 +#define _SUNOS_VTOC_16
36 +#else /* Currently x86_64, i386, arm, powerpc, s390, sparc and mips are supported */
37 #error "Unsupported ISA type"
40 Index: zfs-linux-0.6.5.6/lib/libefi/rdwr_efi.c
41 ===================================================================
42 --- zfs-linux-0.6.5.6.orig/lib/libefi/rdwr_efi.c
43 +++ zfs-linux-0.6.5.6/lib/libefi/rdwr_efi.c
44 @@ -88,7 +88,8 @@ struct dk_map2 default_vtoc_map[NDKMAP]
45 #if defined(_SUNOS_VTOC_16)
47 #if defined(i386) || defined(__amd64) || defined(__arm) || \
48 - defined(__powerpc) || defined(__sparc) || defined(__s390__)
49 + defined(__powerpc) || defined(__sparc) || defined(__s390__) || \
51 { V_BOOT, V_UNMNT }, /* i - 8 */
52 { V_ALTSCTR, 0 }, /* j - 9 */