wok-current view mpd/receipt @ rev 4591

Add speedtouch modem
author Rohit Joshi <jozee@slitaz.org>
date Thu Dec 10 13:29:28 2009 +0000 (2009-12-10)
parents 57acddb48af0
children f3cbdc461ad8
line source
1 # SliTaz package receipt.
3 PACKAGE="mpd"
4 VERSION="0.13.2"
5 CATEGORY="multimedia"
6 SHORT_DESC="Music Player Daemon (MPD)."
7 MAINTAINER="paul@slitaz.org"
8 DEPENDS="libid3tag libmad libogg libvorbis libsamplerate flac alsa-lib audiofile faad2"
9 BUILD_DEPENDS="alsa-lib-dev zlib-dev libid3tag-dev libsamplerate-dev \
10 libmad-dev libogg-dev libvorbis-dev flac-dev libsamplerate \
11 libid3tag audiofile audiofile-dev faad2 faad2-dev pkg-config"
12 TARBALL="$PACKAGE-$VERSION.tar.bz2"
13 WEB_SITE="http://www.musicpd.org/"
14 WGET_URL="$SF_MIRROR/musicpd/$TARBALL"
17 # Rules to configure and make the package.
18 compile_rules()
19 {
20 cd $src
21 ./configure --prefix=/usr --infodir=/usr/share/info \
22 --mandir=/usr/share/man \
23 --disable-jack \
24 --with-zeroconf=no \
25 $CONFIGURE_ARGS &&
26 make &&
27 make DESTDIR=$PWD/_pkg install
28 }
30 # Rules to gen a SliTaz package suitable for Tazpkg.
31 genpkg_rules()
32 {
33 mkdir -p $fs/usr/sbin
34 mkdir -p $fs/etc
35 cp -a $_pkg/usr/bin/mpd $fs/usr/sbin
36 cp $_pkg/usr/share/doc/mpd/mpdconf.example $fs/etc/mpd.conf
37 }
39 post_install()
40 {
41 echo "Processing post-install commands..."
43 # Drop root priviledges and enable pid file
44 echo -n "Enabling mpd.conf..."
45 cd $1/etc
46 sed -i 's/#pid_file/pid_file/; \
47 s/#user/user/; s/#bind_to_address/bind_to_address/; \
48 s/"nobody"/"tux"/; s/"any"/"localhost"/' mpd.conf
49 status
51 # Make mpd directories and files
52 echo -n "Enabling mpd files and directories"
53 mkdir /home/tux/music
54 mkdir -p /home/tux/.mpd/playlists
55 touch /home/tux/.mpd/mpd.log
56 touch /home/tux/.mpd/mpd.error
58 # And change permissions
59 chown tux:tux /home/tux/music
60 chown -R tux:tux /home/tux/.mpd
61 status
62 }