]>
Commit | Line | Data |
---|---|---|
5afc8bc2 | 1 | # TODO: vmaf |
6277aac6 ER |
2 | # |
3 | # Conditional build: | |
4 | %bcond_without asm # x86 assembler | |
e745f1cd | 5 | %bcond_with vmaf # VMAF support [not ready for vmaf-1.3.x as of x265 3.2] |
6277aac6 | 6 | |
c14ed13e | 7 | %ifnarch %{ix86} %{x8664} x32 |
6277aac6 ER |
8 | %undefine with_asm |
9 | %endif | |
10 | ||
bf255eb2 JB |
11 | Summary: H.265/HEVC video encoder |
12 | Summary(pl.UTF-8): Koder obrazu H.265/HEVC | |
13 | Name: x265 | |
4264b299 | 14 | Version: 3.2.1 |
c1aa5841 | 15 | Release: 1 |
bf255eb2 JB |
16 | License: GPL v2+ |
17 | Group: Libraries | |
a8d1efd1 | 18 | # also at https://bitbucket.org/multicoreware/x265/downloads |
94469a9d | 19 | Source0: https://download.videolan.org/videolan/x265/%{name}_%{version}.tar.gz |
4264b299 | 20 | # Source0-md5: 94808045a34d88a857e5eaf3f68f4bca |
bf255eb2 | 21 | Patch0: %{name}-opt.patch |
c14ed13e | 22 | Patch1: %{name}-x32.patch |
bf255eb2 | 23 | URL: http://x265.org/ |
a827c98f JB |
24 | BuildRequires: cmake >= 2.8.11 |
25 | BuildRequires: libstdc++-devel >= 6:4.8 | |
26 | BuildRequires: numactl-devel >= 2 | |
a3d10030 | 27 | BuildRequires: rpmbuild(macros) >= 1.605 |
5afc8bc2 JB |
28 | %{?with_asm:BuildRequires: nasm >= 2.13.0} |
29 | %{?with_vmaf:BuildRequires: vmaf-devel} | |
bf255eb2 JB |
30 | Requires: libx265 = %{version}-%{release} |
31 | # see CMakeLists.txt, more is probably possible | |
ccce3682 | 32 | ExclusiveArch: %{ix86} %{x8664} x32 %{arm} ppc64 ppc64le aarch64 |
a3d10030 JB |
33 | # needs 64-bit atomic compare and swap |
34 | ExcludeArch: i386 i486 | |
bf255eb2 JB |
35 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
36 | ||
37 | %description | |
38 | H.265/HEVC video encoder. | |
39 | ||
40 | %description -l pl.UTF-8 | |
41 | Koder obrazu H.265/HEVC. | |
42 | ||
43 | %package -n libx265 | |
44 | Summary: H.265/HEVC video encoder library | |
45 | Summary(pl.UTF-8): Biblioteka kodowania obrazu H.265/HEVC | |
46 | Group: Libraries | |
47 | ||
48 | %description -n libx265 | |
49 | H.265/HEVC video encoder library. | |
50 | ||
51 | %description -n libx265 -l pl.UTF-8 | |
52 | Biblioteka kodowania obrazu H.265/HEVC. | |
53 | ||
54 | %package -n libx265-devel | |
55 | Summary: Header files for x265 library | |
56 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki x265 | |
57 | Group: Development/Libraries | |
a827c98f | 58 | Requires: libstdc++-devel >= 6:4.8 |
bf255eb2 | 59 | Requires: libx265 = %{version}-%{release} |
a827c98f | 60 | Requires: numactl-devel >= 2 |
bf255eb2 JB |
61 | |
62 | %description -n libx265-devel | |
63 | Header files for x265 library. | |
64 | ||
65 | %description -n libx265-devel -l pl.UTF-8 | |
66 | Pliki nagłówkowe biblioteki x265. | |
67 | ||
68 | %package -n libx265-static | |
69 | Summary: Static x265 library | |
70 | Summary(pl.UTF-8): Statyczna biblioteka x265 | |
71 | Group: Development/Libraries | |
528852c9 | 72 | Requires: libx265-devel = %{version}-%{release} |
bf255eb2 JB |
73 | |
74 | %description -n libx265-static | |
75 | Static x265 library. | |
76 | ||
77 | %description -n libx265-static -l pl.UTF-8 | |
78 | Statyczna biblioteka x265. | |
79 | ||
80 | %prep | |
5afc8bc2 | 81 | %setup -q -n %{name}_%{version} |
bf255eb2 | 82 | %patch0 -p1 |
c14ed13e | 83 | %patch1 -p1 |
bf255eb2 JB |
84 | |
85 | %build | |
7b548267 JB |
86 | install -d source/build |
87 | cd source/build | |
88 | %cmake .. \ | |
6277aac6 | 89 | -DENABLE_ASSEMBLY=%{!?with_asm:OFF}%{?with_asm:ON} \ |
a827c98f | 90 | -DENABLE_HDR10_PLUS=ON \ |
5afc8bc2 | 91 | %{?with_vmaf:-DENABLE_LIBVMAF=ON} \ |
a827c98f | 92 | -DENABLE_SHARED=ON \ |
7b548267 JB |
93 | -DLIB_INSTALL_DIR=%{_lib} |
94 | ||
bf255eb2 JB |
95 | %{__make} |
96 | ||
97 | %install | |
98 | rm -rf $RPM_BUILD_ROOT | |
94469a9d | 99 | |
7b548267 | 100 | %{__make} -C source/build install \ |
bf255eb2 JB |
101 | DESTDIR=$RPM_BUILD_ROOT |
102 | ||
103 | %clean | |
104 | rm -rf $RPM_BUILD_ROOT | |
105 | ||
106 | %post -n libx265 -p /sbin/ldconfig | |
107 | %postun -n libx265 -p /sbin/ldconfig | |
108 | ||
109 | %files | |
110 | %defattr(644,root,root,755) | |
111 | %doc doc/reST/cli.rst | |
112 | %attr(755,root,root) %{_bindir}/x265 | |
113 | ||
114 | %files -n libx265 | |
115 | %defattr(644,root,root,755) | |
116 | %doc doc/reST/introduction.rst | |
e745f1cd | 117 | %attr(755,root,root) %{_libdir}/libx265.so.179 |
a827c98f | 118 | %attr(755,root,root) %{_libdir}/libhdr10plus.so |
bf255eb2 JB |
119 | |
120 | %files -n libx265-devel | |
121 | %defattr(644,root,root,755) | |
122 | %attr(755,root,root) %{_libdir}/libx265.so | |
a827c98f | 123 | %{_includedir}/hdr10plus.h |
bf255eb2 JB |
124 | %{_includedir}/x265.h |
125 | %{_includedir}/x265_config.h | |
126 | %{_pkgconfigdir}/x265.pc | |
127 | ||
128 | %files -n libx265-static | |
129 | %defattr(644,root,root,755) | |
a827c98f | 130 | %{_libdir}/libhdr10plus.a |
bf255eb2 | 131 | %{_libdir}/libx265.a |