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