diff options
Diffstat (limited to 'meta/recipes-multimedia')
3 files changed, 122 insertions, 1 deletions
diff --git a/meta/recipes-multimedia/mpeg2dec/files/0001-check-for-available-arm-optimizations.patch b/meta/recipes-multimedia/mpeg2dec/files/0001-check-for-available-arm-optimizations.patch new file mode 100644 index 0000000000..5bf68b39ee --- /dev/null +++ b/meta/recipes-multimedia/mpeg2dec/files/0001-check-for-available-arm-optimizations.patch | |||
@@ -0,0 +1,55 @@ | |||
1 | From cbcff58ed670c8edc0be1004384cbe0fd07d8d26 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Wed, 5 Jul 2017 18:49:21 -0700 | ||
4 | Subject: [PATCH 1/2] check for available arm optimizations | ||
5 | |||
6 | Taken From | ||
7 | http://sources.debian.net/src/mpeg2dec/0.5.1-7/debian/patches/65_arm-test-with-compiler.patch/ | ||
8 | |||
9 | Upstream-Status: Pending | ||
10 | |||
11 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
12 | --- | ||
13 | configure.ac | 12 ++++++++---- | ||
14 | 1 file changed, 8 insertions(+), 4 deletions(-) | ||
15 | |||
16 | diff --git a/configure.ac b/configure.ac | ||
17 | index acdcb1e..2c0a721 100644 | ||
18 | --- a/configure.ac | ||
19 | +++ b/configure.ac | ||
20 | @@ -59,7 +59,7 @@ elif test x"$GCC" = x"yes"; then | ||
21 | AC_TRY_CFLAGS([$TRY_CFLAGS $CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"]) | ||
22 | |||
23 | dnl arch-specific flags | ||
24 | - arm_conditional=false | ||
25 | + build_arm_opt=false | ||
26 | case "$host" in | ||
27 | i?86-* | k?-* | x86_64-* | amd64-*) | ||
28 | AC_DEFINE([ARCH_X86],,[x86 architecture]) | ||
29 | @@ -102,8 +102,12 @@ elif test x"$GCC" = x"yes"; then | ||
30 | alpha*) | ||
31 | AC_DEFINE([ARCH_ALPHA],,[alpha architecture]);; | ||
32 | arm*) | ||
33 | - arm_conditional=: | ||
34 | - AC_DEFINE([ARCH_ARM],,[ARM architecture]);; | ||
35 | + AC_LANG(C) | ||
36 | + AC_COMPILE_IFELSE( | ||
37 | + [AC_LANG_SOURCE([[ | ||
38 | + void foo(void) { __asm__ volatile("pld [r1]"); }]])], | ||
39 | + build_arm_opt=true; AC_DEFINE([ARCH_ARM],,[ARM architecture]), | ||
40 | + build_arm_opt=false);; | ||
41 | esac | ||
42 | elif test x"$CC" = x"tendracc"; then | ||
43 | dnl TenDRA portability checking compiler | ||
44 | @@ -123,7 +127,7 @@ else | ||
45 | esac | ||
46 | fi | ||
47 | |||
48 | -AM_CONDITIONAL(ARCH_ARM, ${arm_conditional}) | ||
49 | +AM_CONDITIONAL(ARCH_ARM, test x$build_arm_opt = xtrue) | ||
50 | |||
51 | dnl Checks for libtool - this must be done after we set cflags | ||
52 | AC_LIBTOOL_WIN32_DLL | ||
53 | -- | ||
54 | 2.13.2 | ||
55 | |||
diff --git a/meta/recipes-multimedia/mpeg2dec/files/0002-Set-visibility-of-global-symbols-used-in-ARM-specifi.patch b/meta/recipes-multimedia/mpeg2dec/files/0002-Set-visibility-of-global-symbols-used-in-ARM-specifi.patch new file mode 100644 index 0000000000..8301692368 --- /dev/null +++ b/meta/recipes-multimedia/mpeg2dec/files/0002-Set-visibility-of-global-symbols-used-in-ARM-specifi.patch | |||
@@ -0,0 +1,63 @@ | |||
1 | From f9d9dc92d75f8910e3cd5fdcbea72e505cdf3493 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Wed, 5 Jul 2017 19:03:36 -0700 | ||
4 | Subject: [PATCH 2/2] Set visibility of global symbols used in ARM specific | ||
5 | assembly file to internal | ||
6 | |||
7 | Taken from | ||
8 | http://sources.debian.net/src/mpeg2dec/0.5.1-7/debian/patches/60_arm-private-symbols.patch/ | ||
9 | |||
10 | Upstream-Status: Pending | ||
11 | |||
12 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
13 | --- | ||
14 | libmpeg2/motion_comp_arm_s.S | 12 ++++++++---- | ||
15 | 1 file changed, 8 insertions(+), 4 deletions(-) | ||
16 | |||
17 | diff --git a/libmpeg2/motion_comp_arm_s.S b/libmpeg2/motion_comp_arm_s.S | ||
18 | index f6c3d7d..c921f7c 100644 | ||
19 | --- a/libmpeg2/motion_comp_arm_s.S | ||
20 | +++ b/libmpeg2/motion_comp_arm_s.S | ||
21 | @@ -23,7 +23,8 @@ | ||
22 | |||
23 | @ ---------------------------------------------------------------- | ||
24 | .align | ||
25 | - .global MC_put_o_16_arm | ||
26 | + .global MC_put_o_16_arm | ||
27 | + .internal MC_put_o_16_arm | ||
28 | MC_put_o_16_arm: | ||
29 | @@ void func(uint8_t * dest, const uint8_t * ref, int stride, int height) | ||
30 | pld [r1] | ||
31 | @@ -83,7 +84,8 @@ MC_put_o_16_arm_align_jt: | ||
32 | |||
33 | @ ---------------------------------------------------------------- | ||
34 | .align | ||
35 | - .global MC_put_o_8_arm | ||
36 | + .global MC_put_o_8_arm | ||
37 | + .internal MC_put_o_8_arm | ||
38 | MC_put_o_8_arm: | ||
39 | @@ void func(uint8_t * dest, const uint8_t * ref, int stride, int height) | ||
40 | pld [r1] | ||
41 | @@ -152,7 +154,8 @@ MC_put_o_8_arm_align_jt: | ||
42 | .endm | ||
43 | |||
44 | .align | ||
45 | - .global MC_put_x_16_arm | ||
46 | + .global MC_put_x_16_arm | ||
47 | + .internal MC_put_x_16_arm | ||
48 | MC_put_x_16_arm: | ||
49 | @@ void func(uint8_t * dest, const uint8_t * ref, int stride, int height) | ||
50 | pld [r1] | ||
51 | @@ -244,7 +247,8 @@ MC_put_x_16_arm_align_jt: | ||
52 | |||
53 | @ ---------------------------------------------------------------- | ||
54 | .align | ||
55 | - .global MC_put_x_8_arm | ||
56 | + .global MC_put_x_8_arm | ||
57 | + .internal MC_put_x_8_arm | ||
58 | MC_put_x_8_arm: | ||
59 | @@ void func(uint8_t * dest, const uint8_t * ref, int stride, int height) | ||
60 | pld [r1] | ||
61 | -- | ||
62 | 2.13.2 | ||
63 | |||
diff --git a/meta/recipes-multimedia/mpeg2dec/mpeg2dec_0.5.1.bb b/meta/recipes-multimedia/mpeg2dec/mpeg2dec_0.5.1.bb index 8e995daa7c..7711c2dc10 100644 --- a/meta/recipes-multimedia/mpeg2dec/mpeg2dec_0.5.1.bb +++ b/meta/recipes-multimedia/mpeg2dec/mpeg2dec_0.5.1.bb | |||
@@ -7,7 +7,10 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \ | |||
7 | file://include/mpeg2.h;beginline=1;endline=22;md5=7766f4fcb58f0f8413c49a746f2ab89b" | 7 | file://include/mpeg2.h;beginline=1;endline=22;md5=7766f4fcb58f0f8413c49a746f2ab89b" |
8 | 8 | ||
9 | SRC_URI = "http://libmpeg2.sourceforge.net/files/libmpeg2-${PV}.tar.gz \ | 9 | SRC_URI = "http://libmpeg2.sourceforge.net/files/libmpeg2-${PV}.tar.gz \ |
10 | file://altivec_h_needed.patch" | 10 | file://altivec_h_needed.patch \ |
11 | file://0001-check-for-available-arm-optimizations.patch \ | ||
12 | file://0002-Set-visibility-of-global-symbols-used-in-ARM-specifi.patch \ | ||
13 | " | ||
11 | 14 | ||
12 | S = "${WORKDIR}/libmpeg2-${PV}" | 15 | S = "${WORKDIR}/libmpeg2-${PV}" |
13 | 16 | ||