2009-11-17 18:29:10 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class GnuProlog < Formula
|
2009-11-17 18:29:10 +00:00
|
|
|
homepage 'http://www.gprolog.org/'
|
2011-09-05 03:37:27 +00:00
|
|
|
url 'http://gprolog.univ-paris1.fr/gprolog-1.4.0.tar.gz'
|
2011-07-10 16:50:54 +00:00
|
|
|
md5 'cc944e5637a04a9184c8aa46c947fd16'
|
2009-11-17 18:29:10 +00:00
|
|
|
|
2010-04-07 05:58:35 +00:00
|
|
|
skip_clean :all
|
2009-11-17 18:29:10 +00:00
|
|
|
|
2011-09-05 03:37:27 +00:00
|
|
|
# Support OSX x86-64. See:
|
|
|
|
# https://github.com/mxcl/homebrew/pull/7428
|
|
|
|
# http://lists.gnu.org/archive/html/users-prolog/2011-09/msg00004.html
|
|
|
|
# Includes previous inreplace fix from:
|
|
|
|
# http://lists.gnu.org/archive/html/users-prolog/2011-07/msg00013.html
|
|
|
|
def patches
|
|
|
|
"https://gist.github.com/raw/1191268/35db85d5cfe5ecd5699286bdd945856ea9cee1a1/patch-x86_64-darwin.diff"
|
|
|
|
end
|
2011-08-19 19:59:50 +00:00
|
|
|
|
2009-11-17 18:29:10 +00:00
|
|
|
def install
|
2010-04-07 05:58:35 +00:00
|
|
|
ENV.j1 # make won't run in parallel
|
2010-01-01 08:14:37 +00:00
|
|
|
|
2012-02-21 06:04:21 +00:00
|
|
|
cd 'src' do
|
2011-09-05 03:37:27 +00:00
|
|
|
args = ["--prefix=#{prefix}"]
|
|
|
|
|
|
|
|
if MacOS.prefer_64_bit?
|
|
|
|
args << "--build=x86_64-apple-darwin" << "--host=x86_64-apple-darwin"
|
|
|
|
end
|
2011-08-29 02:17:39 +00:00
|
|
|
|
2011-09-05 03:37:27 +00:00
|
|
|
system "./configure", *args
|
2009-11-17 18:29:10 +00:00
|
|
|
system "make"
|
|
|
|
system "make install-strip"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|