]>
Commit | Line | Data |
---|---|---|
0e801e1d JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # static library | |
4 | # | |
7a0f7637 | 5 | Summary: Lightweight video thumbnailer |
a8b04dac | 6 | Summary(pl.UTF-8): Lekki program do wykonywania miniaturek dla filmów |
7a0f7637 | 7 | Name: ffmpegthumbnailer |
b8c64072 | 8 | Version: 2.2.0 |
8334fde0 | 9 | Release: 2 |
7a0f7637 | 10 | License: GPL v2 |
c507c284 | 11 | Group: Applications/Graphics |
0e801e1d JB |
12 | #Source0Download: https://github.com/dirkvdb/ffmpegthumbnailer/releases |
13 | Source0: https://github.com/dirkvdb/ffmpegthumbnailer/releases/download/%{version}/%{name}-%{version}.tar.bz2 | |
b8c64072 | 14 | # Source0-md5: ed3754b3b8b9af93a93c490e17def0d0 |
0e801e1d | 15 | Patch0: %{name}-pc.patch |
893cf8a4 | 16 | URL: https://github.com/dirkvdb/ffmpegthumbnailer |
0e801e1d | 17 | BuildRequires: cmake >= 2.8 |
fae5264b | 18 | # libavcodec >= 52.26.0 libavformat libavutil libswscale |
191710e7 | 19 | BuildRequires: ffmpeg-devel >= 0.6 |
e12f335b | 20 | BuildRequires: libjpeg-devel |
7a0f7637 | 21 | BuildRequires: libpng-devel |
2d5a747b | 22 | BuildRequires: libstdc++-devel |
c507c284 | 23 | BuildRequires: pkgconfig |
191710e7 | 24 | BuildRequires: sed >= 4.0 |
fae5264b | 25 | # dlopens libglib-2.0.so.0 libgobject-2.0.so.0 libgio-2.0.so.0 |
0e801e1d | 26 | Requires: glib2 >= 2.0 |
7a0f7637 MB |
27 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
28 | ||
29 | %description | |
30 | ffmpegthumbnailer can be used by file managers to create thumbnails | |
31 | for your video files. It uses ffmpeg to decode frames from the video | |
32 | files. | |
33 | ||
a8b04dac JB |
34 | %description -l pl.UTF-8 |
35 | ffmpegthumbnailer może być używany przez zarządców plików do tworzenia | |
36 | miniaturek dla plików filmów. Wykorzystuje ffmpeg do dekodowania | |
37 | klatek. | |
38 | ||
2d5a747b MB |
39 | %package devel |
40 | Summary: Header files for libffmpegthumbnailer library | |
41 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libffmpegthumbnailer | |
42 | Group: Development/Libraries | |
43 | Requires: %{name} = %{version}-%{release} | |
44 | Requires: ffmpeg-devel | |
fae5264b | 45 | Requires: libjpeg-devel |
2d5a747b MB |
46 | Requires: libpng-devel |
47 | ||
48 | %description devel | |
49 | Header files for libffmpegthumbnailer library. | |
50 | ||
51 | %description devel -l pl.UTF-8 | |
52 | Pliki nagłówkowe biblioteki libffmpegthumbnailer. | |
53 | ||
54 | %package static | |
55 | Summary: Static libffmpegthumbnailer library | |
56 | Summary(pl.UTF-8): Statyczna biblioteka libffmpegthumbnailer | |
57 | Group: Development/Libraries | |
58 | Requires: %{name}-devel = %{version}-%{release} | |
59 | ||
60 | %description static | |
61 | Static libffmpegthumbnailer library. | |
62 | ||
63 | %description static -l pl.UTF-8 | |
64 | Statyczna biblioteka libffmpegthumbnailer. | |
65 | ||
7a0f7637 MB |
66 | %prep |
67 | %setup -q | |
0e801e1d | 68 | %patch0 -p1 |
191710e7 | 69 | |
7a0f7637 | 70 | %build |
893cf8a4 JR |
71 | mkdir build |
72 | cd build | |
0e801e1d | 73 | %cmake .. \ |
893cf8a4 | 74 | -DENABLE_GIO=ON \ |
0e801e1d JB |
75 | -DENABLE_TESTS=ON \ |
76 | %{?with_static_libs:-DENABLE_STATIC=ON} \ | |
77 | -DENABLE_THUMBNAILER=ON | |
3fd37711 | 78 | |
7a0f7637 MB |
79 | %{__make} |
80 | ||
81 | %install | |
82 | rm -rf $RPM_BUILD_ROOT | |
83 | ||
893cf8a4 | 84 | cd build |
7a0f7637 MB |
85 | %{__make} install \ |
86 | DESTDIR=$RPM_BUILD_ROOT | |
87 | ||
88 | %clean | |
89 | rm -rf $RPM_BUILD_ROOT | |
90 | ||
2d5a747b MB |
91 | %post -p /sbin/ldconfig |
92 | %postun -p /sbin/ldconfig | |
93 | ||
7a0f7637 MB |
94 | %files |
95 | %defattr(644,root,root,755) | |
96 | %doc AUTHORS ChangeLog README TODO | |
97 | %attr(755,root,root) %{_bindir}/ffmpegthumbnailer | |
2d5a747b | 98 | %attr(755,root,root) %{_libdir}/libffmpegthumbnailer.so.*.*.* |
191710e7 | 99 | %attr(755,root,root) %ghost %{_libdir}/libffmpegthumbnailer.so.4 |
3fd37711 | 100 | %{_datadir}/thumbnailers/ffmpegthumbnailer.thumbnailer |
2d5a747b MB |
101 | %{_mandir}/man1/ffmpegthumbnailer.1* |
102 | ||
103 | %files devel | |
104 | %defattr(644,root,root,755) | |
105 | %attr(755,root,root) %{_libdir}/libffmpegthumbnailer.so | |
2d5a747b MB |
106 | %{_includedir}/libffmpegthumbnailer |
107 | %{_pkgconfigdir}/libffmpegthumbnailer.pc | |
108 | ||
0e801e1d | 109 | %if %{with static_libs} |
2d5a747b MB |
110 | %files static |
111 | %defattr(644,root,root,755) | |
112 | %{_libdir}/libffmpegthumbnailer.a | |
0e801e1d | 113 | %endif |