ocrad 0.22: Patch for libc++ in Mavericks

Updated ocrad to 0.22 and added minor patch that fixes compilation with libc++. This has been reported to the ocrad mailing list:

http://lists.gnu.org/archive/html/bug-ocrad/2013-11/msg00000.html

Removed configure options `--disable-debug` and `--disable-dependency-tracking` as they are not recognised by the configure script.

Added simple test to check `ocrad` command line tool exists.

Closes Homebrew/homebrew#24879.

Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
master
Matt Swain 2013-12-02 14:59:18 +00:00 committed by Misty De Meo
parent 40bbd65187
commit 498f45fd56
1 changed files with 14 additions and 5 deletions

View File

@ -2,13 +2,22 @@ require 'formula'
class Ocrad < Formula
homepage 'http://www.gnu.org/software/ocrad/'
url 'http://ftpmirror.gnu.org/ocrad/ocrad-0.21.tar.gz'
mirror 'http://ftp.gnu.org/gnu/ocrad/ocrad-0.21.tar.gz'
sha1 '857a7e0b671d4216ddf2ec1ec2daf0b21d2a6a64'
url 'http://ftpmirror.gnu.org/ocrad/ocrad-0.22.tar.lz'
mirror 'http://ftp.gnu.org/gnu/ocrad/ocrad-0.22.tar.lz'
sha1 'cfb3284b9d7387af80bcd795c093624eb40f6d13'
def patches
# Patch to compile with libc++ in Mavericks. Reported to list:
# http://lists.gnu.org/archive/html/bug-ocrad/2013-11/msg00000.html
"https://gist.github.com/mcs07/7751030/raw/dd3ea738fc9e83adc7b1532a0b2e714e3542c54f/ocrad-mavericks.diff"
end
def install
system "./configure", "--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}"
system "./configure", "--prefix=#{prefix}"
system "make", "install", "CXXFLAGS=#{ENV.cxxflags}"
end
test do
system "#{bin}/ocrad", "-h"
end
end