aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorDominyk Tiller2015-02-14 20:19:01 +0000
committerMike McQuaid2015-02-15 19:14:35 +0000
commitb1716cb94b4dc27d4f110d856fab1931f5f1a9df (patch)
tree31578fa7d9e4415ab69b9cfb6dd91c5e7a59c74c /Library/Formula
parent22d4797781350404a3b442871558140bf5beb33a (diff)
downloadhomebrew-b1716cb94b4dc27d4f110d856fab1931f5f1a9df.tar.bz2
cconv: added test
Test added, modernised the formulae, scrapped the patch in favour of an inreplace. Closes #36819. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/cconv.rb37
1 files changed, 12 insertions, 25 deletions
diff --git a/Library/Formula/cconv.rb b/Library/Formula/cconv.rb
index 29f7aa823..19fc90601 100644
--- a/Library/Formula/cconv.rb
+++ b/Library/Formula/cconv.rb
@@ -1,32 +1,19 @@
-require 'formula'
-
class Cconv < Formula
- homepage 'http://code.google.com/p/cconv/'
- url 'https://cconv.googlecode.com/files/cconv-0.6.2.tar.gz'
- sha1 '9775f91fd5600d176552a88625aaa1f64ece09c1'
-
- # fix link with iconv: http://code.google.com/p/cconv/issues/detail?id=18
- patch :DATA
+ homepage "https://code.google.com/p/cconv/"
+ url "https://cconv.googlecode.com/files/cconv-0.6.2.tar.gz"
+ sha1 "9775f91fd5600d176552a88625aaa1f64ece09c1"
def install
+ # fix link with iconv: https://code.google.com/p/cconv/issues/detail?id=18
+ inreplace "Makefile.in", "@ICONV_LIBS@", "@ICONV_LIBS@ -liconv"
+
system "./configure", "--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}"
- system "make install"
- rm include/"unicode.h"
+ system "make", "install"
+ rm_f include/"unicode.h"
end
-end
-__END__
-diff --git a/Makefile.in b/Makefile.in
-index 7cdb9aa..93afc5b 100644
---- a/Makefile.in
-+++ b/Makefile.in
-@@ -207,7 +207,7 @@ AC_CFLAGS = -Wall @ICONV_INCLUDES@ @OS_TYPE@
- ACLOCAL_AMFLAGS = -I m4
- cconv_SOURCES = cconv.c main.c unicode.c
- cconv_CFLAGS = ${AC_CFLAGS}
--cconv_LDFLAGS = @ICONV_LIBS@
-+cconv_LDFLAGS = @ICONV_LIBS@ -liconv
- lib_LTLIBRARIES = libcconv.la
- libcconv_la_SOURCES = cconv.c unicode.c
- libcconv_la_CFLAGS = -Wall @ICONV_INCLUDES@ @OS_TYPE@
+ test do
+ system bin/"cconv", "-l"
+ end
+end