aboutsummaryrefslogtreecommitdiffstats
path: root/audio/icecast/files
diff options
context:
space:
mode:
authorKoop Mast <kwm@rainbow-runner.nl>2018-11-12 00:22:39 +0800
committerKoop Mast <kwm@rainbow-runner.nl>2018-11-12 00:22:39 +0800
commit9b580ffb435c69606f640c5a657190b54a1ef870 (patch)
treeb85006a979d929da61946937a62b6c6b97fa4c79 /audio/icecast/files
parent6a4416929169733984a0ac898468560f66931e1c (diff)
parentf86bb659dcd66c74ffce85ffcc1575d2095989f8 (diff)
downloadfreebsd-ports-gnome-gnome-3.28.tar.gz
freebsd-ports-gnome-gnome-3.28.tar.zst
freebsd-ports-gnome-gnome-3.28.zip
Merge branch 'master' into gnome-3.28gnome-3.28
Diffstat (limited to 'audio/icecast/files')
-rw-r--r--audio/icecast/files/icecast.in41
-rw-r--r--audio/icecast/files/patch-conf-Makefile.in12
-rw-r--r--audio/icecast/files/pkg-message.in18
3 files changed, 71 insertions, 0 deletions
diff --git a/audio/icecast/files/icecast.in b/audio/icecast/files/icecast.in
new file mode 100644
index 000000000000..83261185e2af
--- /dev/null
+++ b/audio/icecast/files/icecast.in
@@ -0,0 +1,41 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: icecast
+# REQUIRE: DAEMON
+# BEFORE: LOGIN
+# KEYWORD: shutdown
+
+# Add the following line to /etc/rc.conf to enable `icecast'.
+#
+#icecast_enable="YES"
+#
+# To specify a non-default configuration file, set icecast_config
+# in /etc/rc.conf:
+#
+#icecast_config="%%PREFIX%%/etc/icecast.xml"
+#
+# Make sure the <changeowner> section in your configuration file is
+# not commented out - icecast refuses to run as root.
+#
+
+. /etc/rc.subr
+
+name="icecast"
+rcvar=icecast_enable
+
+command="%%PREFIX%%/bin/icecast"
+command_args="-b 1>/dev/null"
+extra_commands="reload"
+
+# read configuration and set defaults
+load_rc_config "$name"
+: ${icecast_enable="NO"}
+: ${icecast_config="%%PREFIX%%/etc/${name}.xml"}
+: ${icecast_flags="-c ${icecast_config}"}
+
+required_files="${icecast_config}"
+
+run_rc_command "$1"
diff --git a/audio/icecast/files/patch-conf-Makefile.in b/audio/icecast/files/patch-conf-Makefile.in
new file mode 100644
index 000000000000..d515eed5ad6a
--- /dev/null
+++ b/audio/icecast/files/patch-conf-Makefile.in
@@ -0,0 +1,12 @@
+--- conf/Makefile.in.orig 2016-01-04 21:07:07 UTC
++++ conf/Makefile.in
+@@ -539,8 +539,7 @@ uninstall-am: uninstall-docDATA
+
+ install-data-hook:
+ $(mkinstalldirs) $(DESTDIR)$(sysconfdir)
+- test -f $(DESTDIR)$(sysconfdir)/icecast.xml || \
+- $(INSTALL_DATA) icecast.xml.dist $(DESTDIR)$(sysconfdir)/icecast.xml
++ $(INSTALL_DATA) icecast.xml.dist $(DESTDIR)$(sysconfdir)/icecast.xml.sample
+
+ icecast.xml.dist: $(srcdir)/icecast.xml.in
+ $(edit) $(srcdir)/icecast.xml.in > icecast.xml.dist
diff --git a/audio/icecast/files/pkg-message.in b/audio/icecast/files/pkg-message.in
new file mode 100644
index 000000000000..0bb7e6898662
--- /dev/null
+++ b/audio/icecast/files/pkg-message.in
@@ -0,0 +1,18 @@
+To start icecast at system boot, copy
+%%PREFIX%%/etc/icecast.xml.sample to %%PREFIX%%/etc/icecast.xml, customize
+to your environment as desired and add:
+
+icecast_enable="yes"
+
+to /etc/rc.conf. See the icecast -h command for optional additional
+flags. To specify an alternative config file for example add:
+
+icecast_flags="-c /path/to/your/configuration.xml"
+
+**********************************************************************
+** Make sure the <changeowner> section in your configuration file **
+** is NOT commented out. Icecast will refuse to run as root. **
+** **
+** Also make sure that the user you choose is able to write to your **
+** configured log directory, otherwise icecast will refuse to run. **
+**********************************************************************