summaryrefslogtreecommitdiff
path: root/community/icecast
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2013-08-13 01:33:19 -0700
committerroot <root@rshg054.dnsready.net>2013-08-13 01:33:19 -0700
commit7a65a910b77ad191d69881098c47f9b0c852d92e (patch)
tree9564e611af1442f8952a8cbddb3b0ad25ed71aab /community/icecast
parent60da6abff6c9577a783d72865f11de7a585e912e (diff)
Tue Aug 13 01:31:08 PDT 2013
Diffstat (limited to 'community/icecast')
-rw-r--r--community/icecast/PKGBUILD52
-rw-r--r--community/icecast/icecast.logrotate8
-rw-r--r--community/icecast/icecast.service9
-rw-r--r--community/icecast/start-by-nobody.patch15
4 files changed, 84 insertions, 0 deletions
diff --git a/community/icecast/PKGBUILD b/community/icecast/PKGBUILD
new file mode 100644
index 000000000..aad4ca008
--- /dev/null
+++ b/community/icecast/PKGBUILD
@@ -0,0 +1,52 @@
+# $Id: PKGBUILD 90559 2013-05-13 07:47:15Z lfleischer $
+# Maintainer:
+# Contributor: Andrea Scarpino <andrea@archlinux.org>
+# Contributor: Andreas Radke <andyrtr@archlinux.org>
+# Contributor: Jason Chu <jchu@xentac.net>
+
+pkgname=icecast
+pkgver=2.3.3
+pkgrel=4
+pkgdesc='Streaming audio over the Internet'
+arch=('i686' 'x86_64')
+license=('GPL')
+url='http://www.icecast.org/'
+depends=('libxslt' 'libvorbis' 'curl' 'speex' 'libtheora')
+backup=('etc/icecast.xml'
+ 'etc/logrotate.d/icecast')
+source=("http://downloads.us.xiph.org/releases/${pkgname}/${pkgname}-${pkgver}.tar.gz"
+ 'icecast.logrotate'
+ 'start-by-nobody.patch'
+ 'icecast.service')
+md5sums=('2b5d1b40778922e5f6431b7758c359ad'
+ '59c6552bcb1dd9fb542af8670dfabd3c'
+ 'd8e929d2214123a1954da4383bf16583'
+ '1468e59f76de194579b615889e20198f')
+
+build() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ patch -Np1 -i "${srcdir}/start-by-nobody.patch"
+
+ ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var
+ make
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ make DESTDIR="${pkgdir}" install
+
+ # install man page
+ sed -i -e 's/icecast2/icecast/g' debian/icecast2.1
+ install -Dm644 debian/icecast2.1 "${pkgdir}/usr/share/man/man1/icecast.1"
+
+ # install logrotate config (taken from Fedora)
+ install -Dm644 "${srcdir}/icecast.logrotate" "${pkgdir}/etc/logrotate.d/icecast"
+
+ # create log directory
+ install -d -g99 -o99 "${pkgdir}/var/log/icecast"
+
+ # install systemd unit
+ install -Dm0644 "${srcdir}/icecast.service" "${pkgdir}/usr/lib/systemd/system/icecast.service"
+}
diff --git a/community/icecast/icecast.logrotate b/community/icecast/icecast.logrotate
new file mode 100644
index 000000000..0fb014c06
--- /dev/null
+++ b/community/icecast/icecast.logrotate
@@ -0,0 +1,8 @@
+/var/log/icecast/*log {
+ missingok
+ notifempty
+ sharedscripts
+ postrotate
+ endscript
+}
+
diff --git a/community/icecast/icecast.service b/community/icecast/icecast.service
new file mode 100644
index 000000000..2f4b0eb29
--- /dev/null
+++ b/community/icecast/icecast.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Icecast Network Audio Streaming Server
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/icecast -c /etc/icecast.xml
+
+[Install]
+WantedBy=multi-user.target
diff --git a/community/icecast/start-by-nobody.patch b/community/icecast/start-by-nobody.patch
new file mode 100644
index 000000000..d218e5afe
--- /dev/null
+++ b/community/icecast/start-by-nobody.patch
@@ -0,0 +1,15 @@
+--- icecast-2.3.2/conf/icecast.xml.in~ 2010-11-12 16:47:54.750000918 +0100
++++ icecast-2.3.2/conf/icecast.xml.in 2010-11-12 16:48:08.086667585 +0100
+@@ -164,11 +164,9 @@
+
+ <security>
+ <chroot>0</chroot>
+- <!--
+ <changeowner>
+ <user>nobody</user>
+- <group>nogroup</group>
++ <group>nobody</group>
+ </changeowner>
+- -->
+ </security>
+ </icecast>