wok annotate mpd/receipt @ rev 8588
Declare source tarball of mplayer-codecs
author | Antoine Bodin <gokhlayeh@slitaz.org> |
---|---|
date | Mon Feb 14 03:54:53 2011 +0100 (2011-02-14) |
parents | 0e2015438912 |
children | 6b5247b899e5 |
rev | line source |
---|---|
paul@1375 | 1 # SliTaz package receipt. |
paul@1375 | 2 |
paul@1375 | 3 PACKAGE="mpd" |
paul@7946 | 4 VERSION="0.16.1" |
paul@1375 | 5 CATEGORY="multimedia" |
paul@1375 | 6 SHORT_DESC="Music Player Daemon (MPD)." |
paul@1375 | 7 MAINTAINER="paul@slitaz.org" |
pascal@5004 | 8 DEPENDS="libid3tag libmad libogg libvorbis libsamplerate flac alsa-lib \ |
pascal@5004 | 9 audiofile faad2 lame sqlite libcurl glib libcrypto" |
paul@1387 | 10 BUILD_DEPENDS="alsa-lib-dev zlib-dev libid3tag-dev libsamplerate-dev \ |
pankso@3405 | 11 libmad-dev libogg-dev libvorbis-dev flac-dev libsamplerate \ |
paul@4808 | 12 libid3tag audiofile audiofile-dev faad2 faad2-dev pkg-config glib-dev lame-dev" |
jozee@3699 | 13 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
paul@1375 | 14 WEB_SITE="http://www.musicpd.org/" |
jozee@3699 | 15 WGET_URL="$SF_MIRROR/musicpd/$TARBALL" |
jozee@3699 | 16 |
paul@1375 | 17 |
paul@1375 | 18 # Rules to configure and make the package. |
paul@1375 | 19 compile_rules() |
paul@1375 | 20 { |
paul@1375 | 21 cd $src |
paul@1375 | 22 ./configure --prefix=/usr --infodir=/usr/share/info \ |
jozee@3699 | 23 --mandir=/usr/share/man \ |
jozee@3699 | 24 --disable-jack \ |
paul@4823 | 25 --disable-ao \ |
paul@4823 | 26 --disable-modplug \ |
paul@4823 | 27 --disable-mms \ |
paul@4823 | 28 --disable-ffmpeg \ |
paul@7796 | 29 --disable-libwrap \ |
paul@7796 | 30 --disable-wavpack \ |
jozee@3699 | 31 --with-zeroconf=no \ |
jozee@3699 | 32 $CONFIGURE_ARGS && |
pascal@1484 | 33 make && |
paul@1375 | 34 make DESTDIR=$PWD/_pkg install |
paul@1375 | 35 } |
paul@1375 | 36 |
paul@1375 | 37 # Rules to gen a SliTaz package suitable for Tazpkg. |
paul@1375 | 38 genpkg_rules() |
paul@1375 | 39 { |
paul@1375 | 40 mkdir -p $fs/usr/sbin |
paul@1375 | 41 mkdir -p $fs/etc |
paul@1375 | 42 cp -a $_pkg/usr/bin/mpd $fs/usr/sbin |
paul@1375 | 43 cp $_pkg/usr/share/doc/mpd/mpdconf.example $fs/etc/mpd.conf |
paul@1375 | 44 } |
paul@1375 | 45 |
paul@1375 | 46 post_install() |
paul@1375 | 47 { |
paul@1375 | 48 echo "Processing post-install commands..." |
paul@1375 | 49 |
paul@1375 | 50 # Drop root priviledges and enable pid file |
paul@1375 | 51 echo -n "Enabling mpd.conf..." |
paul@1375 | 52 cd $1/etc |
paul@4808 | 53 sed -i 's/#music_directory/music_directory/; \ |
paul@4808 | 54 s/#playlist_directory/playlist_directory/; \ |
paul@4808 | 55 s/#db_file/db_file/; \ |
paul@4808 | 56 s/#pid_file/pid_file/; \ |
paul@4808 | 57 s/#user "nobody"/user "tux"/; \ |
paul@4808 | 58 s/#bind_to_address "any"/bind_to_address "localhost"/' mpd.conf |
paul@1375 | 59 status |
paul@1375 | 60 |
paul@1375 | 61 # Make mpd directories and files |
paul@4808 | 62 echo -n "Enabling mpd files and directories..." |
paul@1375 | 63 mkdir /home/tux/music |
paul@1375 | 64 mkdir -p /home/tux/.mpd/playlists |
paul@1375 | 65 touch /home/tux/.mpd/mpd.log |
paul@4808 | 66 #touch /home/tux/.mpd/mpd.error |
paul@1375 | 67 |
paul@1375 | 68 # And change permissions |
paul@1375 | 69 chown tux:tux /home/tux/music |
paul@1375 | 70 chown -R tux:tux /home/tux/.mpd |
paul@1375 | 71 status |
paul@1375 | 72 } |
paul@1375 | 73 |