]>
Commit | Line | Data |
---|---|---|
db8b1635 AO |
1 | # |
2 | # Conditional build: | |
d85de49c JP |
3 | %bcond_without libxmp # libxmp use for MOD support |
4 | %bcond_with modplug # modplug use for MOD support (libxmp is used by default) | |
5 | %bcond_without mpg123 # libmpg123 use for MP3 support | |
6 | %bcond_without static_libs # static library | |
db8b1635 | 7 | # |
5ffcc3bb JB |
8 | # NOTE: libraries dlopened by sonames detected at build time: |
9 | # libFLAC.so.8 | |
10 | # libfluidsynth.so.1 | |
7fdf80cc | 11 | # libgme.so.0 |
5ffcc3bb | 12 | # libmodplug.so.1 |
0aaa6fd5 JB |
13 | # libmpg123.so.0 |
14 | # libopusfile.so.0 | |
5ffcc3bb | 15 | # libvorbisfile.so.3 |
7fdf80cc | 16 | # libwavpack.so.1 |
b5a5314d | 17 | # libxmp.so.4 |
5ffcc3bb | 18 | # |
db8b1635 AO |
19 | Summary: Simple DirectMedia Layer - Sample Mixer Library |
20 | Summary(pl.UTF-8): Simple DirectMedia Layer - biblioteka miksująca próbki dźwiękowe | |
21 | Summary(pt_BR.UTF-8): SDL2 - Biblioteca para mixagem | |
22 | Name: SDL2_mixer | |
7fdf80cc | 23 | Version: 2.8.0 |
b5a5314d | 24 | Release: 1 |
db8b1635 AO |
25 | License: Zlib-like |
26 | Group: Libraries | |
b5a5314d | 27 | Source0: https://github.com/libsdl-org/SDL_mixer/releases/download/release-%{version}/%{name}-%{version}.tar.gz |
7fdf80cc | 28 | # Source0-md5: 6c4b2936784856c575b838a5731a23d1 |
b5a5314d JP |
29 | URL: https://github.com/libsdl-org/SDL_mixer |
30 | BuildRequires: SDL2-devel >= 2.0.9 | |
db8b1635 AO |
31 | BuildRequires: autoconf |
32 | BuildRequires: automake | |
33 | BuildRequires: flac-devel >= 1.3.0 | |
5791969b | 34 | BuildRequires: fluidsynth-devel |
7fdf80cc | 35 | BuildRequires: game-music-emu-devel |
db8b1635 | 36 | BuildRequires: libtool >= 2:2.0 |
5791969b | 37 | %{?with_modplug:BuildRequires: libmodplug-devel >= 0.8.8} |
0aaa6fd5 | 38 | %{?with_mpg123:BuildRequires: libmpg123-devel} |
5791969b | 39 | BuildRequires: libogg-devel |
db8b1635 | 40 | BuildRequires: libvorbis-devel >= 1:1.0 |
b5a5314d | 41 | %{?with_libxmp:BuildRequires: libxmp-devel >= 4.2} |
0aaa6fd5 | 42 | BuildRequires: opusfile-devel >= 0.2 |
5791969b | 43 | BuildRequires: pkgconfig >= 1:0.9.0 |
d85de49c | 44 | BuildRequires: rpmbuild(macros) >= 1.527 |
7fdf80cc | 45 | BuildRequires: wavpack-devel >= 4.0 |
b5a5314d JP |
46 | Requires: SDL2 >= 2.0.9 |
47 | %{?with_libxmp:Suggests: libxmp >= 4.2} | |
5791969b | 48 | %{?with_modplug:Suggests: libmodplug >= 0.8.8} |
0aaa6fd5 | 49 | Suggests: opusfile >= 0.2 |
db8b1635 AO |
50 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
51 | ||
52 | %description | |
53 | Due to popular demand, here is a simple multi-channel audio mixer. It | |
54 | supports 4 channels of 16 bit stereo audio, plus a single channel of | |
c9b48446 | 55 | music, mixed by the popular MikMod MOD, Timidity MIDI and MPG123 MP3 |
db8b1635 AO |
56 | libraries. |
57 | ||
58 | %description -l pl.UTF-8 | |
59 | SDL2_mixer to prosty wielokanałowy mikser audio. Obsługuje 4 kanały | |
60 | 16-bitowego dźwięku stereo plus jeden kanał dla muzyki miksowanej | |
c9b48446 | 61 | przez popularne biblioteki MikMod MOD, Timitity MIDI i MPG123 MP3. |
db8b1635 AO |
62 | |
63 | %description -l pt_BR.UTF-8 | |
64 | Biblioteca que suporta 4 canais de áudio estéreo 16 bit, mais um canal | |
65 | de música, mixado pelo populares bibliotecas MOD MikMod, MIDI timidity | |
c9b48446 | 66 | e MPG123 MP3. |
db8b1635 AO |
67 | |
68 | %package devel | |
69 | Summary: Header files and more to develop SDL_mixer applications | |
5ffcc3bb | 70 | Summary(pl.UTF-8): Pliki nagłówkowe do rozwoju aplikacji używających biblioteki SDL_mixer |
db8b1635 AO |
71 | Summary(pt_BR.UTF-8): Bibliotecas e arquivos de inclusão para desenvolvimento de aplicações SDL |
72 | Group: Development/Libraries | |
73 | Requires: %{name} = %{version}-%{release} | |
b5a5314d | 74 | Requires: SDL2-devel >= 2.0.9 |
db8b1635 AO |
75 | |
76 | %description devel | |
77 | Header files and more to develop SDL2_mixer applications. | |
78 | ||
79 | %description devel -l pl.UTF-8 | |
5ffcc3bb JB |
80 | Pliki nagłówkowe do rozwoju aplikacji używających biblioteki |
81 | SDL2_mixer. | |
db8b1635 AO |
82 | |
83 | %description devel -l pt_BR.UTF-8 | |
84 | Bibliotecas e arquivos de inclusão para desenvolvimento de aplicações | |
85 | SDL2. | |
86 | ||
87 | %package static | |
88 | Summary: Static SDL2_mixer library | |
89 | Summary(pl.UTF-8): Statyczna biblioteka SDL2_mixer | |
90 | Summary(pt_BR.UTF-8): Bibliotecas estáticas para desenvolvimento com SDL2_mixer | |
91 | Group: Development/Libraries | |
92 | Requires: %{name}-devel = %{version}-%{release} | |
93 | ||
94 | %description static | |
95 | Static SDL2_mixer library. | |
96 | ||
97 | %description static -l pl.UTF-8 | |
98 | Statyczna biblioteka SDL2_mixer. | |
99 | ||
100 | %description static -l pt_BR.UTF-8 | |
101 | Bibliotecas estáticas para desenvolvimento com SDL2_mixer. | |
102 | ||
103 | %prep | |
104 | %setup -q | |
5791969b JB |
105 | |
106 | %{__rm} acinclude/{libtool,lt*}.m4 | |
db8b1635 AO |
107 | |
108 | %build | |
5791969b | 109 | %{__libtoolize} |
db8b1635 AO |
110 | %{__aclocal} -I acinclude |
111 | %{__autoconf} | |
112 | %configure \ | |
d85de49c | 113 | %{__enable_disable static_libs static} \ |
b5a5314d | 114 | --disable-music-flac-drflac \ |
7fdf80cc | 115 | --disable-music-mp3-minimp3 \ |
b5a5314d JP |
116 | --disable-music-ogg-stb \ |
117 | --enable-music-flac-libflac \ | |
118 | --enable-music-ogg-vorbis \ | |
7fdf80cc JP |
119 | %{!?with_libxmp:--disable-music-mod-xmp} \ |
120 | %{?with_modplug:--enable-music-mod-modplug} \ | |
b5a5314d | 121 | %{?with_mpg123:--enable-music-mp3-mpg123} |
db8b1635 AO |
122 | %{__make} |
123 | ||
124 | %install | |
125 | rm -rf $RPM_BUILD_ROOT | |
126 | ||
127 | %{__make} install install-bin \ | |
128 | DESTDIR=$RPM_BUILD_ROOT | |
129 | ||
0aaa6fd5 JB |
130 | %{__mv} $RPM_BUILD_ROOT%{_bindir}/playmus $RPM_BUILD_ROOT%{_bindir}/playmus2 |
131 | %{__mv} $RPM_BUILD_ROOT%{_bindir}/playwave $RPM_BUILD_ROOT%{_bindir}/playwave2 | |
db8b1635 | 132 | |
172c0ad2 JB |
133 | # obsoleted by pkg-config |
134 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libSDL2_mixer.la | |
135 | ||
db8b1635 AO |
136 | %clean |
137 | rm -rf $RPM_BUILD_ROOT | |
138 | ||
139 | %post -p /sbin/ldconfig | |
140 | %postun -p /sbin/ldconfig | |
141 | ||
142 | %files | |
143 | %defattr(644,root,root,755) | |
b5a5314d | 144 | %doc CHANGES.txt LICENSE.txt README.txt |
db8b1635 AO |
145 | %attr(755,root,root) %{_bindir}/playmus2 |
146 | %attr(755,root,root) %{_bindir}/playwave2 | |
147 | %attr(755,root,root) %{_libdir}/libSDL2_mixer-2.0.so.*.*.* | |
148 | %attr(755,root,root) %ghost %{_libdir}/libSDL2_mixer-2.0.so.0 | |
149 | ||
150 | %files devel | |
151 | %defattr(644,root,root,755) | |
152 | %attr(755,root,root) %{_libdir}/libSDL2_mixer.so | |
b5a5314d | 153 | %{_libdir}/cmake/SDL2_mixer |
db8b1635 AO |
154 | %{_includedir}/SDL2/SDL_mixer.h |
155 | %{_pkgconfigdir}/SDL2_mixer.pc | |
156 | ||
d85de49c | 157 | %if %{with static_libs} |
db8b1635 AO |
158 | %files static |
159 | %defattr(644,root,root,755) | |
160 | %{_libdir}/libSDL2_mixer.a | |
d85de49c | 161 | %endif |