7c648d9732
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>
29 lines
681 B
Ruby
29 lines
681 B
Ruby
require 'formula'
|
|
|
|
class Camlp5 < Formula
|
|
url 'http://pauillac.inria.fr/~ddr/camlp5/distrib/src/camlp5-5.15.tgz'
|
|
homepage 'http://pauillac.inria.fr/~ddr/camlp5/'
|
|
md5 '67ccbf37ffe33dec137ee71ca6189ea2'
|
|
|
|
depends_on 'objective-caml'
|
|
|
|
def options
|
|
[['--strict', "Compile in strict mode"]]
|
|
end
|
|
|
|
def install
|
|
|
|
# compile for strict or transitional
|
|
if ARGV.include? '--strict'
|
|
strictness = "-strict"
|
|
else
|
|
strictness = "-transitional"
|
|
end
|
|
|
|
system "./configure", "-prefix", prefix, "-mandir", man, strictness
|
|
# this build fails if jobs are parallelized
|
|
ENV.deparallelize
|
|
system "make world.opt"
|
|
system "make install"
|
|
end
|
|
end
|