1 |
commit: 62b555e6978b6c99f564214445d9ffe606c5363e |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Feb 10 06:50:42 2019 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Feb 10 06:52:02 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=62b555e6 |
7 |
|
8 |
media-libs/libvpx: drop cpu_flags_x86 flags |
9 |
|
10 |
The code does runtime CPU detection, and disabling code at build time |
11 |
tends to cause build failures. |
12 |
|
13 |
Package-Manager: Portage-2.3.59_p2, Repoman-2.3.12_p67 |
14 |
Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org> |
15 |
|
16 |
media-libs/libvpx/libvpx-1.8.0-r1.ebuild | 116 +++++++++++++++++++++++++++++++ |
17 |
1 file changed, 116 insertions(+) |
18 |
|
19 |
diff --git a/media-libs/libvpx/libvpx-1.8.0-r1.ebuild b/media-libs/libvpx/libvpx-1.8.0-r1.ebuild |
20 |
new file mode 100644 |
21 |
index 00000000000..b75c00c5ca4 |
22 |
--- /dev/null |
23 |
+++ b/media-libs/libvpx/libvpx-1.8.0-r1.ebuild |
24 |
@@ -0,0 +1,116 @@ |
25 |
+# Copyright 1999-2019 Gentoo Authors |
26 |
+# Distributed under the terms of the GNU General Public License v2 |
27 |
+ |
28 |
+EAPI="7" |
29 |
+inherit toolchain-funcs multilib-minimal |
30 |
+ |
31 |
+# To create a new testdata tarball: |
32 |
+# 1. Unpack source tarbll or checkout git tag |
33 |
+# 2. export LIBVPX_TEST_DATA_PATH=libvpx-testdata |
34 |
+# 3. configure --enable-unit-tests --enable-vp9-highbitdepth |
35 |
+# 4. make testdata |
36 |
+# 5. tar -cjf libvpx-testdata-${MY_PV}.tar.xz libvpx-testdata |
37 |
+ |
38 |
+LIBVPX_TESTDATA_VER=1.8.0 |
39 |
+ |
40 |
+DESCRIPTION="WebM VP8 and VP9 Codec SDK" |
41 |
+HOMEPAGE="https://www.webmproject.org" |
42 |
+SRC_URI="https://github.com/webmproject/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz |
43 |
+ test? ( mirror://gentoo/${PN}-testdata-${LIBVPX_TESTDATA_VER}.tar.xz )" |
44 |
+ |
45 |
+LICENSE="BSD" |
46 |
+SLOT="0/6" |
47 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux" |
48 |
+IUSE="doc +highbitdepth postproc static-libs svc test +threads" |
49 |
+ |
50 |
+REQUIRED_USE="test? ( threads )" |
51 |
+ |
52 |
+# Disable test phase when USE="-test" |
53 |
+RESTRICT="!test? ( test )" |
54 |
+ |
55 |
+RDEPEND="" |
56 |
+DEPEND="abi_x86_32? ( dev-lang/yasm ) |
57 |
+ abi_x86_64? ( dev-lang/yasm ) |
58 |
+ abi_x86_x32? ( dev-lang/yasm ) |
59 |
+ x86-fbsd? ( dev-lang/yasm ) |
60 |
+ amd64-fbsd? ( dev-lang/yasm ) |
61 |
+ doc? ( |
62 |
+ app-doc/doxygen |
63 |
+ dev-lang/php |
64 |
+ ) |
65 |
+" |
66 |
+ |
67 |
+PATCHES=( |
68 |
+ "${FILESDIR}/libvpx-1.3.0-sparc-configure.patch" # 501010 |
69 |
+) |
70 |
+ |
71 |
+src_configure() { |
72 |
+ # https://bugs.gentoo.org/show_bug.cgi?id=384585 |
73 |
+ # https://bugs.gentoo.org/show_bug.cgi?id=465988 |
74 |
+ # copied from php-pear-r1.eclass |
75 |
+ addpredict /usr/share/snmp/mibs/.index |
76 |
+ addpredict /var/lib/net-snmp/ |
77 |
+ addpredict /var/lib/net-snmp/mib_indexes |
78 |
+ addpredict /session_mm_cli0.sem |
79 |
+ multilib-minimal_src_configure |
80 |
+} |
81 |
+ |
82 |
+multilib_src_configure() { |
83 |
+ unset CODECS #357487 |
84 |
+ |
85 |
+ # #498364: sse doesn't work without sse2 enabled, |
86 |
+ local myconfargs=( |
87 |
+ --prefix="${EPREFIX}"/usr |
88 |
+ --libdir="${EPREFIX}"/usr/$(get_libdir) |
89 |
+ --enable-pic |
90 |
+ --enable-vp8 |
91 |
+ --enable-vp9 |
92 |
+ --enable-shared |
93 |
+ --extra-cflags="${CFLAGS}" |
94 |
+ $(use_enable postproc) |
95 |
+ $(use_enable svc experimental) |
96 |
+ $(use_enable static-libs static) |
97 |
+ $(use_enable test unit-tests) |
98 |
+ $(use_enable threads multithread) |
99 |
+ $(use_enable highbitdepth vp9-highbitdepth) |
100 |
+ ) |
101 |
+ |
102 |
+ # let the build system decide which AS to use (it honours $AS but |
103 |
+ # then feeds it with yasm flags without checking...) #345161 |
104 |
+ tc-export AS |
105 |
+ case "${CHOST}" in |
106 |
+ i?86*) export AS=yasm;; |
107 |
+ x86_64*) export AS=yasm;; |
108 |
+ esac |
109 |
+ |
110 |
+ # Build with correct toolchain. |
111 |
+ tc-export CC CXX AR NM |
112 |
+ # Link with gcc by default, the build system should override this if needed. |
113 |
+ export LD="${CC}" |
114 |
+ |
115 |
+ if multilib_is_native_abi; then |
116 |
+ myconfargs+=( $(use_enable doc install-docs) $(use_enable doc docs) ) |
117 |
+ else |
118 |
+ # not needed for multilib and will be overwritten anyway. |
119 |
+ myconfargs+=( --disable-examples --disable-install-docs --disable-docs ) |
120 |
+ fi |
121 |
+ |
122 |
+ echo "${S}"/configure "${myconfargs[@]}" >&2 |
123 |
+ "${S}"/configure "${myconfargs[@]}" |
124 |
+} |
125 |
+ |
126 |
+multilib_src_compile() { |
127 |
+ # build verbose by default and do not build examples that will not be installed |
128 |
+ emake verbose=yes GEN_EXAMPLES= |
129 |
+} |
130 |
+ |
131 |
+multilib_src_test() { |
132 |
+ local -x LD_LIBRARY_PATH="${BUILD_DIR}" |
133 |
+ local -x LIBVPX_TEST_DATA_PATH="${WORKDIR}/${PN}-testdata" |
134 |
+ emake verbose=yes GEN_EXAMPLES= test |
135 |
+} |
136 |
+ |
137 |
+multilib_src_install() { |
138 |
+ emake verbose=yes GEN_EXAMPLES= DESTDIR="${D}" install |
139 |
+ multilib_is_native_abi && use doc && dodoc -r docs/html |
140 |
+} |