pulseaudio.spec revision 20885
10139N/A#
10139N/A# spec file for package pulseaudio
10139N/A#
11391N/A# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
10139N/A# This file and all modifications and additions to the pristine
10139N/A# package are under the same license as the package itself.
10139N/A#
10139N/A%define owner yippi
10139N/A# bugdb: bugzilla.freedesktop.org
10139N/A#
10139N/A
10139N/A%define src_name pulseaudio
11416N/A%define src_url http://freedesktop.org/software/pulseaudio/releases
11260N/A
10139N/AName: pulseaudio
10139N/ASummary: Sample Rate Converter for audio
10139N/AVersion: 1.1
11260N/ALicense: LGPLv2.1, MIT, Sun Public Domain
10139N/ASource: %{src_url}/%{src_name}-%{version}.tar.gz
10139N/ASource1: libtool-2.2.6b.tar.gz
10737N/A# date:2011-09-27 owner:yippi type:bug bugid:41537
10139N/APatch1: pulseaudio-01-esdcompat.diff
10737N/A# This patch is very rough, but gets the code to compile.
11419N/A# date:2011-09-27 owner:yippi type:bug bugid:41538
10139N/APatch2: pulseaudio-02-solaris.diff
10737N/A# date:2011-09-27 owner:yippi type:feature
11419N/APatch3: pulseaudio-03-libtool.diff
10139N/A# date:2011-10-05 owner:yippi type:feature bugid:41539
10941N/APatch4: pulseaudio-04-fixlink.diff
10139N/A# date:2011-10-06 owner:yippi type:feature
10941N/APatch5: pulseaudio-05-amd64.diff
11055N/A# /usr/include/sys/stream.h also defines module_info.
11055N/A# date:2011-10-14 owner:yippi type:bug bugid:41823
10941N/APatch6: pulseaudio-06-gconf.diff
10737N/A# date:2011-10-14 owner:yippi type:bug
11044N/APatch7: pulseaudio-07-shm.diff
11044N/A# date:2011-10-31 owner:yippi type:branding
11044N/A# This patch configures PulseAudio for Solaris, by enabling the OSSv4 module
10737N/A# for example, instead of using the SunAudio (solaris) module.
10139N/APatch8: pulseaudio-08-configure.diff
10139N/A# date:2011-11-30 owner:yippi type:bug
10139N/APatch9: pulseaudio-09-sada.diff
10139N/A# date:2011-12-13 owner:yippi type:bug
10139N/APatch10: pulseaudio-10-oss4.diff
10139N/ABuildRoot: %{_tmppath}/%{name}-%{version}-build
10139N/A
10139N/A%prep
10139N/A%setup -q -n pulseaudio-%version
10139N/A%patch1 -p1
10139N/A%patch2 -p1
10139N/Aperl -pi -e 's,/bin/sh,/bin/ksh,' src/daemon/esdcompat.in
10139N/A
10139N/A# Build libtool, with patch.
10139N/Agzcat %SOURCE1 | tar xf -
10139N/A%patch3 -p0
10139N/A
10139N/A%patch4 -p1
10139N/A%patch5 -p1
10139N/A%patch6 -p1
10737N/A%patch7 -p1
11419N/A%patch8 -p1
10139N/A%patch9 -p1
11419N/A%patch10 -p1
10139N/A
10139N/A%build
10740N/A# There seems to be an issue with the version of libtool that GStreamer is
10740N/A# now using. The libtool script uses the echo and RM variables but does not
10941N/A# define them, so setting them here addresses this.
10740N/Aexport echo="/usr/bin/echo"
11044N/Aexport RM="/usr/bin/rm -f"
11044N/A
10139N/ACPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '`
10139N/Aif test "x$CPUS" = "x" -o $CPUS = 0; then
10139N/A CPUS=1
10139N/Afi
10139N/A
10139N/A# Build newer libtool that PulseAudio needs. This should be removed when
10139N/A# libtool is updated.
10139N/A#
10139N/Aexport CFLAGS="%{optflags}"
10139N/Aexport LDFLAGS="%{_ldflags}"
10139N/Acd libtool-2.2.6b
10139N/A./configure \
10139N/A --prefix=%{_prefix} \
10139N/A --infodir=%{_infodir}
10139N/A
10139N/Amake -j$CPUS
10139N/A
10139N/Arm libltdl/.libs/*.a
10139N/Arm libltdl/.libs/*.la
10139N/Acd ..
10139N/A
10139N/A# Now build PulseAudio
10139N/A# Need to specify /usr/include/gc as an include directory since the atomic_ops
10139N/A# headers are delivered there on Solaris.
10139N/A#
10139N/Aexport CPPFLAGS="$SOLARIS_PULSE_CPPFLAGS"
10139N/Aexport CFLAGS="$SOLARIS_PULSE_CFLAGS -I/usr/include/gc"
10139N/Aexport LDFLAGS="$SOLARIS_PULSE_LDFLAGS"
10139N/A
10139N/Aautoreconf --force --install
10139N/A
10139N/A# We build PulseAudio without samplerate or bluez support since these are GPL
10139N/A# and it is not desirable to build PulseAudio with GPL code. Bluez is not
10139N/A# available anyway yet in Solaris, but disabling it just to ensure that it does
10139N/A# not build if bluez is added.
10139N/A#
10139N/A# We must turn off avahi for amd64 since avahi 64-bit is not available.
10139N/A./configure --prefix=%{_prefix} \
10139N/A --mandir=%{_mandir} \
10139N/A --bindir=%{_bindir} \
10139N/A --libdir=%{_libdir} \
10139N/A --libexecdir=%{_libexecdir} \
10139N/A --sysconfdir=%{_sysconfdir} \
10139N/A --disable-samplerate \
10139N/A --disable-bluez \
10139N/A $SOLARIS_PULSE_ARGS
10139N/A
10139N/Amake -j$CPUS
10139N/A
10139N/A%install
10139N/A# There seems to be an issue with the version of libtool that GStreamer is
10139N/A# now using. The libtool script uses the echo and RM variables but does not
10139N/A# define them, so setting them here addresses this.
10139N/Aexport echo="/usr/bin/echo"
10139N/Aexport RM="/usr/bin/rm -f"
10139N/A
10139N/Amake install DESTDIR=$RPM_BUILD_ROOT
10142N/A
10142N/Afind $RPM_BUILD_ROOT%{_libdir}/ -name "*.a" -exec rm {} \; -print -o -name "*.la" -exec rm {} \; -print
10139N/A
10139N/A%if %build_l10n
10139N/A%else
10139N/A# REMOVE l10n FILES
10139N/Arm -rf $RPM_BUILD_ROOT%{_datadir}/locale
10139N/A%endif
10139N/A
11419N/A%clean
11419N/Arm -rf $RPM_BUILD_ROOT
11416N/A
11416N/A%changelog
11391N/A* Thu Oct 20 2011 - Brian Cameron <brian.cameron@oracle.com>
11391N/A- Bump to 1.1.
11391N/A* Thu Oct 06 2011 - Brian Cameron <brian.cameron@oracle.com>
11260N/A- Split from SUNWpulseaudio.spec and now build amd64. Add the
11260N/A pulseaudio-05-amd64.diff patch.
11190N/A
11190N/A