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