2011-03-06 20:20:54 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class GdalGrass < Formula
|
2011-03-06 20:20:54 +00:00
|
|
|
homepage 'http://www.gdal.org'
|
|
|
|
url 'http://download.osgeo.org/gdal/gdal-grass-1.4.3.tar.gz'
|
2012-09-03 18:33:56 +00:00
|
|
|
sha1 '63b87ad1688cc365dc6bd6c3ccc854d0e6aa637a'
|
2011-03-06 20:20:54 +00:00
|
|
|
|
|
|
|
depends_on 'gdal'
|
|
|
|
depends_on 'grass'
|
|
|
|
|
|
|
|
def install
|
2014-02-25 05:52:43 +00:00
|
|
|
gdal = Formula['gdal']
|
|
|
|
grass = Formula['grass']
|
2011-03-06 20:20:54 +00:00
|
|
|
|
|
|
|
system "./configure", "--prefix=#{prefix}",
|
|
|
|
"--disable-debug",
|
|
|
|
"--disable-dependency-tracking",
|
2014-02-25 05:52:43 +00:00
|
|
|
"--with-gdal=#{gdal.bin}/gdal-config",
|
2011-03-06 20:20:54 +00:00
|
|
|
"--with-grass=#{grass.prefix}/grass-#{grass.version}",
|
|
|
|
"--with-autoload=#{lib}/gdalplugins"
|
|
|
|
|
|
|
|
inreplace "Makefile", 'mkdir', 'mkdir -p'
|
|
|
|
|
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
|
2012-11-25 19:42:57 +00:00
|
|
|
def caveats; <<-EOS.undent
|
|
|
|
This formula provides a plugin that allows GDAL and OGR to access geospatial
|
|
|
|
data stored using the GRASS vector and raster formats. In order to use the
|
|
|
|
plugin, you will need to add the following path to the GDAL_DRIVER_PATH
|
|
|
|
enviroment variable:
|
|
|
|
#{HOMEBREW_PREFIX}/lib/gdalplugins
|
2011-03-06 20:20:54 +00:00
|
|
|
EOS
|
|
|
|
end
|
|
|
|
end
|