]>
Commit | Line | Data |
---|---|---|
8d93948c ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # don't build static libraries | |
ffd255af | 4 | %bcond_without avresample # avresample support via libavresample |
8d93948c | 5 | |
f99faf48 JB |
6 | Summary: FFmpegSource - FFmpeg wrapper library |
7 | Summary(pl.UTF-8): FFmpegSource - biblioteka obudowująca FFmpeg | |
8d93948c | 8 | Name: ffms2 |
45d1616e | 9 | Version: 2.40 |
3373fec7 | 10 | Release: 1 |
f99faf48 JB |
11 | License: MIT (ffmpegsource itself), GPL v3+ (forced by ffmpeg) |
12 | Group: Libraries | |
3373fec7 | 13 | #Source0Download: https://github.com/FFMS/ffms2/releases |
8d93948c | 14 | Source0: https://github.com/FFMS/ffms2/archive/%{version}/%{name}-%{version}.tar.gz |
45d1616e | 15 | # Source0-md5: 141f194432d70bbf5456a847043f332a |
8d93948c | 16 | URL: https://github.com/FFMS/ffms2 |
f99faf48 | 17 | BuildRequires: autoconf >= 2.58 |
ffd255af | 18 | BuildRequires: automake >= 1:1.11 |
ce23f194 | 19 | # PKG_CHECK_MODULES(LIBAV, [libavformat >= 53.20.0 libavcodec >= 53.24.0 libswscale >= 0.7.0 libavutil >= 51.21.0 ]) |
7d6fea5e | 20 | BuildRequires: ffmpeg-devel >= 0.9 |
3373fec7 | 21 | # libavresample >= 1.0.0 or libswresample >= 1.0.0 |
ffd255af | 22 | %{?with_avresample:BuildRequires: ffmpeg-devel >= 1.1} |
a31926a4 JP |
23 | %ifarch %{armv6} |
24 | BuildRequires: libatomic-devel | |
25 | %endif | |
f99faf48 JB |
26 | BuildRequires: libstdc++-devel |
27 | BuildRequires: libtool >= 2:2.0 | |
f99faf48 | 28 | BuildRequires: pkgconfig >= 1:0.22 |
a31926a4 | 29 | BuildRequires: rpmbuild(macros) >= 2.007 |
f36cd6f2 | 30 | BuildRequires: sed >= 4.0 |
f99faf48 | 31 | BuildRequires: zlib-devel |
8d93948c | 32 | Obsoletes: ffmpegsource < 2.20 |
f99faf48 JB |
33 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
34 | ||
35 | %description | |
36 | FFmpegSource (usually known as FFMS or FFMS2) is a cross-platform | |
37 | wrapper library around FFmpeg, plus some additional components to deal | |
38 | with file formats FFmpeg's libavformat has (or used to have) problems | |
39 | with. It gives you an easy, convenient way to say "open and decompress | |
40 | this media file for me, I don't care how you do it" and get frame- and | |
41 | sample-accurate access (usually), without having to bother with the | |
42 | sometimes less than straightforward and less than perfectly documented | |
43 | FFmpeg API. | |
44 | ||
45 | %description -l pl.UTF-8 | |
46 | FFmpegSource (zwykle zwana FFMS lub FFMS2) to wieloplatformowa | |
47 | biblioteka obudowująca FFmpeg wraz z paroma dodatkowymi komponentami | |
48 | mającymi radzić sobie z formatami plików, z którymi libavformat z | |
49 | FFmpeg ma (lub miał) problemy. Umożliwia w łatwy sposób zażądanie | |
50 | "otwórz i zdekompresuj ten plik, nieważne jak" i uzyskanie dostępu | |
8d93948c ER |
51 | (zwykle) z dokładnością do ramek i próbek, bez potrzeby zajmowania się |
52 | często złożonym, nie najlepiej udokumentowanym API FFmpeg. | |
f99faf48 JB |
53 | |
54 | %package devel | |
55 | Summary: Header files for FFmpegSource library | |
56 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki FFmpegSource | |
57 | Group: Development/Libraries | |
58 | Requires: %{name} = %{version}-%{release} | |
ffd255af JB |
59 | %if %{with avresample} |
60 | Requires: ffmpeg-devel >= 1.1 | |
61 | %else | |
7d6fea5e | 62 | Requires: ffmpeg-devel >= 0.9 |
ffd255af | 63 | %endif |
f99faf48 JB |
64 | Requires: libstdc++-devel |
65 | Requires: zlib-devel | |
8d93948c ER |
66 | Provides: ffmpegsource-devel = %{version}-%{release} |
67 | Obsoletes: ffmpegsource-devel < 2.20 | |
f99faf48 JB |
68 | |
69 | %description devel | |
70 | Header files for FFmpegSource library. | |
71 | ||
72 | %description devel -l pl.UTF-8 | |
73 | Pliki nagłówkowe biblioteki FFmpegSource. | |
74 | ||
75 | %package static | |
76 | Summary: Static FFmpegSource library | |
77 | Summary(pl.UTF-8): Statyczna biblioteka FFmpegSource | |
78 | Group: Development/Libraries | |
79 | Requires: %{name}-devel = %{version}-%{release} | |
8d93948c | 80 | Obsoletes: ffmpegsource-static < 2.20 |
f99faf48 JB |
81 | |
82 | %description static | |
83 | Static FFmpegSource library. | |
84 | ||
85 | %description static -l pl.UTF-8 | |
86 | Statyczna biblioteka FFmpegSource. | |
87 | ||
88 | %prep | |
8d93948c | 89 | %setup -q |
f99faf48 | 90 | |
45d1616e JP |
91 | install -d src/config |
92 | ||
f99faf48 | 93 | %build |
3373fec7 | 94 | CXXFLAGS="%{rpmcxxflags} -Wall -Wextra" |
f99faf48 JB |
95 | %{__libtoolize} |
96 | %{__aclocal} -I m4 | |
97 | %{__autoconf} | |
98 | %{__autoheader} | |
99 | %{__automake} | |
100 | %configure \ | |
a31926a4 JP |
101 | %ifarch %{armv6} |
102 | LIBS=-latomic \ | |
103 | %endif | |
ffd255af | 104 | --enable-avresample%{!?with_avresample:=no} \ |
8d93948c | 105 | --disable-silent-rules \ |
ffd255af JB |
106 | --enable-shared \ |
107 | %{__enable_disable static_libs static} | |
cf17c716 | 108 | |
8d93948c | 109 | %{__make} |
f99faf48 JB |
110 | |
111 | %install | |
112 | rm -rf $RPM_BUILD_ROOT | |
3373fec7 | 113 | |
f99faf48 JB |
114 | %{__make} install \ |
115 | DESTDIR=$RPM_BUILD_ROOT | |
116 | ||
3373fec7 JB |
117 | # obsoleted by pkg-config |
118 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libffms2.la | |
119 | ||
8d93948c ER |
120 | %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name} |
121 | ||
f99faf48 JB |
122 | %clean |
123 | rm -rf $RPM_BUILD_ROOT | |
124 | ||
125 | %post -p /sbin/ldconfig | |
126 | %postun -p /sbin/ldconfig | |
127 | ||
128 | %files | |
129 | %defattr(644,root,root,755) | |
ffd255af | 130 | %doc COPYING README.md |
f99faf48 JB |
131 | %attr(755,root,root) %{_bindir}/ffmsindex |
132 | %attr(755,root,root) %{_libdir}/libffms2.so.*.*.* | |
3373fec7 | 133 | %attr(755,root,root) %ghost %{_libdir}/libffms2.so.4 |
f99faf48 JB |
134 | |
135 | %files devel | |
136 | %defattr(644,root,root,755) | |
3373fec7 | 137 | %doc doc/ffms2-*.md |
f99faf48 | 138 | %attr(755,root,root) %{_libdir}/libffms2.so |
f99faf48 JB |
139 | %{_includedir}/ffms.h |
140 | %{_includedir}/ffmscompat.h | |
141 | %{_pkgconfigdir}/ffms2.pc | |
142 | ||
8d93948c | 143 | %if %{with static_libs} |
f99faf48 JB |
144 | %files static |
145 | %defattr(644,root,root,755) | |
146 | %{_libdir}/libffms2.a | |
8d93948c | 147 | %endif |