2011-12-08 23:09:43 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Points2grid < Formula
|
|
|
|
homepage 'https://github.com/CRREL/points2grid'
|
2014-02-09 02:47:54 +00:00
|
|
|
url 'https://github.com/CRREL/points2grid/archive/1.2.1.tar.gz'
|
|
|
|
sha1 'afd1b8ac0086b7ac220a3615e0ec1512161a4628'
|
2011-12-08 23:09:43 +00:00
|
|
|
|
|
|
|
depends_on 'cmake' => :build
|
|
|
|
depends_on 'boost'
|
|
|
|
|
|
|
|
def install
|
2014-02-09 03:00:03 +00:00
|
|
|
libexec.install "example.las"
|
2012-05-22 21:37:04 +00:00
|
|
|
system "cmake", ".", *std_cmake_args
|
2011-12-08 23:09:43 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
2014-02-09 03:00:03 +00:00
|
|
|
|
|
|
|
test do
|
|
|
|
mktemp do
|
|
|
|
system bin/"points2grid",
|
|
|
|
"-i", libexec/"example.las",
|
|
|
|
"-o", "example",
|
|
|
|
"--max", "--output_format", "grid"
|
|
|
|
assert_equal 5, %x(grep -c '423.820000' < example.max.grid).strip.to_i
|
|
|
|
end
|
|
|
|
end
|
2011-12-08 23:09:43 +00:00
|
|
|
end
|