wok annotate mpd/receipt @ rev 15184
cherokee/stuff/cherokee: tiny edit
author | Richard Dunbar <mojo@slitaz.org> |
---|---|
date | Wed Aug 21 14:20:25 2013 +0000 (2013-08-21) |
parents | 6299ef313f35 |
children | 89e7debe3a7e |
rev | line source |
---|---|
paul@1375 | 1 # SliTaz package receipt. |
paul@1375 | 2 |
paul@1375 | 3 PACKAGE="mpd" |
devl547@13807 | 4 VERSION="0.17.2" |
paul@1375 | 5 CATEGORY="multimedia" |
paul@1375 | 6 SHORT_DESC="Music Player Daemon (MPD)." |
paul@1375 | 7 MAINTAINER="paul@slitaz.org" |
pascal@15001 | 8 LICENSE="GPL2" |
pascal@15001 | 9 TARBALL="$PACKAGE-$VERSION.tar.bz2" |
pascal@15001 | 10 WEB_SITE="http://www.musicpd.org/" |
pascal@15001 | 11 WGET_URL="$SF_MIRROR/musicpd/$TARBALL" |
pascal@15001 | 12 |
pascal@5004 | 13 DEPENDS="libid3tag libmad libogg libvorbis libsamplerate flac alsa-lib \ |
pascal@5004 | 14 audiofile faad2 lame sqlite libcurl glib libcrypto" |
paul@1387 | 15 BUILD_DEPENDS="alsa-lib-dev zlib-dev libid3tag-dev libsamplerate-dev \ |
pankso@3405 | 16 libmad-dev libogg-dev libvorbis-dev flac-dev libsamplerate \ |
paul@4808 | 17 libid3tag audiofile audiofile-dev faad2 faad2-dev pkg-config glib-dev lame-dev" |
paul@1375 | 18 |
paul@1375 | 19 # Rules to configure and make the package. |
paul@1375 | 20 compile_rules() |
paul@1375 | 21 { |
paul@1375 | 22 cd $src |
pascal@12676 | 23 sed -i 's/<stdbool.h>/&\n#include <stdio.h>/' src/decoder_api.h |
paul@1375 | 24 ./configure --prefix=/usr --infodir=/usr/share/info \ |
jozee@3699 | 25 --mandir=/usr/share/man \ |
jozee@3699 | 26 --disable-jack \ |
paul@4823 | 27 --disable-ao \ |
paul@4823 | 28 --disable-modplug \ |
paul@4823 | 29 --disable-mms \ |
paul@4823 | 30 --disable-ffmpeg \ |
paul@7796 | 31 --disable-wavpack \ |
paul@13816 | 32 --disable-systemd-daemon \ |
jozee@3699 | 33 --with-zeroconf=no \ |
jozee@3699 | 34 $CONFIGURE_ARGS && |
pascal@1484 | 35 make && |
devl547@13807 | 36 make DESTDIR=$DESTDIR install |
paul@1375 | 37 } |
paul@1375 | 38 |
paul@1375 | 39 # Rules to gen a SliTaz package suitable for Tazpkg. |
paul@1375 | 40 genpkg_rules() |
paul@1375 | 41 { |
paul@1375 | 42 mkdir -p $fs/usr/sbin |
paul@1375 | 43 mkdir -p $fs/etc |
devl547@13807 | 44 cp -a $install/usr/bin/mpd $fs/usr/sbin |
devl547@13807 | 45 cp $install/usr/share/doc/mpd/mpdconf.example $fs/etc/mpd.conf |
pascal@10908 | 46 cp -a $stuff/* $fs |
paul@1375 | 47 } |
paul@1375 | 48 |
paul@1375 | 49 post_install() |
paul@1375 | 50 { |
paul@1375 | 51 echo "Processing post-install commands..." |
paul@1375 | 52 |
paul@1375 | 53 # Drop root priviledges and enable pid file |
paul@1375 | 54 echo -n "Enabling mpd.conf..." |
paul@1375 | 55 cd $1/etc |
paul@4808 | 56 sed -i 's/#music_directory/music_directory/; \ |
paul@4808 | 57 s/#playlist_directory/playlist_directory/; \ |
paul@4808 | 58 s/#db_file/db_file/; \ |
paul@4808 | 59 s/#pid_file/pid_file/; \ |
paul@4808 | 60 s/#user "nobody"/user "tux"/; \ |
paul@4808 | 61 s/#bind_to_address "any"/bind_to_address "localhost"/' mpd.conf |
paul@1375 | 62 status |
paul@1375 | 63 |
paul@1375 | 64 # Make mpd directories and files |
paul@4808 | 65 echo -n "Enabling mpd files and directories..." |
paul@1375 | 66 mkdir /home/tux/music |
paul@1375 | 67 mkdir -p /home/tux/.mpd/playlists |
paul@1375 | 68 touch /home/tux/.mpd/mpd.log |
paul@4808 | 69 #touch /home/tux/.mpd/mpd.error |
paul@13816 | 70 cp -a /etc/mpd.conf /home/tux/.mpd |
paul@1375 | 71 |
paul@1375 | 72 # And change permissions |
paul@11814 | 73 chown tux:users /home/tux/music |
paul@11814 | 74 chown -R tux:users /home/tux/.mpd |
paul@1375 | 75 status |
paul@1375 | 76 } |
paul@1375 | 77 |