From 4af401f41b5cd69b4b41d0640d232d0502a188ac Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Thu, 29 Oct 2009 14:05:15 +0000 Subject: testing/icecast: added init.d script from gentoo --- testing/icecast/APKBUILD | 15 +++++++++++---- testing/icecast/icecast.initd | 18 ++++++++++++++++++ 2 files changed, 29 insertions(+), 4 deletions(-) create mode 100644 testing/icecast/icecast.initd (limited to 'testing/icecast') diff --git a/testing/icecast/APKBUILD b/testing/icecast/APKBUILD index b9d34f42..73135371 100644 --- a/testing/icecast/APKBUILD +++ b/testing/icecast/APKBUILD @@ -6,10 +6,11 @@ pkgrel=0 pkgdesc="Open source media server" url="http://www.icecast.org" license="GPL" -depends="busybox" +depends= makedepends="libxslt-dev libxml2-dev libogg-dev libvorbis-dev libtheora-dev" subpackages="$pkgname-doc" -source="http://downloads.xiph.org/releases/$pkgname/$pkgname-$pkgver.tar.gz" +source="http://downloads.xiph.org/releases/$pkgname/$pkgname-$pkgver.tar.gz + icecast.initd" build() { cd "$srcdir"/$pkgname-$pkgver @@ -18,8 +19,14 @@ build() { --sysconfdir=/etc \ --mandir=/usr/share/man \ --infodir=/usr/share/info - make || return 1 + make +} + +package() { + cd "$srcdir"/$pkgname-$pkgver make DESTDIR="$pkgdir" install + install -D -m755 ../icecast.initd "$pkgdir"/etc/init.d/icecast } -md5sums="ff516b3ccd2bcc31e68f460cd316093f icecast-2.3.2.tar.gz" +md5sums="ff516b3ccd2bcc31e68f460cd316093f icecast-2.3.2.tar.gz +b6f2fc5eaada6e9389784ccf43f68684 icecast.initd" diff --git a/testing/icecast/icecast.initd b/testing/icecast/icecast.initd new file mode 100644 index 00000000..b82e5cdd --- /dev/null +++ b/testing/icecast/icecast.initd @@ -0,0 +1,18 @@ +#!/sbin/runscript + +depend() { + need net + after firewall +} + +start() { + ebegin "Starting Icecast 2" + start-stop-daemon --background --start --make-pidfile --pidfile /var/run/icecast.pid --exec /usr/bin/icecast -- -c /etc/icecast.xml + eend $? +} + +stop() { + ebegin "Stopping Icecast 2" + start-stop-daemon --stop --pidfile /var/run/icecast.pid --name icecast + eend $? +} -- cgit v1.2.3