diff options
author | W. Michael Petullo <mike@flyn.org> | 2014-07-16 22:12:38 -0400 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2014-07-19 14:08:11 +0200 |
commit | 45150b3585c67a931b6600e7c16092fe69d66306 (patch) | |
tree | 4bedbea6bef76417f23c662dbbfb4e7d23083d28 /libs/libmpeg2/patches | |
parent | d81d7ebe5ea866c74c8ee214eea77edbefd9d934 (diff) |
Copy libmpeg2 package from old repository
Signed-off-by: W. Michael Petullo <mike@flyn.org>
Diffstat (limited to 'libs/libmpeg2/patches')
-rw-r--r-- | libs/libmpeg2/patches/101-ppc_no_altivec.patch | 66 | ||||
-rw-r--r-- | libs/libmpeg2/patches/102-arm_data_preload_check.patch | 19 |
2 files changed, 85 insertions, 0 deletions
diff --git a/libs/libmpeg2/patches/101-ppc_no_altivec.patch b/libs/libmpeg2/patches/101-ppc_no_altivec.patch new file mode 100644 index 000000000..49251a098 --- /dev/null +++ b/libs/libmpeg2/patches/101-ppc_no_altivec.patch @@ -0,0 +1,66 @@ +--- a/libmpeg2/motion_comp_altivec.c ++++ b/libmpeg2/motion_comp_altivec.c +@@ -25,6 +25,8 @@ + + #ifdef ARCH_PPC + ++#ifdef __I_WANT_ALTIVEC__ ++ + #ifdef HAVE_ALTIVEC_H + #include <altivec.h> + #endif +@@ -1007,4 +1009,6 @@ static void MC_avg_xy_8_altivec (uint8_t + + MPEG2_MC_EXTERN (altivec) + ++#endif /* __I_WANT_ALTIVEC__ */ ++ + #endif +--- a/libmpeg2/idct_altivec.c ++++ b/libmpeg2/idct_altivec.c +@@ -25,6 +25,8 @@ + + #ifdef ARCH_PPC + ++#ifdef __I_WANT_ALTIVEC__ ++ + #ifdef HAVE_ALTIVEC_H + #include <altivec.h> + #endif +@@ -283,4 +285,6 @@ void mpeg2_idct_altivec_init (void) + } + } + ++#endif /* __I_WANT_ALTIVEC__ */ ++ + #endif +--- a/libmpeg2/idct.c ++++ b/libmpeg2/idct.c +@@ -251,11 +251,13 @@ void mpeg2_idct_init (uint32_t accel) + } else + #endif + #ifdef ARCH_PPC ++#ifdef __I_WANT_ALTIVEC__ + if (accel & MPEG2_ACCEL_PPC_ALTIVEC) { + mpeg2_idct_copy = mpeg2_idct_copy_altivec; + mpeg2_idct_add = mpeg2_idct_add_altivec; + mpeg2_idct_altivec_init (); + } else ++#endif /* __I_WANT_ALTIVEC__ */ + #endif + #ifdef ARCH_ALPHA + if (accel & MPEG2_ACCEL_ALPHA_MVI) { +--- a/libmpeg2/motion_comp.c ++++ b/libmpeg2/motion_comp.c +@@ -43,9 +43,11 @@ void mpeg2_mc_init (uint32_t accel) + else + #endif + #ifdef ARCH_PPC ++#ifdef __I_WANT_ALTIVEC__ + if (accel & MPEG2_ACCEL_PPC_ALTIVEC) + mpeg2_mc = mpeg2_mc_altivec; + else ++#endif /* __I_WANT_ALTIVEC__ */ + #endif + #ifdef ARCH_ALPHA + if (accel & MPEG2_ACCEL_ALPHA) diff --git a/libs/libmpeg2/patches/102-arm_data_preload_check.patch b/libs/libmpeg2/patches/102-arm_data_preload_check.patch new file mode 100644 index 000000000..86793fcd7 --- /dev/null +++ b/libs/libmpeg2/patches/102-arm_data_preload_check.patch @@ -0,0 +1,19 @@ +diff -urN libmpeg2-0.5.1/libmpeg2/motion_comp_arm_s.S libmpeg2-0.5.1.new/libmpeg2/motion_comp_arm_s.S +--- libmpeg2-0.5.1/libmpeg2/motion_comp_arm_s.S 2008-07-09 21:16:05.000000000 +0200 ++++ libmpeg2-0.5.1.new/libmpeg2/motion_comp_arm_s.S 2012-07-30 15:22:58.664964215 +0200 +@@ -19,6 +19,15 @@ + @ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + ++@ Data preload is supported only by ARM V5TE and above ++ ++#if (defined (__ARM_ARCH_2__) || defined (__ARM_ARCH_3__) \ ++ || defined (__ARM_ARCH_3M__) || defined (__ARM_ARCH_4__) \ ++ || defined (__ARM_ARCH_4T__) || defined (__ARM_ARCH_5__) \ ++ || defined (__ARM_ARCH_5T__)) ++.macro pld reg ++.endm ++#endif + .text + + @ ---------------------------------------------------------------- |