2014-03-30 19:41:11 +00:00
|
|
|
require "language/haskell"
|
|
|
|
|
|
|
|
class Pandoc < Formula
|
|
|
|
include Language::Haskell::Cabal
|
|
|
|
|
|
|
|
homepage "http://johnmacfarlane.net/pandoc/"
|
2014-12-20 22:47:11 +00:00
|
|
|
url "https://hackage.haskell.org/package/pandoc-1.13.2/pandoc-1.13.2.tar.gz"
|
|
|
|
sha1 "20f6e4c8d17748979efd011ef870dbfd1fb6dbb3"
|
2014-03-30 19:41:11 +00:00
|
|
|
|
2014-05-06 22:52:15 +00:00
|
|
|
bottle do
|
2014-12-20 23:29:44 +00:00
|
|
|
sha1 "b4d98399c366b63faed06a6184bb2a9d3c7bacf2" => :yosemite
|
|
|
|
sha1 "f8c3ba25bc44c7e8da1bf14d1fdeef04e2793926" => :mavericks
|
|
|
|
sha1 "592f4c65d534317172ce377a0d4524340e7177a8" => :mountain_lion
|
2014-05-06 22:52:15 +00:00
|
|
|
end
|
|
|
|
|
2014-03-30 19:41:11 +00:00
|
|
|
depends_on "ghc" => :build
|
|
|
|
depends_on "cabal-install" => :build
|
|
|
|
depends_on "gmp"
|
|
|
|
|
2014-09-23 17:52:37 +00:00
|
|
|
fails_with(:clang) { build 425 } # clang segfaults on Lion
|
2014-09-23 17:04:10 +00:00
|
|
|
|
2014-03-30 19:41:11 +00:00
|
|
|
def install
|
|
|
|
cabal_sandbox do
|
2014-08-17 06:56:58 +00:00
|
|
|
cabal_install "--only-dependencies"
|
2014-03-30 19:41:11 +00:00
|
|
|
cabal_install "--prefix=#{prefix}"
|
|
|
|
end
|
|
|
|
cabal_clean_lib
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
system "pandoc", "-o", "output.html", prefix/"README"
|
|
|
|
assert (Pathname.pwd/"output.html").read.include? '<h1 id="synopsis">Synopsis</h1>'
|
|
|
|
end
|
|
|
|
end
|