2009-10-15 08:07:12 +00:00
|
|
|
require 'formula'
|
2009-06-04 18:21:19 +00:00
|
|
|
|
|
|
|
class Cmake <Formula
|
2010-11-10 06:07:01 +00:00
|
|
|
url 'http://www.cmake.org/files/v2.8/cmake-2.8.3.tar.gz'
|
|
|
|
md5 'a76a44b93acf5e3badda9de111385921'
|
2009-11-30 13:57:36 +00:00
|
|
|
homepage 'http://www.cmake.org/'
|
2009-06-04 18:21:19 +00:00
|
|
|
|
|
|
|
def install
|
2010-11-10 06:07:01 +00:00
|
|
|
# If we specify to CMake to use the system libraries by passing
|
|
|
|
# --system-libs to bootstrap then it insists on finding them all
|
|
|
|
# or erroring out, as that's what other Linux/OSX distributions
|
|
|
|
# would want. I've requested that they either fix this or let us
|
|
|
|
# submit a patch to do so on their bug tracker:
|
|
|
|
# http://www.cmake.org/Bug/view.php?id=11431
|
2009-07-28 01:28:46 +00:00
|
|
|
inreplace 'CMakeLists.txt',
|
|
|
|
"# Mention to the user what system libraries are being used.",
|
2010-11-12 03:04:09 +00:00
|
|
|
"SET(CMAKE_USE_SYSTEM_LIBARCHIVE 0)"
|
2009-07-28 01:28:46 +00:00
|
|
|
|
2009-08-07 14:41:43 +00:00
|
|
|
system "./bootstrap", "--prefix=#{prefix}",
|
|
|
|
"--system-libs",
|
|
|
|
"--datadir=/share/cmake",
|
|
|
|
"--docdir=/share/doc/cmake",
|
|
|
|
"--mandir=/share/man"
|
2010-07-15 04:50:29 +00:00
|
|
|
system "make"
|
2009-06-04 18:21:19 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
2009-11-30 13:57:36 +00:00
|
|
|
end
|