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