Commit ebc906a6 authored by Led's avatar Led

0.13.0-alt2

parent f8c99c8e
tar.bz2: @version@:. tar.bz2: @version@:.
copy: *.conf copy: *.conf *.in *.patch
diff -urN mpd-0.13.0.orig/configure.ac mpd-0.13.0/configure.ac
--- mpd-0.13.0.orig/configure.ac 2007-05-28 16:19:32 +0300
+++ mpd-0.13.0/configure.ac 2007-09-13 17:29:48 +0300
@@ -81,7 +81,14 @@
AC_ARG_ENABLE(id3,[ --disable-id3 disable id3 support (default: enable)],[enable_id3=$enableval],[enable_id3=yes])
AC_ARG_ENABLE(lsr,[ --disable-lsr disable libsamplerate support (default: enable)],[enable_lsr=$enableval],[enable_lsr=yes])
-AC_ARG_WITH(tremor,[[ --with-tremor[=PFX] Use Tremor(vorbisidec) integer Ogg-Vorbis decoder (with optional prefix)]], use_tremor=yes; test x$withval != xyes && tremor_prefix="$withval",)
+AC_ARG_WITH(tremor,[[ --with-tremor[=PFX] Use Tremor(vorbisidec) integer Ogg-Vorbis decoder (with optional prefix)]],
+ if test "x$withval" = xyes -o "x$withval" = xno; then
+ use_tremor="$withval"
+ else
+ use_tremor=yes
+ tremor_prefix="$withval"
+ fi
+,)
AC_ARG_WITH(tremor-libraries,[ --with-tremor-libraries=DIR Directory where Tremor library is installed (optional)], tremor_libraries="$withval", tremor_libraries="")
AC_ARG_WITH(tremor-includes,[ --with-tremor-includes=DIR Directory where Tremor header files are installed (optional)], tremor_includes="$withval", tremor_includes="")
@@ -170,7 +177,7 @@
fi
if test x$enable_shout = xyes; then
- XIPH_PATH_SHOUT([AC_DEFINE(HAVE_SHOUT, 1, [Define to enable libshout support]) MPD_LIBS="$MPD_LIBS $SHOUT_LIBS" MPD_CFLAGS="$MPD_CFLAGS $SHOUT_CFLAGS"], enable_shout=no)
+ XIPH_PATH_SHOUT([AC_DEFINE(HAVE_SHOUT, 1, [Define to enable libshout support]) MPD_LIBS="$MPD_LIBS $SHOUT_LIBS" MPD_CFLAGS="$MPD_CFLAGS $SHOUT_CFLAGS $SHOUT_CPPFLAGS"], enable_shout=no)
fi
if test x$enable_oss = xyes; then
music_directory "~/MyMusic" ######################## REQUIRED PATHS ###############################
playlist_directory "~/MyMusic" music_directory "~/Music"
log_file "~/MyMusic/mpd.log" playlist_directory "~/.mpd/playlists"
db_file "~/MyMusic/mpd.db" log_file "~/.mpd/mpd.log"
error_file "~/MyMusic/mpd.err" db_file "~/.mpd/mpd.db"
state_file "~/MyMusic/mpd.state" error_file "~/.mpd/mpd.error"
port "6600" #######################################################################
######################## OPTIONAL PATHS ###############################
pid_file "~/.mpd/mpd.pid"
state_file "~/.mpd/mpdstate"
#######################################################################
######################## DAEMON OPTIONS ###############################
#user "nobody"
bind_to_address "127.0.0.1" bind_to_address "127.0.0.1"
#bind_to_address "any"
port "6600"
# "default", "secure", or "verbose".
log_level "default"
#zeroconf_name "Music Player"
audio_output { audio_output {
type "ao" type "alsa"
name "ao_alsa_out" name "alsa"
device "alsa09"
} }
#samplerate_converter "Fastest Sinc Interpolator"
mixer_type "alsa"
mixer_device "default"
mixer_control "PCM"
#mixer_type "software"
#replaygain "album"
#volume_normalization "no"
#audio_buffer_size "2048"
#buffer_before_play "10%"
#http_buffer_size "128"
#http_prebuffer_size "25%"
########################### HTTP PROXY ################################
#http_proxy_host "proxy"
#http_proxy_port "8080"
#http_proxy_user "user"
#http_proxy_password "password"
############################# LIMITS ##################################
#connection_timeout "60"
#max_connections "5"
#max_playlist_length "16384"
#max_command_list_size "2048"
#max_output_buffer_size "8192"
###################### CHARACTER ENCODINGS ############################
#filesystem_charset "ISO-8859-1"
id3v1_encoding "CP1251"
######################### OTHER OPTIONS ###############################
#gapless_mp3_playback "yes"
#save_absolute_paths_in_playlists "no"
#metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc"
#!/bin/sh
#
# mpd This shell script takes care of starting and stopping
# Music Player Daemon (MPD).
# chkconfig: - 99 01
# description: Music Player Daemon (MPD) allows remote access \
# for playing music and managing playlists.
# processname: mpd
# config: /etc/mpd.sys.conf
# pidfile: /var/run/mpd.pid
# Do not load RH compatibility interface.
WITHOUT_RC_COMPAT=1
# Source function library.
. /etc/init.d/functions
USER=@MPD_USER@
CONFFILE=/etc/mpd.sys.conf
PIDFILE=/var/run/mpd/pid
LOCKFILE=/var/lock/subsys/mpd
RETVAL=0
start()
{
start_daemon --lockfile "$LOCKFILE" --expect-user $USER -- mpd $CONFFILE
RETVAL=$?
return $RETVAL
}
stop()
{
stop_daemon --lockfile "$LOCKFILE" --expect-user $USER -- mpd --kill $CONFFILE
RETVAL=$?
return $RETVAL
}
restart()
{
stop
start
}
createdb()
{
mpd --create-db $CONFFILE
RETVAL=$?
return $RETVAL
}
case "$1" in
start)
start
;;
stop)
stop
;;
restart)
restart
;;
condstop)
if [ -e "$LOCKFILE" ]; then
stop
fi
;;
condrestart)
if [ -e "$LOCKFILE" ]; then
restart
fi
;;
createdb)
createdb
;;
status)
status --pidfile "$PIDFILE" --expect-user $USER -- mpd
RETVAL=$?
;;
*)
msg_usage "${0##*/} {start|stop|restart|condstop|condrestart|createdb|status}"
RETVAL=1
esac
exit $RETVAL
%def_with pic
%def_enable ao %def_enable ao
%def_enable shout %def_enable shout
%def_enable iconv %def_enable iconv
...@@ -7,6 +5,7 @@ ...@@ -7,6 +5,7 @@
%def_disable sun %def_disable sun
%def_enable oss %def_enable oss
%def_enable alsa %def_enable alsa
%def_enable jack
%def_enable pulse %def_enable pulse
%def_enable mvp %def_enable mvp
%def_enable oggvorbis %def_enable oggvorbis
...@@ -19,7 +18,11 @@ ...@@ -19,7 +18,11 @@
%def_enable faad %def_enable faad
%def_enable mpc %def_enable mpc
%def_enable id3 %def_enable id3
%def_enable lsr
%def_without tremor %def_without tremor
%define zeroconf avahi
%define mpd_user _mpd
%define mpd_group audio
#---------------------------------------------------------------------- #----------------------------------------------------------------------
%define set_disable() %{expand:%%force_disable %{1}} %{expand:%%undefine _enable_%{1}} %define set_disable() %{expand:%%force_disable %{1}} %{expand:%%undefine _enable_%{1}}
...@@ -27,50 +30,71 @@ ...@@ -27,50 +30,71 @@
%set_disable shout %set_disable shout
%set_disable oggflac %set_disable oggflac
%endif %endif
%{!?zeroconf:%define zeroconf no}
%define Name MPD
Name: mpd Name: mpd
Version: 0.13.0 Version: 0.13.0
Release: alt1 Release: alt2
Summary: Music Player Daemon (MPD) allows remote access for playing music and managing playlists. Summary: Music Player Daemon (%Name) allows remote access for playing music and managing playlists.
License: GPL License: %gpl2plus
Group: Sound Group: Sound
URL: http://musicpd.org/ URL: http://musicpd.org/
Source0: http://musicpd.org/uploads/files/%name-%version.tar.bz2 Source0: http://musicpd.org/uploads/files/%name-%version.tar.bz2
Source1: %name.conf Source1: %name.conf
Source2: %name.sys.conf.in
Source3: %name.init.in
Patch: %name-0.13.0-configure.patch
# Automatically added by buildreq on Tue Sep 11 2007
#BuildRequires: gcc-c++ glibc-devel-static jackit-devel libalsa-devel libao-devel libaudiofile-devel libavahi-devel libfaad-devel libflac-devel libid3tag-devel libmad-devel libmikmod-devel libmpcdec-devel libpulseaudio-devel libsamplerate-devel libshout2-devel zlib-devel
# Automatically added by buildreq on Wed Jan 10 2007 BuildRequires: zlib-devel rpm-build-licenses
BuildRequires: gcc-c++ zlib-devel libsamplerate-devel
%{?_enable_alsa:BuildRequires: libalsa-devel >= 0.9.0} %{?_enable_alsa:BuildRequires: libalsa-devel >= 0.9.0}
%{?_enable_jack:BuildRequires: jackit-devel}
%{?_enable_ao:BuildRequires: libao-devel} %{?_enable_ao:BuildRequires: libao-devel}
%{?_enable_shout:BuildRequires: libshout2-devel} %{?_enable_shout:BuildRequires: libshout2-devel}
%{?_enable_audiofile:BuildRequires: libaudiofile-devel >= 0.1.7} %{?_enable_audiofile:BuildRequires: libaudiofile-devel >= 0.1.7}
%{?_enable_mod:BuildRequires: libmikmod-devel >= 3.1.7} %{?_enable_mod:BuildRequires: libmikmod-devel >= 3.1.7}
%{?_enable_faad:BuildRequires: libfaad-devel} %{?_enable_faad:BuildRequires: libfaad-devel}
%{?_enable_flac:BuildRequires: libflac-devel} %{?_enable_flac:BuildRequires: libflac-devel >= 1.1.3}
%{?_enable_oggflac:BuildRequires: liboggflac-devel} %{?_enable_oggflac:BuildRequires: liboggflac-devel}
%{?_enable_id3:BuildRequires: libid3tag-devel} %{?_enable_id3:BuildRequires: libid3tag-devel}
%{?_enable_mp3:BuildRequires: libmad-devel} %{?_enable_mp3:BuildRequires: libmad-devel}
%{?_enable_mpc:BuildRequires: libmpcdec-devel} %{?_enable_mpc:BuildRequires: libmpcdec-devel}
%{?_enable_pulse:BuildRequires: libpulseaudio-devel} %{?_enable_pulse:BuildRequires: libpulseaudio-devel}
%{?_enable_oggvorbis:BuildRequires: libvorbis-devel} %{?_enable_oggvorbis:BuildRequires: libvorbis-devel}
%{?_enable_lsr:BuildRequires: libsamplerate-devel}
%if %zeroconf == avahi
BuildRequires: libavahi-devel
%endif
%description %description
Music Player Daemon (MPD) allows remote access for playing music Music Player Daemon (%Name) allows remote access for playing music
(MP3, Ogg Vorbis, FLAC, AAC, Mod, and wave files) and managing (MP3, Ogg Vorbis, FLAC, AAC, Mod, and wave files) and managing
playlists. MPD is designed for integrating a computer into a stereo playlists. %Name is designed for integrating a computer into a stereo
system that provides control for music playback over a local network. system that provides control for music playback over a local network.
It is also makes a great desktop music player, especially if you are a It is also makes a great desktop music player, especially if you are a
console junkie, like frontend options, or restart X often. console junkie, like frontend options, or restart X often.
%prep %prep
%setup -q %setup
%patch -p1
%if "%{get_version libflac-devel}" >= "1.1.3"
subst 's/AM_PATH_LIBOGGFLAC/AM_PATH_LIBFLAC/' configure.ac
%endif
%build %build
%add_optflags -I/usr/include/shout2 %define _optlevel 3
%__autoreconf
%configure \ %configure \
%{subst_with pic} \ %ifarch x86_64
--with-pic \
%endif
%{subst_with tremor} \
%{subst_enable ao} \ %{subst_enable ao} \
%{subst_enable shout} \ %{subst_enable shout} \
%{subst_enable iconv} \ %{subst_enable iconv} \
...@@ -78,6 +102,7 @@ console junkie, like frontend options, or restart X often. ...@@ -78,6 +102,7 @@ console junkie, like frontend options, or restart X often.
%{subst_enable sun} \ %{subst_enable sun} \
%{subst_enable oss} \ %{subst_enable oss} \
%{subst_enable alsa} \ %{subst_enable alsa} \
%{subst_enable jack} \
%{subst_enable pulse} \ %{subst_enable pulse} \
%{subst_enable mvp} \ %{subst_enable mvp} \
%{subst_enable oggvorbis} \ %{subst_enable oggvorbis} \
...@@ -89,26 +114,56 @@ console junkie, like frontend options, or restart X often. ...@@ -89,26 +114,56 @@ console junkie, like frontend options, or restart X often.
%{subst_enable mod} \ %{subst_enable mod} \
%{subst_enable mpc} \ %{subst_enable mpc} \
%{subst_enable id3} \ %{subst_enable id3} \
--disable-libOggFLACtest %{subst_enable lsr} \
--with-zeroconf=%zeroconf
%make_build %make_build
bzip2 --best --keep --force ChangeLog
%install %install
%make_install DESTDIR=%buildroot docdir=%_docdir/%name-%version install %make_install DESTDIR=%buildroot docdir=%_docdir/%name-%version install
install -pD -m 0644 %SOURCE1 %buildroot%_sysconfdir/%name.conf install -d %buildroot{%_localstatedir/%name/playlists,{/var/run,%_logdir}/%name,%_sysconfdir,%_initdir}
bzip2 --best --keep --force ChangeLog install -m 0644 %SOURCE1 %buildroot%_sysconfdir/%name.conf
sed 's/@MPD_USER@/%mpd_user/g' %SOURCE2 > %buildroot%_sysconfdir/%name.sys.conf
chmod 640 %buildroot%_sysconfdir/%name.sys.conf
sed 's/@MPD_USER@/%mpd_user/g' %SOURCE3 > %buildroot%_initdir/%name
chmod 755 %buildroot%_initdir/%name
%pre
/usr/sbin/useradd -r -n -s /dev/null -d %_localstatedir/%name -g %mpd_group -c "Music Player Daemon (%Name)" %mpd_user 2> /dev/null ||:
%post
%post_service %name ||:
%preun
%preun_service %name ||:
%files %files
%doc AUTHORS ChangeLog.* README TODO UPGRADING doc/{%{name}conf.example,COMMANDS} %doc AUTHORS ChangeLog.* README TODO UPGRADING doc/{%{name}conf.example,COMMANDS}
%config(noreplace) %_sysconfdir/* %config(noreplace) %_sysconfdir/%name.conf
%config(noreplace) %_sysconfdir/%name.sys.conf
%_bindir/* %_bindir/*
%_man1dir/* %_man1dir/*
%_man5dir/* %_man5dir/*
%_initdir/*
%attr(755,%mpd_user,%mpd_group) %dir %_localstatedir/%name
%attr(755,%mpd_user,%mpd_group) %dir %_localstatedir/%name/playlists
%attr(755,%mpd_user,%mpd_group) %dir /var/run/%name
%attr(755,%mpd_user,%mpd_group) %dir %_logdir/%name
%changelog %changelog
* Thu Sep 13 2007 Led <led@altlinux.ru> 0.13.0-alt2
- added init script (fixed #12707)
- updated default %_sysconfdir/%name.conf
- added default %_sysconfdir/%name.sys.conf (for system wide service)
- updated mpd-0.13.0-configure.patch
- fixed License
* Mon Sep 10 2007 Alex Gorbachenko (agent_007) <algor@altlinux.ru> 0.13.0-alt1 * Mon Sep 10 2007 Alex Gorbachenko (agent_007) <algor@altlinux.ru> 0.13.0-alt1
- 0.13.0. - 0.13.0.
- fix build with libshout2 (#12708). - fix build with libshout2 (#12708).
......
######################## REQUIRED PATHS ###############################
music_directory "/var/empty"
playlist_directory "/var/lib/mpd/playlists"
log_file "/var/log/mpd/info"
db_file "/var/lib/mpd/mpd.db"
error_file "/var/log/mpd/errors"
#######################################################################
######################## OPTIONAL PATHS ###############################
pid_file "/var/run/mpd/pid"
state_file "/var/lib/mpd/state"
#######################################################################
######################## DAEMON OPTIONS ###############################
user "@MPD_USER@"
bind_to_address "127.0.0.1"
#bind_to_address "any"
port "6600"
# "default", "secure", or "verbose".
log_level "default"
#zeroconf_name "Music Player"
########################## PERMISSIONS ################################
#password "password@read,add,control,admin"
#default_permissions "read,add,control,admin"
audio_output {
type "alsa"
name "alsa"
}
#audio_output {
# type "shout"
# name "My Shout Stream"
# host "localhost"
# port "8000"
# mount "/mpd.ogg"
# password "hackme"
# quality "5.0"
# bitrate "128"
# format "44100:16:1"
# user "source" # optional
# description "My Stream Description" # optional
# genre "jazz" # optional
# public "no" # optional
#}
#samplerate_converter "Fastest Sinc Interpolator"
mixer_type "alsa"
mixer_device "default"
mixer_control "PCM"
#mixer_type "software"
#replaygain "album"
#volume_normalization "no"
#audio_buffer_size "2048"
#buffer_before_play "10%"
#http_buffer_size "128"
#http_prebuffer_size "25%"
########################### HTTP PROXY ################################
#http_proxy_host "proxy"
#http_proxy_port "8080"
#http_proxy_user "user"
#http_proxy_password "password"
############################# LIMITS ##################################
#connection_timeout "60"
#max_connections "5"
#max_playlist_length "16384"
#max_command_list_size "2048"
#max_output_buffer_size "8192"
###################### CHARACTER ENCODINGS ############################
#filesystem_charset "ISO-8859-1"
id3v1_encoding "CP1251"
######################### OTHER OPTIONS ###############################
#gapless_mp3_playback "yes"
#save_absolute_paths_in_playlists "no"
#metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment