Blob Blame History Raw
# Minimum audacious/audacious-plugins version in inter-package
# dependencies.
# We enforce 2.4 as 2.2 or older is insufficient.
%define aud_ver 2.4

Name: audacious
Version: 2.4
Release: 0.4.alpha2%{?dist}

License: GPLv3
Summary: GTK2 based media player similar to XMMS
URL: http://audacious-media-player.org/
Group: Applications/Multimedia

Source0: http://distfiles.atheme.org/audacious-%{version}-alpha2.tgz

# only for --help
Patch1: audacious-2.4-doc-enqueue.patch

BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildRequires: gettext
BuildRequires: glib2-devel
BuildRequires: gtk2-devel
BuildRequires: libmowgli-devel
BuildRequires: mcs-devel
BuildRequires: libxml2-devel
BuildRequires: dbus-devel dbus-glib-devel
BuildRequires: libSM-devel
BuildRequires: desktop-file-utils

# The automatic SONAME dependency is not enough
# during version upgrades.
Requires: audacious-libs = %{version}-%{release}

Requires: audacious-plugins >= %{aud_ver}
Requires: hicolor-icon-theme

# Skin packages can require this from xmms and all GUI compatible players
Provides: xmms-gui

%description
Audacious is a media player that currently uses a skinned user interface
(based on Winamp 2.x skins) as well as a separate GTK2 based front end.
Historically, it started as a fork of Beep Media Player (BMP), which
itself forked from XMMS.


%package libs
Summary: Library files for the Audacious media player
Group: System Environment/Libraries

%description libs
Library files for the Audacious media player.


%package devel
Summary: Development files for the Audacious media player
Group: Development/Libraries
Requires: %{name}-libs = %{version}-%{release}
Requires: glib2-devel gtk2-devel
Requires: dbus-glib-devel
Requires: mcs-devel
Requires: libmowgli-devel
Requires: pkgconfig

%description devel
Files needed when building software for the Audacious media player.


%prep
%setup -q -n %{name}-%{version}-alpha2
sed -i '\,^.SILENT:,d' buildsys.mk.in
%patch1 -p1 -b .doc-enqueue

# From .desktop files remove MIME types the base build of the
# Fedora audacious-plugins package does not understand.
for t in \
    audio/mp3 \
    audio/mpeg \
    audio/mpegurl \
    audio/x-mp3 \
    audio/x-mpeg \
    audio/x-mpegurl \
    audio/x-ms-wma \
    audio/x-musepack \
    audio/prs.sid \
; do
    for f in audacious2.desktop audacious2-gtkui.desktop ; do
        cp ${f} ${f}.old
        sed -i "s!${t};!!g" $f
        diff -u ${f}.old ${f} || :
        rm -f ${f}.old
    done
done   


%build
%configure  \
    --with-buildstamp="Fedora package"  \
    --disable-sse2  \
    --disable-rpath \
    --disable-dependency-tracking
make %{?_smp_mflags}


%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p"
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'

%find_lang %{name}

desktop-file-install  \
    --dir $RPM_BUILD_ROOT%{_datadir}/applications  \
    --remove-mime-type audio/mp3  \
    --remove-mime-type audio/mpeg  \
    --remove-mime-type audio/mpegurl  \
    --remove-mime-type audio/x-mp3  \
    --remove-mime-type audio/x-mpeg  \
    --remove-mime-type audio/x-mpegurl  \
    --remove-mime-type audio/x-ms-wma  \
    --remove-mime-type audio/x-scpls  \
    --remove-category Application  \
    --add-category AudioVideo  \
    $RPM_BUILD_ROOT%{_datadir}/applications/audacious2.desktop


%clean
rm -rf $RPM_BUILD_ROOT


%post
update-desktop-database &> /dev/null || :
touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :

%postun
if [ $1 -eq 0 ] ; then
    touch --no-create %{_datadir}/icons/hicolor &>/dev/null
    gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
update-desktop-database &> /dev/null || :

%post libs -p /sbin/ldconfig

%postun libs -p /sbin/ldconfig

%posttrans
gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :


%files -f %{name}.lang
%defattr(-,root,root,-)
%doc AUTHORS COPYING NEWS README
%{_bindir}/audacious2
%{_bindir}/audacious
%{_bindir}/audtool2
%{_bindir}/audtool
%{_datadir}/audacious/
%{_mandir}/man[^3]/*
%{_datadir}/applications/*.desktop
%{_datadir}/pixmaps/*
%{_datadir}/icons/hicolor/*/apps/%{name}*.*

