wok-next view mpd/receipt @ rev 14243

lirc: remove incompatible drivers
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Mar 23 10:06:31 2013 +0100 (2013-03-23)
parents 0747d5d72804
children 408c87fa22ca
line source
1 # SliTaz package receipt.
3 PACKAGE="mpd"
4 VERSION="0.17.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 \
9 audiofile faad2 lame sqlite libcurl glib libcrypto"
10 BUILD_DEPENDS="alsa-lib-dev zlib-dev libid3tag-dev libsamplerate-dev \
11 libmad-dev libogg-dev libvorbis-dev flac-dev libsamplerate \
12 libid3tag audiofile audiofile-dev faad2 faad2-dev pkg-config glib-dev lame-dev"
13 TARBALL="$PACKAGE-$VERSION.tar.bz2"
14 WEB_SITE="http://www.musicpd.org/"
15 WGET_URL="$SF_MIRROR/musicpd/$TARBALL"
18 # Rules to configure and make the package.
19 compile_rules()
20 {
21 cd $src
22 sed -i 's/<stdbool.h>/&\n#include <stdio.h>/' src/decoder_api.h
23 ./configure --prefix=/usr --infodir=/usr/share/info \
24 --mandir=/usr/share/man \
25 --disable-jack \
26 --disable-ao \
27 --disable-modplug \
28 --disable-mms \
29 --disable-ffmpeg \
30 --disable-wavpack \
31 --disable-systemd-daemon \
32 --with-zeroconf=no \
33 $CONFIGURE_ARGS &&
34 make &&
35 make DESTDIR=$DESTDIR install
36 }
38 # Rules to gen a SliTaz package suitable for Tazpkg.
39 genpkg_rules()
40 {
41 mkdir -p $fs/usr/sbin
42 mkdir -p $fs/etc
43 cp -a $install/usr/bin/mpd $fs/usr/sbin
44 cp $install/usr/share/doc/mpd/mpdconf.example $fs/etc/mpd.conf
45 cp -a $stuff/* $fs
46 }
48 post_install()
49 {
50 echo "Processing post-install commands..."
52 # Drop root priviledges and enable pid file
53 echo -n "Enabling mpd.conf..."
54 cd $1/etc
55 sed -i 's/#music_directory/music_directory/; \
56 s/#playlist_directory/playlist_directory/; \
57 s/#db_file/db_file/; \
58 s/#pid_file/pid_file/; \
59 s/#user "nobody"/user "tux"/; \
60 s/#bind_to_address "any"/bind_to_address "localhost"/' mpd.conf
61 status
63 # Make mpd directories and files
64 echo -n "Enabling mpd files and directories..."
65 mkdir /home/tux/music
66 mkdir -p /home/tux/.mpd/playlists
67 touch /home/tux/.mpd/mpd.log
68 #touch /home/tux/.mpd/mpd.error
69 cp -a /etc/mpd.conf /home/tux/.mpd
71 # And change permissions
72 chown tux:users /home/tux/music
73 chown -R tux:users /home/tux/.mpd
74 status
75 }