2009-10-15 08:07:12 +00:00
|
|
|
require 'formula'
|
2009-09-01 04:57:16 +00:00
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Antiword < Formula
|
2009-11-26 06:45:17 +00:00
|
|
|
url 'http://www.winfield.demon.nl/linux/antiword-0.37.tar.gz'
|
|
|
|
homepage 'http://www.winfield.demon.nl/'
|
|
|
|
md5 'f868e2a269edcbc06bf77e89a55898d1'
|
2009-09-01 04:57:16 +00:00
|
|
|
|
2010-04-07 05:58:35 +00:00
|
|
|
skip_clean 'share/antiword'
|
2010-04-24 04:09:39 +00:00
|
|
|
|
2009-09-01 04:57:16 +00:00
|
|
|
def install
|
2010-04-24 04:09:39 +00:00
|
|
|
inreplace "Makefile" do |s|
|
|
|
|
s.change_make_var! "GLOBAL_INSTALL_DIR", bin
|
|
|
|
s.change_make_var! "GLOBAL_RESOURCES_DIR", share+'antiword'
|
|
|
|
end
|
|
|
|
|
2011-10-30 23:19:11 +00:00
|
|
|
inreplace 'antiword.h', '/usr/share/antiword', share+'antiword'
|
|
|
|
|
|
|
|
system "make CC=#{ENV.cc} LD=#{ENV.cc}"
|
2009-09-01 04:57:16 +00:00
|
|
|
bin.install 'antiword'
|
2009-09-02 00:03:34 +00:00
|
|
|
man1.install 'Docs/antiword.1'
|
2010-04-24 04:09:39 +00:00
|
|
|
(share+'antiword').mkpath
|
|
|
|
end
|
|
|
|
|
|
|
|
def caveats; <<-EOS.undent
|
|
|
|
You can install mapping files globally to:
|
|
|
|
#{HOMEBREW_PREFIX}/share/antiword
|
|
|
|
or locally to:
|
|
|
|
~/.antiword
|
|
|
|
EOS
|
2009-09-01 04:57:16 +00:00
|
|
|
end
|
|
|
|
end
|