collectd: don't presume /usr/local in plist

Re:
https://github.com/Homebrew/homebrew/pull/37966#issuecomment-84656418

Closes Homebrew/homebrew#37984.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
master
Dominyk Tiller 2015-03-23 01:58:50 +00:00 committed by Mike McQuaid
parent 95e42a8e71
commit c56d92256a
1 changed files with 10 additions and 6 deletions

View File

@ -10,8 +10,11 @@ class Collectd < Formula
end
# Will fail against Java 1.7
option "java", "Enable Java 1.6 support"
option "debug", "Enable debug support"
option "with-java", "Enable Java 1.6 support"
option "with-debug", "Enable debug support"
deprecated_option "java" => "with-java"
deprecated_option "debug" => "with-debug"
head do
url "git://git.verplant.org/collectd.git"
@ -22,6 +25,7 @@ class Collectd < Formula
end
depends_on "pkg-config" => :build
depends_on :java => ["1.6", :optional]
depends_on "openssl"
fails_with :clang do
@ -41,8 +45,8 @@ class Collectd < Formula
]
args << "--disable-embedded-perl" if MacOS.version <= :leopard
args << "--disable-java" unless build.include? "java"
args << "--enable-debug" if build.include? "debug"
args << "--disable-java" if build.without? "java"
args << "--enable-debug" if build.with? "debug"
system "./build.sh" if build.head?
system "./configure", *args
@ -68,9 +72,9 @@ class Collectd < Formula
<key>RunAtLoad</key>
<true/>
<key>StandardErrorPath</key>
<string>/usr/local/var/log/collectd.log</string>
<string>#{var}/log/collectd.log</string>
<key>StandardOutPath</key>
<string>/usr/local/var/log/collectd.log</string>
<string>#{var}/log/collectd.log</string>
</dict>
</plist>
EOS