python-dataproperty: bump version to 0.17.0
[buildroot-gz.git] / package / libmad / 0001-mips-h-constraint-removal.patch
blob095858717eec7e4ed2b837ac0f2dd3fd460875e5
1 http://patchwork.openembedded.org/patch/921/
3 diff -ur libmad-0.15.1b-orig/fixed.h libmad-0.15.1b/fixed.h
4 --- libmad-0.15.1b-orig/fixed.h 2004-02-17 12:32:03.000000000 +1030
5 +++ libmad-0.15.1b/fixed.h 2009-08-05 10:46:30.000000000 +0930
6 @@ -299,6 +299,23 @@
8 # elif defined(FPM_MIPS)
10 +/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
11 +#if defined (__GNUC__) && defined (__GNUC_MINOR__)
12 +#define __GNUC_PREREQ(maj, min) \
13 + ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
14 +#else
15 +#define __GNUC_PREREQ(maj, min) 0
16 +#endif
18 +#if __GNUC_PREREQ(4,4)
19 + typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
20 +# define MAD_F_MLX(hi, lo, x, y) \
21 + do { \
22 + u64_di_t __ll = (u64_di_t) (x) * (y); \
23 + hi = __ll >> 32; \
24 + lo = __ll; \
25 + } while (0)
26 +#else
28 * This MIPS version is fast and accurate; the disposition of the least
29 * significant bit depends on OPT_ACCURACY via mad_f_scale64().
30 @@ -328,6 +345,7 @@
31 : "%r" ((x) >> 12), "r" ((y) >> 16))
32 # define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
33 # endif
34 +#endif /* __GNU_PREREQ(4,4) */
36 # if defined(OPT_SPEED)
37 # define mad_f_scale64(hi, lo) \
38 diff -ur libmad-0.15.1b-orig/mad.h libmad-0.15.1b/mad.h
39 --- libmad-0.15.1b-orig/mad.h 2004-02-17 13:25:44.000000000 +1030
40 +++ libmad-0.15.1b/mad.h 2009-08-05 10:42:40.000000000 +0930
41 @@ -344,6 +344,23 @@
43 # elif defined(FPM_MIPS)
45 +/* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */
46 +#if defined (__GNUC__) && defined (__GNUC_MINOR__)
47 +#define __GNUC_PREREQ(maj, min) \
48 + ((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
49 +#else
50 +#define __GNUC_PREREQ(maj, min) 0
51 +#endif
53 +#if __GNUC_PREREQ(4,4)
54 + typedef unsigned int u64_di_t __attribute__ ((mode (DI)));
55 +# define MAD_F_MLX(hi, lo, x, y) \
56 + do { \
57 + u64_di_t __ll = (u64_di_t) (x) * (y); \
58 + hi = __ll >> 32; \
59 + lo = __ll; \
60 + } while (0)
61 +#else
63 * This MIPS version is fast and accurate; the disposition of the least
64 * significant bit depends on OPT_ACCURACY via mad_f_scale64().
65 @@ -373,6 +390,7 @@
66 : "%r" ((x) >> 12), "r" ((y) >> 16))
67 # define MAD_F_MLZ(hi, lo) ((mad_fixed_t) (lo))
68 # endif
69 +#endif /* __GNU_PREREQ(4,4) */
71 # if defined(OPT_SPEED)
72 # define mad_f_scale64(hi, lo) \