Bug 145779 - [patch] audio/icecast2: rc setting icecast_config
Summary: [patch] audio/icecast2: rc setting icecast_config
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Sahil Tandon
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-17 15:50 UTC by Jille
Modified: 2010-04-24 21:50 UTC (History)
0 users

See Also:


Attachments
icecast2.sh.in.txt (1.16 KB, text/plain)
2010-04-17 16:37 UTC, Jille
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jille 2010-04-17 15:50:01 UTC
	This patch adds the rc.conf setting to specify another config file than the default of /usr/local/etc/icecast.xml.

Fix: 

--- icecast2    (from port)
+++ icecast2    (my version)
@@ -8,12 +8,16 @@
 # BEFORE:  LOGIN
 # KEYWORD: shutdown

-# Add the following line to /etc/rc.conf to enable `icecast2'. This requires
-# a working configuration in /usr/local/etc/icecast.xml.
+# Add the following line to /etc/rc.conf to enable `icecast2'.
 #
 #icecast_enable="YES"
 #
-# Make sure the <changeowner> section in your /usr/local/etc/icecast.xml is
+# You can specify another configuration file than /usr/local/etc/icecast.xml
+# by adding the following line.
+#
+#icecast_config="/usr/local/etc/icecast.xml"
+#
+# Make sure the <changeowner> section in your configuration file is
 # not commented out - icecast refuses to run as root.
 #

@@ -24,11 +24,13 @@

 command="/usr/local/bin/icecast"
 command_args="-b 1>/dev/null"
-required_files="/usr/local/etc/$name.xml"

 # read configuration and set defaults
 load_rc_config "$name"
 : ${icecast_enable="NO"}
-: ${icecast_flags="-c ${required_files}"}
+: ${icecast_config="/usr/local/etc/$name.xml"}
+: ${icecast_flags="-c ${icecast_config}"}
+
+required_files="${icecast_config}"

 run_rc_command "$1"
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2010-04-17 15:50:10 UTC
Maintainer of audio/icecast2,

Please note that PR ports/145779 has just been submitted.

If it contains a patch for an upgrade, an enhancement or a bug fix
you agree on, reply to this email stating that you approve the patch
and a committer will take care of it.

The full text of the PR can be found at:
    http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/145779

-- 
Edwin Groothuis via the GNATS Auto Assign Tool
edwin@FreeBSD.org
Comment 2 Edwin Groothuis freebsd_committer freebsd_triage 2010-04-17 15:50:12 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Comment 3 Sahil Tandon freebsd_committer freebsd_triage 2010-04-17 16:07:27 UTC
Responsible Changed
From-To: freebsd-ports-bugs->sahil

I'll take it.
Comment 4 Sahil Tandon freebsd_committer freebsd_triage 2010-04-17 16:16:20 UTC
Please submit a patch vs. icecast2.sh.in in the port's files/ directory,
and not vs. the version installed on your system; diff'ing vs. the
latter is problematic because it has already expanded variables like
%%PREFIX%% to /usr/local.

-- 
Sahil Tandon <sahil@FreeBSD.org>
Comment 5 Jille 2010-04-17 16:37:02 UTC
I'm sorry. Here you go.

-- Jille

Sahil Tandon schreef:
> Please submit a patch vs. icecast2.sh.in in the port's files/ directory,
> and not vs. the version installed on your system; diff'ing vs. the
> latter is problematic because it has already expanded variables like
> %%PREFIX%% to /usr/local.
> 
Comment 6 dfilter service freebsd_committer freebsd_triage 2010-04-24 21:45:14 UTC
sahil       2010-04-24 20:45:06 UTC

  FreeBSD ports repository

  Modified files:
    audio/icecast2/files icecast2.sh.in 
  Log:
  - Add support for custom config file location
  
  PR:             ports/145779
  Submitted by:   Jille Timmermans <jille@quis.cx>
  Approved by:    Sunpoet Hsieh (maintainer), wxs@ (mentor)
  
  Revision  Changes    Path
  1.7       +12 -6     ports/audio/icecast2/files/icecast2.sh.in
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 7 Sahil Tandon freebsd_committer freebsd_triage 2010-04-24 21:45:29 UTC
State Changed
From-To: feedback->closed

Committed, with minor changes. Thanks!