diff options
| author | Jack Nagel | 2011-08-29 23:55:17 -0500 |
|---|---|---|
| committer | Jack Nagel | 2011-09-02 17:25:39 -0500 |
| commit | 553bf2070701aa026b17293f2bc91f17acac550a (patch) | |
| tree | 2ddad5e2f325700ec23fb717724f7aeca39c15b3 | |
| parent | c0b2528a705891af3f1be9bc33397a334c903655 (diff) | |
| download | homebrew-553bf2070701aa026b17293f2bc91f17acac550a.tar.bz2 | |
New formula: nettle 2.3
Nettle is yet another crypto library. The GnuTLS 3.x series requires it.
Includes an alias for 'libnettle'.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
| l--------- | Library/Aliases/libnettle | 1 | ||||
| -rw-r--r-- | Library/Formula/nettle.rb | 41 |
2 files changed, 42 insertions, 0 deletions
diff --git a/Library/Aliases/libnettle b/Library/Aliases/libnettle new file mode 120000 index 000000000..9bd9afac6 --- /dev/null +++ b/Library/Aliases/libnettle @@ -0,0 +1 @@ +../Formula/nettle.rb
\ No newline at end of file diff --git a/Library/Formula/nettle.rb b/Library/Formula/nettle.rb new file mode 100644 index 000000000..8aeb227b0 --- /dev/null +++ b/Library/Formula/nettle.rb @@ -0,0 +1,41 @@ +require 'formula' + +class Nettle < Formula + url 'http://www.lysator.liu.se/~nisse/archive/nettle-2.3.tar.gz' + homepage 'http://www.lysator.liu.se/~nisse/nettle/' + md5 'ba66035af27731307229fd39efa51c0d' + + depends_on 'gmp' + + # Fix undefined symbols when linking + def patches; DATA; end + + def install + ENV.universal_binary + ENV.append 'LDFLAGS', '-lgmp' # Fix undefined symbols when linking + ENV['DYLD_LIBRARY_PATH'] = lib # otherwise 'make check' fails + + system "./configure", "--disable-dependency-tracking", + "--prefix=#{prefix}", + "--enable-shared", + "--disable-assembler" + system "make" + system "make install" + system "make check" + end +end + +__END__ +diff --git a/Makefile.in b/Makefile.in +index fd486f5..227ccd9 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -163,7 +163,7 @@ $(LIBNETTLE_FORLINK): $(nettle_PURE_OBJS) + && ln -sf ../$(LIBNETTLE_FORLINK) $(LIBNETTLE_SONAME)) + + $(LIBHOGWEED_FORLINK): $(hogweed_PURE_OBJS) $(LIBNETTLE_FORLINK) +- $(LIBHOGWEED_LINK) $(hogweed_PURE_OBJS) -o $@ $(LIBHOGWEED_LIBS) ++ $(LIBHOGWEED_LINK) $(hogweed_PURE_OBJS) $(nettle_PURE_OBJS) -o $@ $(LIBHOGWEED_LIBS) + -mkdir .lib 2>/dev/null + [ -z "$(LIBHOGWEED_SONAME)" ] || (cd .lib \ + && ln -sf ../$(LIBHOGWEED_FORLINK) $(LIBHOGWEED_SONAME)) |
