homebrew-core/Formula/opentracker.rb
Jack Nagel 7c648d9732 Shore up a number of shell quoting issues
When interpolating in strings passed to Formula#system, it should be
done in such a way that if any interpolated variables contain spaces,
they are either (a) passed as part of a list or (b) protected by quotes
if they are part of a long string (which is subject to shell expansion).
Otherwise, they will be split on the space when expanded by the shell
and passed as multiple arguments to whatever process is being executed.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-05-15 14:03:11 -05:00

26 lines
828 B
Ruby

require 'formula'
class Libowfat < Formula
url 'http://dl.fefe.de/libowfat-0.28.tar.bz2'
md5 '6bbee9a86506419657d87123b7a6f2c1'
homepage 'http://www.fefe.de/libowfat/'
end
class Opentracker < Formula
head 'cvs://:pserver:anoncvs:@cvs.erdgeist.org:/home/cvsroot:opentracker'
homepage 'http://erdgeist.org/arts/software/opentracker/'
def install
# First libowfat must be compiled and installed where opentracker is expecting it
libowfat_include = Pathname.new(pwd) + 'libowfat'
Libowfat.new.brew do
system "make", "install", "INCLUDEDIR=#{libowfat_include}", "LIBDIR=#{libowfat_include}", "MAN3DIR=."
end
# Tell opentracker that libowfat headers are located in the same directory as itself
ENV['PREFIX'] = '.'
system "make", "opentracker"
bin.install "opentracker"
end
end