]>
Commit | Line | Data |
---|---|---|
6e529ff8 | 1 | # TODO: port to standalone mp4v2 |
313e4f3c JB |
2 | # |
3 | # Conditional build: | |
6e529ff8 JR |
4 | %bcond_with mp4v2 # build with mp4v2 support |
5 | ||
14cee363 | 6 | %define major 0.5 |
2f94c4ac | 7 | Summary: The MusicBrainz tagging library |
1d7513e5 | 8 | Summary(pl.UTF-8): Biblioteka znakowania MusicBrainz |
2f94c4ac | 9 | Name: libtunepimp |
14cee363 | 10 | Version: %{major}.3 |
313e4f3c JB |
11 | Release: 20 |
12 | License: GPL v2+ | |
2f94c4ac | 13 | Group: Libraries |
313e4f3c | 14 | Source0: http://ftp.musicbrainz.org/pub/musicbrainz/historical/%{name}-%{version}.tar.gz |
b83e31ac | 15 | # Source0-md5: 09649f983acef679a548344ba7a9bb2f |
a40019e2 | 16 | Patch0: %{name}-ltdl.patch |
7e6206cd | 17 | Patch1: %{name}-mpeg4ip.patch |
1e0007f6 | 18 | Patch2: %{name}-gcc43.patch |
e5acd9f6 | 19 | Patch3: gcc44.patch |
313e4f3c | 20 | URL: https://wiki.musicbrainz.org/libtunepimp |
2f94c4ac JB |
21 | BuildRequires: autoconf >= 2.52 |
22 | BuildRequires: automake | |
a40019e2 JB |
23 | BuildRequires: curl-devel |
24 | BuildRequires: expat-devel | |
640006af | 25 | BuildRequires: flac-devel |
a40019e2 | 26 | BuildRequires: libltdl-devel |
2f94c4ac | 27 | BuildRequires: libmad-devel |
a041b484 | 28 | BuildRequires: libmusicbrainz-devel >= 2.1.0 |
a40019e2 | 29 | BuildRequires: libofa-devel >= 0.4.0 |
2f94c4ac JB |
30 | BuildRequires: libstdc++-devel >= 2:1.4d |
31 | BuildRequires: libtool | |
32 | BuildRequires: libvorbis-devel | |
6e529ff8 | 33 | %{?with_mp4v2:BuildRequires: mp4v2-devel} |
dad21fdb | 34 | BuildRequires: python-devel >= 1:2.5 |
a40019e2 | 35 | BuildRequires: rpm-pythonprov |
313e4f3c | 36 | BuildRequires: sed >= 4.0 |
bd146259 | 37 | BuildRequires: taglib-devel >= 1.4 |
a40019e2 | 38 | BuildRequires: zlib-devel |
2f94c4ac JB |
39 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
40 | ||
41 | %description | |
42 | The MusicBrainz tagging library. | |
43 | ||
1372dcb1 | 44 | %description -l pl.UTF-8 |
2f94c4ac JB |
45 | Biblioteka znakowania MusicBrainz. |
46 | ||
47 | %package devel | |
48 | Summary: Header files for libtunepimp library | |
1d7513e5 | 49 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libtunepimp |
2f94c4ac | 50 | Group: Development/Libraries |
a041b484 | 51 | Requires: %{name} = %{version}-%{release} |
23dda988 JB |
52 | Requires: curl-devel |
53 | Requires: expat-devel | |
a40019e2 | 54 | Requires: libltdl-devel |
a041b484 | 55 | Requires: libmusicbrainz-devel >= 2.1.0 |
a62fd4a4 | 56 | Requires: libofa-devel >= 0.4.0 |
112e17ae | 57 | Requires: libstdc++-devel >= 2:1.4d |
2f94c4ac JB |
58 | |
59 | %description devel | |
60 | Header files for libtunepimp library. | |
61 | ||
1372dcb1 JR |
62 | %description devel -l pl.UTF-8 |
63 | Pliki nagłówkowe biblioteki libtunepimp. | |
2f94c4ac JB |
64 | |
65 | %package static | |
66 | Summary: Static libtunepimp library | |
1d7513e5 | 67 | Summary(pl.UTF-8): Statyczna biblioteka libtunepimp |
2f94c4ac | 68 | Group: Development/Libraries |
a041b484 | 69 | Requires: %{name}-devel = %{version}-%{release} |
2f94c4ac JB |
70 | |
71 | %description static | |
72 | Static libtunepimp library. | |
73 | ||
1372dcb1 | 74 | %description static -l pl.UTF-8 |
2f94c4ac JB |
75 | Statyczna biblioteka libtunepimp. |
76 | ||
a40019e2 JB |
77 | %package -n python-tunepimp |
78 | Summary: Python bindings for libtunepimp library | |
1d7513e5 | 79 | Summary(pl.UTF-8): Wiązania Pythona do biblioteki libtunepimp |
a40019e2 JB |
80 | Group: Libraries/Python |
81 | %pyrequires_eq python-libs | |
82 | Requires: %{name} = %{version}-%{release} | |
a40019e2 JB |
83 | |
84 | %description -n python-tunepimp | |
85 | Python bindings for libtunepimp library. | |
86 | ||
1372dcb1 JR |
87 | %description -n python-tunepimp -l pl.UTF-8 |
88 | Wiązania Pythona do biblioteki libtunepimp. | |
a40019e2 | 89 | |
2f94c4ac JB |
90 | %prep |
91 | %setup -q | |
65af387d | 92 | %patch0 -p1 |
1e0007f6 | 93 | %patch2 -p1 |
e5acd9f6 | 94 | %patch3 -p1 |
6e529ff8 | 95 | %patch1 -p1 |
2f94c4ac | 96 | |
c41f0aab PS |
97 | %{__sed} -i 's/ -O2//' configure.in |
98 | %{__sed} -i 's/lt_dlhandle_struct \*/lt_dlhandle/' lib/plugins.cpp | |
313e4f3c | 99 | %{__sed} -i -e '1s,/usr/bin/env python,%{__python},' python/examples/trm.py |
bd146259 | 100 | |
2f94c4ac JB |
101 | %build |
102 | %{__libtoolize} | |
103 | %{__aclocal} | |
104 | %{__autoconf} | |
105 | %{__autoheader} | |
106 | %{__automake} | |
c41f0aab | 107 | %configure \ |
6e529ff8 | 108 | %{!?with_mp4v2:ac_cv_lib_mp4v2_MP4Read=false} \ |
313e4f3c | 109 | --disable-ltdl-install |
c41f0aab | 110 | |
2f94c4ac JB |
111 | %{__make} |
112 | ||
a40019e2 JB |
113 | # perl bindings are not updated to current API |
114 | #cd perl/tunepimp-perl | |
115 | #%{__perl} Makefile.PL \ | |
116 | # OPTIMIZE="%{rpmcflags}" | |
117 | #%{__make} | |
118 | # cd ../.. | |
119 | ||
120 | cd python | |
d47d7c73 | 121 | %py_build |
a40019e2 | 122 | |
2f94c4ac JB |
123 | %install |
124 | rm -rf $RPM_BUILD_ROOT | |
125 | ||
126 | %{__make} install \ | |
127 | DESTDIR=$RPM_BUILD_ROOT | |
128 | ||
bd146259 | 129 | # not installed, but used by installed headers (track.h, tunepimp.h) |
640006af | 130 | install lib/threads/posix/mutex.h \ |
a40019e2 JB |
131 | lib/{analyzer,filecache,plugins,readmeta,write}.h \ |
132 | include/tunepimp-*/metadata.h \ | |
14cee363 | 133 | $RPM_BUILD_ROOT%{_includedir}/tunepimp-%{major} |
a40019e2 JB |
134 | |
135 | #cd perl/tunepimp-perl | |
136 | #%{__make} install \ | |
137 | # DESTDIR=$RPM_BUILD_ROOT | |
138 | #install -D examples/tp_tagger.pl $RPM_BUILD_ROOT%{_bindir}/tp_tagger | |
139 | # cd ../.. | |
140 | ||
141 | cd python | |
d47d7c73 | 142 | %py_install |
a40019e2 | 143 | %py_postclean |
313e4f3c | 144 | install -Dp examples/trm.py $RPM_BUILD_ROOT%{_bindir}/trm |
2f94c4ac JB |
145 | |
146 | %clean | |
147 | rm -rf $RPM_BUILD_ROOT | |
148 | ||
149 | %post -p /sbin/ldconfig | |
150 | %postun -p /sbin/ldconfig | |
151 | ||
152 | %files | |
153 | %defattr(644,root,root,755) | |
154 | %doc AUTHORS ChangeLog README.LGPL TODO | |
a40019e2 JB |
155 | %attr(755,root,root) %{_bindir}/puid |
156 | %attr(755,root,root) %{_libdir}/libtunepimp.so.*.*.* | |
0c3e412c | 157 | %attr(755,root,root) %ghost %{_libdir}/libtunepimp.so.5 |
640006af PS |
158 | %dir %{_libdir}/tunepimp |
159 | %dir %{_libdir}/tunepimp/plugins | |
160 | %attr(755,root,root) %{_libdir}/tunepimp/plugins/*.tpp | |
2f94c4ac JB |
161 | |
162 | %files devel | |
163 | %defattr(644,root,root,755) | |
a40019e2 JB |
164 | %attr(755,root,root) %{_libdir}/libtunepimp.so |
165 | %{_libdir}/libtunepimp.la | |
14cee363 | 166 | %{_includedir}/tunepimp-%{major} |
2f94c4ac JB |
167 | |
168 | %files static | |
169 | %defattr(644,root,root,755) | |
a40019e2 JB |
170 | %{_libdir}/libtunepimp.a |
171 | ||
172 | %files -n python-tunepimp | |
173 | %defattr(644,root,root,755) | |
174 | %attr(755,root,root) %{_bindir}/trm | |
175 | %dir %{py_sitescriptdir}/tunepimp | |
176 | %{py_sitescriptdir}/tunepimp/*.py[co] | |
313e4f3c | 177 | %{py_sitescriptdir}/tunepimp-%{version}-py*.egg-info |