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