]> git.pld-linux.org Git - packages/mpv.git/blame - mpv.spec
up to 0.33.0
[packages/mpv.git] / mpv.spec
CommitLineData
2299b04f
JP
1#
2# Conditional build:
3%bcond_without caca # CACA
4%bcond_without dvdnav # dvdnav support
236ade95 5%bcond_without js # JavaScript scripting support
2299b04f
JP
6%bcond_without libplacebo # libplacebo support
7%bcond_without rubberband # librubberband support
2299b04f
JP
8%bcond_without shaderc # libshaderc SPIR-V compiler
9%bcond_without vapoursynth # VapourSynth filter bridge
10%bcond_without zimg # libzimg support (high quality software scaler)
11
b297e630 12Summary: Movie player based on MPlayer and mplayer2
c1eb0652 13Summary(pl.UTF-8): Odtwarzacz filmów oparty na projektach MPlayer i mplayer2
b297e630 14Name: mpv
236ade95
JP
15Version: 0.33.0
16Release: 1
17License: GPL v2+
b297e630 18Group: Applications/Multimedia
c1eb0652
JB
19#Source0Download: http://github.com/mpv-player/mpv/releases
20Source0: http://github.com/mpv-player/mpv/archive/v%{version}/%{name}-%{version}.tar.gz
236ade95 21# Source0-md5: b08d25d3a44c3362984636e5dfa78ecc
4084bdb9 22Source1: %{name}.conf
236ade95 23Patch0: %{name}-shaderc.patch
b297e630 24URL: http://mpv.io/
77c81a17 25BuildRequires: EGL-devel
f272a633 26BuildRequires: Mesa-libgbm-devel
b297e630
JP
27BuildRequires: OpenAL-devel >= 1.13
28BuildRequires: OpenGL-devel
9da63119 29BuildRequires: SDL2-devel
5045f7e8 30BuildRequires: alsa-lib-devel >= 1.0.18
682d5897 31BuildRequires: docutils
fe3aada1 32BuildRequires: ffmpeg-devel >= 4.0
b297e630 33BuildRequires: jack-audio-connection-kit-devel
d297c06d 34BuildRequires: lcms2-devel >= 2.6
f272a633 35BuildRequires: libarchive-devel >= 3.4.0
236ade95 36BuildRequires: libass-devel >= 0.12.2
308de4d0
JP
37%ifarch i386 i486
38BuildRequires: libatomic-devel
39%endif
5d9fec95 40BuildRequires: libbluray-devel >= 0.3.0
2299b04f 41%{?with_caca:BuildRequires: libcaca-devel >= 0.99-0.beta18.1}
b297e630 42BuildRequires: libcdio-paranoia-devel
f272a633 43BuildRequires: libdrm-devel >= 2.4.74
2299b04f 44%if %{with dvdnav}
b297e630
JP
45BuildRequires: libdvdnav-devel >= 4.2.0
46BuildRequires: libdvdread-devel >= 4.1.0
2299b04f 47%endif
b297e630 48BuildRequires: libjpeg-devel
236ade95 49%{?with_libplacebo:BuildRequires: libplacebo-devel >= 1.18.0}
5045f7e8
JP
50BuildRequires: libva-devel >= 1.4.0
51BuildRequires: libva-glx-devel >= 1.4.0
b297e630 52BuildRequires: libvdpau-devel >= 0.2
236ade95
JP
53BuildRequires: lua52-devel
54%{?with_js:BuildRequires: mujs-devel >= 1.0.0}
f272a633 55BuildRequires: nv-codec-headers >= 8.2.15.7
b297e630 56BuildRequires: pkgconfig
5045f7e8 57BuildRequires: pulseaudio-devel >= 1.0
f272a633 58BuildRequires: rpmbuild(macros) >= 1.719
2299b04f
JP
59%{?with_rubberband:BuildRequires: rubberband-devel >= 1.8.0}
60%{?with_shaderc:BuildRequires: shaderc-devel >= 2019.0}
a33f39f8 61BuildRequires: uchardet-devel
2299b04f 62%{?with_vapoursynth:BuildRequires: vapoursynth-devel >= 24}
236ade95 63BuildRequires: waf >= 2.0.21
8a7befcf 64BuildRequires: wayland-devel >= 1.15.0
12311963 65BuildRequires: wayland-egl-devel
b4be0d1d 66BuildRequires: wayland-protocols >= 1.14
31601366
JP
67BuildRequires: xorg-lib-libX11-devel >= 1.0.0
68BuildRequires: xorg-lib-libXScrnSaver-devel >= 1.0.0
b297e630 69BuildRequires: xorg-lib-libXdamage-devel
31601366
JP
70BuildRequires: xorg-lib-libXext-devel >= 1.0.0
71BuildRequires: xorg-lib-libXinerama-devel >= 1.0.0
72BuildRequires: xorg-lib-libXrandr-devel >= 1.2.0
b297e630 73BuildRequires: xorg-lib-libXv-devel
b297e630
JP
74BuildRequires: xorg-lib-libxkbcommon-devel >= 0.3.0
75BuildRequires: xorg-proto-xproto-devel
2299b04f 76%{?with_zimg:BuildRequires: zimg-devel >= 2.9}
f272a633 77BuildRequires: zlib-devel
5d9fec95 78Requires: OpenAL >= 1.13
b297e630 79Requires: OpenGL
5045f7e8 80Requires: alsa-lib >= 1.0.18
8a7befcf 81%requires_eq_to ffmpeg-libs ffmpeg-devel
5d9fec95 82Requires: lcms2 >= 2.6
f272a633 83Requires: libarchive >= 3.4.0
236ade95 84Requires: libass >= 0.12.2
5d9fec95 85Requires: libbluray >= 0.3.0
2299b04f 86%{?with_caca:Requires: libcaca >= 0.99-0.beta18.1}
f272a633 87Requires: libdrm >= 2.4.74
2299b04f 88%if %{with dvdnav}
5d9fec95
JP
89Requires: libdvdnav >= 4.2.0
90Requires: libdvdread >= 4.1.0
2299b04f 91%endif
236ade95 92%{?with_libplacebo:Requires: libplacebo >= 1.18.0}
5045f7e8
JP
93Requires: libva >= 1.4.0
94Requires: libva-glx >= 1.4.0
5d9fec95 95Requires: libvdpau >= 0.2
236ade95 96%{?with_js:Requires: mujs >= 1.0.0}
5d9fec95 97Requires: pulseaudio-libs >= 1.0
2299b04f
JP
98%{?with_rubberband:Requires: rubberband-libs >= 1.8.0}
99%{?with_shaderc:Requires: shaderc >= 2019.0}
100%{?with_vapoursynth:Requires: vapoursynth >= 24}
8a7befcf 101Requires: wayland >= 1.15.0
31601366
JP
102Requires: xorg-lib-libX11 >= 1.0.0
103Requires: xorg-lib-libXScrnSaver >= 1.0.0
104Requires: xorg-lib-libXext >= 1.0.0
105Requires: xorg-lib-libXinerama >= 1.0.0
106Requires: xorg-lib-libXrandr >= 1.2.0
5d9fec95 107Requires: xorg-lib-libxkbcommon >= 0.3.0
2299b04f 108%{?with_zimg:Requires: zimg >= 2.9}
20a45907 109Suggests: youtube-dl >= 2:20150223
b297e630
JP
110BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
111
112%define _noautoreqdep libGL.so.1 libGLU.so.1
113
114%description
292eac8e 115Movie player based on MPlayer and mplayer2.
b297e630 116
c1eb0652
JB
117%description -l pl.UTF-8
118Odtwarzacz filmów oparty na projektach MPlayer i mplayer2.
119
d297c06d 120%package client-libs
e386ece9 121Summary: Client library for controlling mpv
c1eb0652
JB
122Summary(pl.UTF-8): Biblioteka kliencka do sterowania odtwarzaczem mpv
123Group: Libraries
d297c06d
JP
124
125%description client-libs
126Client library for controlling mpv.
127
c1eb0652
JB
128%description client-libs -l pl.UTF-8
129Biblioteka kliencka do sterowania odtwarzaczem mpv.
130
d297c06d 131%package client-devel
e386ece9 132Summary: Development files for mpv client library
c1eb0652 133Summary(pl.UTF-8): Pliki programistyczne biblioteki klienckiej mpv
e386ece9
JP
134Group: Development/Libraries
135Requires: %{name}-client-libs = %{version}-%{release}
d297c06d
JP
136
137%description client-devel
138Development files for mpv client library.
139
c1eb0652
JB
140%description client-devel -l pl.UTF-8
141Pliki programistyczne biblioteki klienckiej mpv.
142
f272a633
JP
143%package -n bash-completion-mpv
144Summary: Bash completion for mpv
145Summary(pl.UTF-8): Dopełnianie parametrów mpv dla powłoki Bash
146Group: Applications/Shells
147Requires: %{name} = %{version}-%{release}
148Requires: bash-completion >= 2.0
149
150%description -n bash-completion-mpv
151Bash completion for mpv.
152
153%description -n bash-completion-mpv -l pl.UTF-8
154Dopełnianie parametrów mpv dla powłoki Bash.
155
d297c06d 156%package -n zsh-completion-mpv
c1eb0652
JB
157Summary: ZSH completion for mpv
158Summary(pl.UTF-8): Dopełnianie parametrów mpv dla powłoki ZSH
e386ece9
JP
159Group: Applications/Shells
160Requires: %{name} = %{version}-%{release}
d297c06d
JP
161
162%description -n zsh-completion-mpv
c1eb0652
JB
163ZSH completion for mpv.
164
165%description -n zsh-completion-mpv -l pl.UTF-8
166Dopełnianie parametrów mpv dla powłoki ZSH.
d297c06d 167
b297e630
JP
168%prep
169%setup -q
d297c06d 170%patch0 -p1
b297e630
JP
171
172%build
4d3f4bbb 173%waf configure \
b297e630
JP
174 --prefix=%{_prefix} \
175 --bindir=%{_bindir} \
176 --confdir=%{_sysconfdir}/mpv \
177 --libdir=%{_libdir} \
178 --datadir=%{_datadir} \
179 --mandir=%{_mandir} \
180 --disable-debug-build \
181 --enable-alsa \
2299b04f 182 %{__enable_disable caca} \
b297e630 183 --enable-cdda \
4c185ee1 184 --enable-cplugins \
b297e630
JP
185 --enable-dvb \
186 --enable-dvbin \
2299b04f 187 %{__enable_disable dvdnav} \
b297e630
JP
188 --enable-gl-wayland \
189 --enable-gl-x11 \
190 --enable-iconv \
191 --enable-jack \
236ade95 192 %{__enable_disable js javascript} \
b297e630 193 --enable-jpeg \
b297e630 194 --enable-lcms2 \
d297c06d 195 --enable-libavdevice \
b297e630 196 --enable-libbluray \
d297c06d 197 --enable-libmpv-shared \
2299b04f
JP
198 %{__enable_disable libplacebo} \
199 %{__enable_disable rubberband} \
b297e630 200 --enable-openal \
b297e630 201 --enable-pulse \
9da63119 202 --enable-sdl2 \
2299b04f 203 %{__enable_disable shaderc} \
a33f39f8 204 --enable-uchardet \
b297e630 205 --enable-vaapi \
2299b04f 206 %{__enable_disable vapoursynth} \
b297e630 207 --enable-vdpau \
d297c06d 208 --enable-vdpau-gl-x11 \
d297c06d 209 --enable-wayland \
b297e630 210 --enable-x11 \
d297c06d 211 --enable-xv \
2299b04f 212 %{__enable_disable zimg} \
236ade95 213 --lua=52deb \
f272a633
JP
214 --bashdir=%{bash_compdir} \
215 --zshdir=%{zsh_compdir}
292eac8e 216
4d3f4bbb 217%waf build -v
b297e630
JP
218
219%install
220rm -rf $RPM_BUILD_ROOT
221
4d3f4bbb 222%waf install --destdir=$RPM_BUILD_ROOT
b297e630 223
4084bdb9 224install -d $RPM_BUILD_ROOT%{_sysconfdir}/mpv
e386ece9 225cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/mpv
4084bdb9 226
a68f52ba
JP
227%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
228
b297e630
JP
229%clean
230rm -rf $RPM_BUILD_ROOT
231
1a8f2eea
ER
232%post client-libs -p /sbin/ldconfig
233%postun client-libs -p /sbin/ldconfig
234
b297e630
JP
235%files
236%defattr(644,root,root,755)
6ee6242b 237%doc README.md RELEASE_NOTES etc/input.conf etc/mplayer-input.conf etc/mpv.conf etc/restore-old-bindings.conf
b297e630 238%dir %{_sysconfdir}/mpv
1a8f2eea 239%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mpv/encoding-profiles.conf
4084bdb9 240%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mpv/mpv.conf
b297e630
JP
241%attr(755,root,root) %{_bindir}/%{name}
242%{_desktopdir}/mpv.desktop
243%{_iconsdir}/hicolor/*/apps/mpv.png
2d1f1cf1 244%{_iconsdir}/hicolor/scalable/apps/mpv.svg
0ea238bf 245%{_iconsdir}/hicolor/symbolic/apps/mpv-symbolic.svg
b297e630 246%{_mandir}/man1/mpv.1*
d297c06d
JP
247
248%files client-libs
249%defattr(644,root,root,755)
250%attr(755,root,root) %{_libdir}/libmpv.so.*.*.*
251%attr(755,root,root) %ghost %{_libdir}/libmpv.so.1
252
253%files client-devel
254%defattr(644,root,root,755)
255%attr(755,root,root) %{_libdir}/libmpv.so
256%{_includedir}/mpv
257%{_pkgconfigdir}/mpv.pc
258
f272a633
JP
259%files -n bash-completion-mpv
260%defattr(644,root,root,755)
261%{bash_compdir}/mpv
262
d297c06d
JP
263%files -n zsh-completion-mpv
264%defattr(644,root,root,755)
f272a633 265%{zsh_compdir}/_mpv
This page took 0.087965 seconds and 4 git commands to generate.