New formula: cereal 1.0.0
Add cereal 1.0.0, a C++11 header-only library for serialization. This formula includes a "with-tests" option, which can be used to build and run cereal's internal unit test suite before installation. Note that these tests are broken for tag 1.0.0, but are not (currently) broken for the "develop" branch. Closes Homebrew/homebrew#29438. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
parent
fcb564ef5f
commit
254c3333c6
1 changed files with 22 additions and 0 deletions
22
Formula/cereal.rb
Normal file
22
Formula/cereal.rb
Normal file
|
@ -0,0 +1,22 @@
|
|||
require "formula"
|
||||
|
||||
class Cereal < Formula
|
||||
homepage "http://uscilab.github.io/cereal/"
|
||||
url "https://github.com/USCiLab/cereal/archive/v1.0.0.tar.gz"
|
||||
sha1 "a8e409deb2bdba6bdbc04d3eb2d5294d4cc4b9e2"
|
||||
|
||||
head "https://github.com/USCiLab/cereal.git", :branch => "develop"
|
||||
|
||||
option "with-tests", "Build and run the test suite"
|
||||
|
||||
depends_on "cmake" => :build if build.with? "tests"
|
||||
|
||||
def install
|
||||
if build.with? "tests"
|
||||
system "cmake", ".", *std_cmake_args
|
||||
system "make"
|
||||
system "make", "test"
|
||||
end
|
||||
include.install "include/cereal"
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue