1 |
commit: 432f45bd8ece2a10ea64b7b07f951d0ac6aa0666 |
2 |
Author: Jeroen Roovers <jer <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Oct 17 12:40:22 2018 +0000 |
4 |
Commit: Jeroen Roovers <jer <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Oct 17 12:48:21 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=432f45bd |
7 |
|
8 |
media-libs/x265: Let everybody have detect512 |
9 |
|
10 |
Upstream commit d55132eb4201 introduced detect512() but the function is |
11 |
defined only when X265_ARCH_X86 so the linker fails with non x86 |
12 |
targets: |
13 |
|
14 |
libx265.so.165: undefined reference to `x265_12bit::detect512()' |
15 |
libx265.so.165: undefined reference to `x265_10bit::detect512()' |
16 |
libx265.so.165: undefined reference to `x265::detect512()' |
17 |
|
18 |
Fix it by defining the function unconditionally. |
19 |
|
20 |
Package-Manager: Portage-2.3.51, Repoman-2.3.11 |
21 |
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org> |
22 |
|
23 |
media-libs/x265/files/x265-2.9-detect512.patch | 25 +++++++++++++++++++++++++ |
24 |
media-libs/x265/x265-2.9.ebuild | 1 + |
25 |
2 files changed, 26 insertions(+) |
26 |
|
27 |
diff --git a/media-libs/x265/files/x265-2.9-detect512.patch b/media-libs/x265/files/x265-2.9-detect512.patch |
28 |
new file mode 100644 |
29 |
index 00000000000..8437ed09b88 |
30 |
--- /dev/null |
31 |
+++ b/media-libs/x265/files/x265-2.9-detect512.patch |
32 |
@@ -0,0 +1,25 @@ |
33 |
+--- a/source/common/cpu.cpp |
34 |
++++ b/source/common/cpu.cpp |
35 |
+@@ -110,6 +110,11 @@ |
36 |
+ { "", 0 }, |
37 |
+ }; |
38 |
+ |
39 |
++bool detect512() |
40 |
++{ |
41 |
++ return(enable512); |
42 |
++} |
43 |
++ |
44 |
+ #if X265_ARCH_X86 |
45 |
+ |
46 |
+ extern "C" { |
47 |
+@@ -123,10 +128,6 @@ |
48 |
+ #pragma warning(disable: 4309) // truncation of constant value |
49 |
+ #endif |
50 |
+ |
51 |
+-bool detect512() |
52 |
+-{ |
53 |
+- return(enable512); |
54 |
+-} |
55 |
+ uint32_t cpu_detect(bool benableavx512 ) |
56 |
+ { |
57 |
+ |
58 |
|
59 |
diff --git a/media-libs/x265/x265-2.9.ebuild b/media-libs/x265/x265-2.9.ebuild |
60 |
index b62476a545d..38316ce55ea 100644 |
61 |
--- a/media-libs/x265/x265-2.9.ebuild |
62 |
+++ b/media-libs/x265/x265-2.9.ebuild |
63 |
@@ -31,6 +31,7 @@ PATCHES=( |
64 |
"${FILESDIR}/arm.patch" |
65 |
"${FILESDIR}/neon.patch" |
66 |
"${FILESDIR}/ppc64.patch" |
67 |
+ "${FILESDIR}"/${PN}-2.9-detect512.patch |
68 |
) |
69 |
|
70 |
src_unpack() { |