]>
Commit | Line | Data |
---|---|---|
b6febd90 JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # static library | |
4 | ||
eb417e36 | 5 | Summary: Extensible Binary Meta Language access library |
c898b1eb | 6 | Summary(pl.UTF-8): Biblioteka dostępu rozszerzalnego metajęzyka binarnego |
eb417e36 | 7 | Name: libmatroska |
1d2888d7 | 8 | Version: 1.7.1 |
aba80a59 | 9 | Release: 1 |
58ee65c3 | 10 | License: LGPL v2.1+ |
eb417e36 | 11 | Group: Libraries |
a48d202d | 12 | Source0: https://dl.matroska.org/downloads/libmatroska/%{name}-%{version}.tar.xz |
1d2888d7 | 13 | # Source0-md5: 576ca1b6d2661f328a42192124135e86 |
9c4c0812 | 14 | URL: https://www.matroska.org/ |
b6febd90 | 15 | BuildRequires: cmake >= 3.1.2 |
aba80a59 JP |
16 | BuildRequires: libebml-devel >= 1.4.3 |
17 | BuildRequires: libstdc++-devel >= 6:5 | |
df9e9bf8 | 18 | BuildRequires: pkgconfig |
b6febd90 | 19 | BuildRequires: rpmbuild(macros) >= 1.605 |
c2948ae6 JP |
20 | BuildRequires: tar >= 1:1.22 |
21 | BuildRequires: xz | |
aba80a59 | 22 | Requires: libebml >= 1.4.3 |
eb417e36 | 23 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
24 | ||
25 | %description | |
b57b5cf5 JB |
26 | Matroska is an extensible open standard Audio/Video container format, |
27 | aiming to become the standard of Multimedia Container Formats one day. | |
28 | It is based on EBML (Extensible Binary Meta Language), a kind of | |
29 | binary version of XML. This way the significant advantages in terms of | |
30 | future format extensibility are gained without breaking file support | |
31 | in old parsers. | |
ac28d4e4 | 32 | |
6ab1e4ef JR |
33 | %description -l pl.UTF-8 |
34 | Matroska to rozszerzalny otwarty format kodowania dźwięku i obrazu, | |
35 | dążący do stania się pewnego dnia standardem formatów zawierających | |
36 | multimedia. Jest on oparty na EBML (rozszerzalnym metajęzyku | |
37 | binarnym), binarnym odpowiedniku XML-a. W ten sposób ma on przewagę | |
38 | nad innymi formatami pod względem przyszłej rozszerzalności przy | |
39 | jednoczesnym zachowaniu kompatybilności wstecz. | |
eb417e36 | 40 | |
41 | %package devel | |
b57b5cf5 | 42 | Summary: Header files for matroska library |
c898b1eb | 43 | Summary(pl.UTF-8): Nagłówki dla biblioteki matroska |
eb417e36 | 44 | Group: Development/Libraries |
0f5a8090 | 45 | Requires: %{name} = %{version}-%{release} |
aba80a59 | 46 | Requires: libebml-devel >= 1.4.3 |
3dcf4f5a | 47 | Requires: libstdc++-devel >= 6:4.7 |
eb417e36 | 48 | |
49 | %description devel | |
b57b5cf5 | 50 | Header files for matroska library. |
eb417e36 | 51 | |
6ab1e4ef JR |
52 | %description devel -l pl.UTF-8 |
53 | Nagłówki dla biblioteki matroska. | |
eb417e36 | 54 | |
55 | %package static | |
b57b5cf5 | 56 | Summary: Static version of matroska library |
c898b1eb | 57 | Summary(pl.UTF-8): Statyczna wersja biblioteki matroska |
b57b5cf5 | 58 | Group: Development/Libraries |
0f5a8090 | 59 | Requires: %{name}-devel = %{version}-%{release} |
eb417e36 | 60 | |
61 | %description static | |
b57b5cf5 | 62 | Static version of matroska library. |
eb417e36 | 63 | |
6ab1e4ef | 64 | %description static -l pl.UTF-8 |
b57b5cf5 | 65 | Statyczna wersja biblioteki matroska. |
eb417e36 | 66 | |
67 | %prep | |
47663573 | 68 | %setup -q |
eb417e36 | 69 | |
70 | %build | |
b6febd90 JB |
71 | # .pc file generation expects relative CMAKE_INSTALL_{INCLUDE,LIB}DIR |
72 | %if %{with static_libs} | |
73 | install -d build-static | |
74 | cd build-static | |
75 | %cmake .. \ | |
76 | -DBUILD_SHARED_LIBS:BOOL=OFF \ | |
77 | -DCMAKE_INSTALL_INCLUDEDIR=include \ | |
78 | -DCMAKE_INSTALL_LIBDIR=%{_lib} | |
79 | ||
80 | %{__make} | |
81 | cd .. | |
82 | %endif | |
83 | ||
84 | install -d build | |
85 | cd build | |
86 | %cmake .. \ | |
87 | -DCMAKE_INSTALL_INCLUDEDIR=include \ | |
88 | -DCMAKE_INSTALL_LIBDIR=%{_lib} | |
df9e9bf8 JB |
89 | |
90 | %{__make} | |
eb417e36 | 91 | |
92 | %install | |
93 | rm -rf $RPM_BUILD_ROOT | |
b57b5cf5 | 94 | |
b6febd90 JB |
95 | %if %{with static_libs} |
96 | %{__make} -C build-static install \ | |
97 | DESTDIR=$RPM_BUILD_ROOT | |
98 | %endif | |
99 | ||
100 | %{__make} -C build install \ | |
df9e9bf8 | 101 | DESTDIR=$RPM_BUILD_ROOT |
eb417e36 | 102 | |
103 | %clean | |
104 | rm -rf $RPM_BUILD_ROOT | |
105 | ||
ac28d4e4 JB |
106 | %post -p /sbin/ldconfig |
107 | %postun -p /sbin/ldconfig | |
eb417e36 | 108 | |
deff1af3 | 109 | %files |
eb417e36 | 110 | %defattr(644,root,root,755) |
aba80a59 | 111 | %doc NEWS.md README.md |
b57b5cf5 | 112 | %attr(755,root,root) %{_libdir}/libmatroska.so.*.*.* |
3dcf4f5a | 113 | %attr(755,root,root) %ghost %{_libdir}/libmatroska.so.7 |
eb417e36 | 114 | |
115 | %files devel | |
116 | %defattr(644,root,root,755) | |
b57b5cf5 | 117 | %attr(755,root,root) %{_libdir}/libmatroska.so |
ac28d4e4 | 118 | %{_includedir}/matroska |
df9e9bf8 | 119 | %{_pkgconfigdir}/libmatroska.pc |
78251059 | 120 | %{_libdir}/cmake/Matroska |
eb417e36 | 121 | |
b6febd90 | 122 | %if %{with static_libs} |
eb417e36 | 123 | %files static |
124 | %defattr(644,root,root,755) | |
125 | %{_libdir}/libmatroska.a | |
b6febd90 | 126 | %endif |