%files libs
%defattr(-,root,root,-)
# license file included also in this subpkg
# for Fedora Licensing Guidelines change (2010-07-07)
%doc COPYING
%{_libdir}/*.so.*

%files devel
%defattr(-,root,root,-)
%{_includedir}/audacious/
%{_includedir}/libaudcore/
%{_includedir}/libaudgui/
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc


%changelog
* Thu Jul  8 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.4-0.4.alpha2
- Include license file also in the -libs subpackage
  for Fedora Licensing Guidelines change (2010-07-07).

* Tue Jun 29 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.4-0.3.alpha2
- Update scriptlets for hicolor icon maintenance.
- Update to alpha2.

* Sat Jun 12 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.4-0.2.alpha1
- Use --with-buildstamp.

* Wed Jun  9 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.4-0.1.alpha1
- Drop obsolete BR libsamplerate-devel and --enable-samplerate.
- Upgrade to 2.4 alpha1.

* Wed Jun  9 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-16
- Enhance the coverart patch to not crash in URI conversion (#602113).

* Fri Apr 16 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-15
- Fix manual and --help for options -e/-E (#581394 and AUD-174).

* Sat Mar 20 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-14
- Unescape filename uri in fileinfo dialog to avoid g_markup crash (#575387).

* Sat Mar  6 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-13
- Enhance the coverart patch to not display an empty filename for
  streams when title isn't known yet and filename isn't either.

* Mon Feb 15 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-12
- Fix album cover art image loader (which cannot handle vfs URIs).

* Sat Feb 13 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-11
- Explicitly link with libm because of:
  http://fedoraproject.org/wiki/Features/ChangeInImplicitDSOLinking

* Thu Jan 28 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-10
- Fix tuple_copy() further (it was completely broken as the mowgli
  dict wasn't copied at all).

* Thu Jan 28 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-9
- Let set_tuple_cb() work on a copied tuple
  (the metadata updates flood is too racy IMO).
- Fix tuple_copy().

* Wed Jan 27 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-8
- Change build_stamp from "UNSUPPORTED VERSION" to "Fedora package".
- Always add category AudioVideo to .desktop file for safety reasons.

* Sat Jan 23 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-7
- Patch filename_find_decoder to probe a file if multiple decoders
  compete with eachother to handle files with the same extension.
  This also merges the 2nd chunk of the disabled-iplugins patch.

* Sun Jan 17 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-6
- In audacious.pc link with -laudcore instead of -laudclient (AUD-125).
  This removes a superfluous libaudclient dependency from all plugins and
  adds a libaudcore dependency. So far, plugins that use libaudcore
  had undefined symbols instead.

* Thu Jan  7 2010 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-5
- Apply fix for seeking to -1 milliseconds, causing a hangup (AUD-99).

* Thu Dec 31 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-4
- Added another fix to the disabled-iplugins patch.

* Wed Dec 30 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-3
- Patch Audacious so that filename_find_decoder only considers
  enabled input plugins (disabled modplug plugin effectively disabled
  also the xmp plugin).

* Wed Dec  2 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-2
- Drop Musepack and SID MIME types from desktop files. As of Audacious 2.2,
  Musepack is only supported by the separate "ffaudio" plugin. The SID
  plugin in a separate subpackage provides its own desktop file.
- Drop unsupported MIME types from desktop files.

* Wed Nov 25 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-1
- Upgrade to 2.2 (declared as the next "stable release" after 2.1).

* Tue Nov 10 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-0.1.beta2
- Upgrade to 2.2-beta2

* Thu Oct 22 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-0.1.beta1
- Upgrade to 2.2-beta1

* Sun Oct 18 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-0.1.alpha2
- Upgrade to 2.2-alpha2

* Sun Sep 20 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.2-0.1.alpha1
- Upgrade to 2.2-alpha1 (primarly for alsa-gapless output plugin).
- /usr/bin/audacious and /usr/bin/audtool compatibility links are now
  provided officially by upstream.

* Sun Sep 20 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.1-5
- /usr/bin/audacious and /usr/bin/audtool compatibility links are
  provided officially by upstream within 2.2-alpha1.

* Sat Sep 12 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.1-4
- Build with --enable-samplerate (off by default), BR libsamplerate-devel

* Mon Aug 24 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.1-3
- Default to PulseAudio output plugin: Fix pluginenum.c indentation
  to make output plugin default/priority init work. Actually, when I
  noticed this bug, I went a step further and copied a rewrite from
  upstream devel scm.

* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Tue Jul 14 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.1-1
- Upgrade to 2.1 final.

* Mon Jun 29 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.1-0.1.beta1
- Upgrade to 2.1beta1.
- Drop obsolete patches.

* Fri Jun  5 2009 Michael Schwendt <mschwendt@fedoraproject.org> - 2.0.1-0.1
- Initial package for Audacious 2.0.1
  based on a major spec overhaul of the older Fedora packages.