homebrew-core/Formula/osm2pgrouting.rb
2016-11-13 21:46:45 -08:00

37 lines
1.2 KiB
Ruby

class Osm2pgrouting < Formula
desc "Import OSM data into pgRouting database"
homepage "http://pgrouting.org/docs/tools/osm2pgrouting.html"
url "https://github.com/pgRouting/osm2pgrouting/archive/v2.2.0.tar.gz"
sha256 "bdd3095123cf21ee2f56e5cf04b2ea7b781dea629bff909fa45ebc5dbe50f8a6"
head "https://github.com/pgRouting/osm2pgrouting.git"
bottle do
cellar :any
sha256 "dc2257b6ba845714b8543519140ce3e60a9f72623e72bbab3c1099b65d4e3b12" => :sierra
sha256 "9f1df3976e859f8688b4d87963b896e7683349a6bb2aee5894c58eff95f37696" => :el_capitan
sha256 "b780ea51ec19cada89d188b622ec5ad9b6985058cd464eed45cc7d4c803bda9d" => :yosemite
end
depends_on "cmake" => :build
depends_on "boost"
depends_on "expat"
depends_on "pgrouting"
depends_on "postgis"
depends_on :postgresql
def install
inreplace "CMakeLists.txt" do |s|
s.gsub! "RUNTIME DESTINATION \"/usr/bin\"",
"RUNTIME DESTINATION \"#{bin}\""
s.gsub! "set (SHARE_DIR \"/usr/share/osm2pgrouting\")",
"set (SHARE_DIR \"#{pkgshare}\")"
end
system "cmake", ".", *std_cmake_args
system "make", "install"
end
test do
system bin/"osm2pgrouting", "--help"
end
end