summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Ospald <hasufell@gentoo.org>2014-11-17 22:32:41 +0000
committerJulian Ospald <hasufell@gentoo.org>2014-11-17 22:32:41 +0000
commita469d32018acd74b04feb92a7221b81b8992ed92 (patch)
treea0160c0f1a2d40761b330605667a1a5c3212db11 /dev-libs/libntru
parentStable for HPPA (bug #527672). (diff)
downloadhistorical-a469d32018acd74b04feb92a7221b81b8992ed92.tar.gz
historical-a469d32018acd74b04feb92a7221b81b8992ed92.tar.bz2
historical-a469d32018acd74b04feb92a7221b81b8992ed92.zip
version bump
Package-Manager: portage-2.2.14/cvs/Linux x86_64 Manifest-Sign-Key: 0xBDEED020
Diffstat (limited to 'dev-libs/libntru')
-rw-r--r--dev-libs/libntru/ChangeLog10
-rw-r--r--dev-libs/libntru/Manifest37
-rw-r--r--dev-libs/libntru/files/libntru-0.3-Allow-building-and-installing-static-lib.patch78
-rw-r--r--dev-libs/libntru/files/libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch33
-rw-r--r--dev-libs/libntru/files/libntru-0.3-Update-VERSION-in-Makefiles.patch53
-rw-r--r--dev-libs/libntru/libntru-0.3.ebuild57
6 files changed, 251 insertions, 17 deletions
diff --git a/dev-libs/libntru/ChangeLog b/dev-libs/libntru/ChangeLog
index e7ffd4bdf4af..5d2f85177e09 100644
--- a/dev-libs/libntru/ChangeLog
+++ b/dev-libs/libntru/ChangeLog
@@ -1,6 +1,14 @@
# ChangeLog for dev-libs/libntru
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/libntru/ChangeLog,v 1.1 2014/04/16 22:48:09 hasufell Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libntru/ChangeLog,v 1.2 2014/11/17 22:32:35 hasufell Exp $
+
+*libntru-0.3 (17 Nov 2014)
+
+ 17 Nov 2014; Julian Ospald <hasufell@gentoo.org> +libntru-0.3.ebuild,
+ +files/libntru-0.3-Allow-building-and-installing-static-lib.patch,
+ +files/libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch,
+ +files/libntru-0.3-Update-VERSION-in-Makefiles.patch:
+ version bump
*libntru-0.2 (16 Apr 2014)
diff --git a/dev-libs/libntru/Manifest b/dev-libs/libntru/Manifest
index 9499fdfbee2f..9bda66d62926 100644
--- a/dev-libs/libntru/Manifest
+++ b/dev-libs/libntru/Manifest
@@ -6,26 +6,31 @@ AUX 02-libntru-0.2-add-warnings.patch 1960 SHA256 29cf1c7f4af111deeeaa3d9388f43d
AUX 03-libntru-0.2-install-rules.patch 9199 SHA256 cc1b2ef6c67b630f26dd8ae94218ace3f419be32742e4d625730fa4bdadbe901 SHA512 8c427fb672fcbc57c16998f01d9d738203b10149d29b8fd495981a92a6e739193fde942756ffcc24ad59fc8c0bf91aa24a9e0db5886541a2161139ea0989f1e3 WHIRLPOOL 57d9dd5e2c257c0749faf594dd59aa5ec2a4725678d187590c808b575dc83805e7ccb55d7607a19bf8d7eb0db40b4f364eb862a36b01e2998b7b1dba5a7d4dca
AUX 04-libntru-0.2-respect-flags.patch 3405 SHA256 4d205170a1c10fbeb13a9d2c799a88ce2cde3e656bbf523dd160739edb700124 SHA512 c8d651474d8087deac1871325471842ffa57a96421f919abc2c92e38c54f0e05b5dc26c29751ce111fbf382d7e6acc129dfe354bd94556cda836080868e8e6df WHIRLPOOL 34a7e7e8e2befe8a585c2166c8265c7434a856d00aec026126ae833916ab23310db02074cac17f80a905305bf3f676c771ccf03c1571f39761ff0be7e87e785f
AUX 05-libntru-0.2-fix-memory-leak.patch 770 SHA256 84c8bf04283f75f3c81f14ae74331a9f2c51c6c80b069bcd711db2f238ee0bcd SHA512 c2e6bf2b14bfb9bed90843136a00c763ba5f8a1d3e0b6161cdc06181c709ad52f2d593a2cf1935dfc9a1af7a18832a88908a3b8eed0748db75274198878d0f5b WHIRLPOOL 5127981a47749c1acf174e56f333e967c5a389a2cace60c3e19dda9e524aff50b625f8c377242ec8548619acafc9db62885b6945034a7d7a6e456ebf2307ee09
+AUX libntru-0.3-Allow-building-and-installing-static-lib.patch 2465 SHA256 b622ea735c4a6fdf37051bb498e90b859f98af6277621f4ec80c490162e48019 SHA512 a74054fc16044035eb3c9bfe6f104073c83f6ebcc832c229ec8a20cea67eb88fdeb011173be85ed393dd44d5d8c0ee718e5d85eaef208ef70f956661df10fe01 WHIRLPOOL a3d09dc2efb616832a4c79c13d81d8dc0db3d194b1064a895f88b4f18febab565ed0662e2f42fcdab7b20e0f6efc7f43411ed8dd2ad0370a7d8fe6a0201fbb5a
+AUX libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch 988 SHA256 6325acee408cb5a2f2c800a5d985d8f65fc7b3257b6741b7ec826afdea6fc566 SHA512 05ed478c618342c07188380895d79875a5b23ac011aa057cebb351da0d401beafae82965dbb855b17d8e042be15e1f34e89952183818b6643d0f31136aa9bcbf WHIRLPOOL f3c34ddca37b13b3431940aaeeb445a9c3760f97f3a91a42c83195ad4c2229cd84893fd887759b6cd77eca6d4f868fd08e498c38c3eb8cf5d20757d9d7a57f3b
+AUX libntru-0.3-Update-VERSION-in-Makefiles.patch 1763 SHA256 5b364a6eb4d2a1155482f06b65f29cf6f78e41a05428c1697bd07ff6bb8eaeca SHA512 a48dd36d1ebbeee1222f528bf3946eba3425850d2b50e11196057c8f538bf0999bd83b37518ca598862d87b3bf7343fbabd1dde7bf753c853939abf9eee0ea99 WHIRLPOOL 851ec9e644350ebbd88c96e5a2a9da672f95f1d75ed0ae9aedfa7469406201134d723780741b5f0fff7c558cbe468a262d34865fdad46759c561266ee1e731cb
DIST libntru-0.2.tar.gz 49832 SHA256 bc1d10dcd1755f836d4696b734ecc4bc8b047b7ea40d857657c03ecb31ac141f SHA512 4de4cc550fb74d53a26f1b6f94d27d6131756ab7f1b62ce5f1845e6e626581a357004efbd92881d1e180d75f4a92ec97e3c30926dcdf6ea23d87f1da81809f3a WHIRLPOOL 5e96d55f56f608e5ca24506bc8a122d2dff62c61fc0dab847913456d84d36fe13d615c8910b3915c0aa3881a236aaae45725842f9d062183906162df352fd396
+DIST libntru-0.3.tar.gz 53364 SHA256 9ce6b6a20ca304c09d2ff853e3b5762880a8cb85728113b26eb8ca2e915e2a0a SHA512 b99fecf21104f73246a9494dce6caa6742b7a2e5219e9b2a46d639d3181588bb1580c0b03209f150e9294f721d2e1179157be0eab52f25b2664c1451aaae8712 WHIRLPOOL 1545da85003e0466354767388252a67d5ac9cb457e94baf9ed1862b2b2b28bfa6057202509a017765442ca502c888ca50c6724b8c67569b6e6f4fcb8d5b2fd8a
EBUILD libntru-0.2.ebuild 993 SHA256 c5a7233a0bab02e9aedd4de9b98fcbc9895ce31fe7cea82ddfa40ecb94c125db SHA512 a9502256fdd2d2661a4ebf56e10eb0443a6d1b5fad01135e322ac770d44ea5c83d36ffd92b145405af9a87d581e2a41065e0c797b58d732d8cb0f4ba313b2511 WHIRLPOOL d6bf4f955b910775c1657882eead382a1736356143474f446916f0b8ccaa36133cd06fb4fdeb9f2e3782e7154a40d3b96a834029203a7cc8f2e926f30e251e42
-MISC ChangeLog 572 SHA256 e4ce15f0cf4f21b5dbf1090858a15bc49c2d4684755a4d84310b73232f231b97 SHA512 1c10b839528c09ed4eb98e01f2b438e2ec9771f280ead74af39a972a168cbf60dd3b211c9b6376cbb1c19fca9160ba29838d3fac4ee238b35a032bd9f6244ec8 WHIRLPOOL 8012396f475b0d19a4914ef28acbcab61cd6f44c5589ae08a01c3c013eea7800438ad6adbeffbff211e0550984596ee630880307b6c5bdce4f4bc72e201b1aa4
+EBUILD libntru-0.3.ebuild 1441 SHA256 273b7647bbc4a3593f0d3ef3b38ca183b607472da19244494dc9cbd459e98af5 SHA512 91c249ae54654f0092714f16dd565e778048c7f651af6b3049c1c93b37c48e6accbcb83417b32af7c8fbaa6c49b04939f7da6503d0d4d92b90a13875bed6ebba WHIRLPOOL 6a04b0cb208831574d82a3dd9b04f460fd1845595d93d29ba2741d5cccb6e162dcaa1267411b77f4916d115b07abbd85c76f68c3f93c4ebf8a47c0c1c4fb3eea
+MISC ChangeLog 893 SHA256 e1b3bdc5bbc561cd8a51ce7e9866153f36fcc8800b7b3520a190b3b812683cf3 SHA512 15f5955500e97b9e6e3bedca3debe41957215c05086772f5ce2b26ddad52e8c43e72eb57c8247a794322daa48e585665bcf88b98946cf73878cfb02250ce66a1 WHIRLPOOL 5133db9dbfec9566628b5e8e795d63503f7c80905417eba5c579e99b9629e5a15e86e1d5db6f952417e50547166b3b984a7ae8ae577a50ad0fe4e4ebcf109c0b
MISC metadata.xml 313 SHA256 9b7560a1714adab73c1b7fdfc5b489f5e521ece27b513b19844e438eafc072fc SHA512 bcaf8d1897c71af93f072a7843ae160105fb8e6f5039576ffaf2a46d186546ef36c99caca4f97522c9eeeb5f531b492e66b471b496cea68317ed7936de834034 WHIRLPOOL ba4273788d466482c0c7bce783e519ec415563a913fae3bb05e19deeef39f6863b53fa2b4c36659712aa3e4a9c25561b82455fe0d8e15ba3e3ae053fd48ad42a
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.22 (GNU/Linux)
+Version: GnuPG v2.0
-iQJ8BAEBCABmBQJTTwisXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
+iQJ8BAEBCABmBQJUaneGXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQzMDlCNDQ4NjEyNDI4NjA5REVEMDI3MzIy
-MjBDRDFDNUJERUVEMDIwAAoJECIM0cW97tAgC2UP/iqxC2tfyhrxrqUbcAK8ejwf
-hbksr6F9N0nyr2Pg9FFAvQQBHjdwV/1F9Y9ZxhUDXv3IcQR6bKVPXQ87JLpsEr3R
-OsGuCjXSnPq7g3kCX6aj5WVymeZ6eGDFg6bqYHDobkrVmTZJkhSDH8+gA4WDsJrJ
-8RDeMY4I/pp80dsgjZ8S4U5SNXgw9qdYo3gpWizBt1dm3RWdx2dxRAtQU0vF4T15
-qgBhRi4OYnIejuKazTVpBFBjGhKiUfgJz9HwmSBltcP0hMsHJO04T2mEAXow5Hja
-uRSALpplEQPgD5MtXqSSlmtDuTJZRvTpuqC+xXY6+FdzEsAb2CZdFk70IOEsX4NL
-bCWQYQ2VmRLRDErAJlSitd8Tu29tZ0pFCjFPYldb8ML1ZWOxd5q8fBFMrWgX5Iit
-bDy3GBGgzYqi+Zvpcd+m5ZqFI6E27QjIHFnCOwqMScSmKZEIAHHx5v41zwb2NDpY
-wdNabRsnxVfkaGsneyDIBtA7KacKgRlIQpaMtMAX/uPBrS3ZTeLaSqyIkWtGEnX2
-qdnmtMckpdxMhOCsphezSNCH9+kugKOehf/SDb9KOtxCRPDRI1mmoMnkifj2ebb4
-YLqx4ZgSBoSTBsilnSkhKxUyWIyDs/M+U6FJDGVQrFqJ1IeKsw4gAjsGqmpHHadb
-alnZDn2Yi4pJ9H7Cz5wY
-=ztPX
+MjBDRDFDNUJERUVEMDIwAAoJECIM0cW97tAgYhYQAJbP6e6W7pKgXcYh1a8DgSOk
+PNng3MPXBStKsrfyaCIYdLBvovZAdSsSRniRsiU28qVNB/FOROCvGH97AFtnHD2+
++VPQvIBW91pa4hzKkIgMNJ8YyHMRd/JnPJcd7ZP/K+rZFjgy7WLLTU1/0OmM8BwK
+Ow+CoBVCNsM/spHSBJ45a+zUpHXzxAfspuqYwpaqOeJtraDec9BRU4H5gFD+XGiC
+y/llaSz95NCD1SsR+DsA3OfNTVvGawwI+OS++i0Uxzl61h4MnccT9TcerizUGXtJ
+iZ1Ie5pjYkSWCeDan5GnbWAI74H3rbPczlAKl4tOysNyjPC2bQgOomjJg/XDmLz2
++btmNDB1NUcDtskwXPtgfXcqGiop7ly/D741tp1e+Rpq1Vhn0PnSFvxEYGE0Okof
+fS4mkQj3mdHlv8gtSyoQ2QEB/a9SrnfElOYFAxMjUDZES3k8HN84tX14To8ndrhf
+y/eNVoec3EqEiUBXlGpCOeysaAv1U/2sqJ3UX7X+Ls4kF6nLhsoIItmd7gf331Nx
+VefmX6n0gKeij86ibHhdhyHLBUEwSvDHrELLi2sBaYYcoqzeNPVtzkQ4dV/DNzpQ
+5XvQHqlPcUxW4fvA/9cpzgbr9XjF3x/6aRX5sc6JMa7FLoizBeJFnA43rd9z6jh2
+u+S0cDKHPgbykv6nl9nV
+=oXCU
-----END PGP SIGNATURE-----
diff --git a/dev-libs/libntru/files/libntru-0.3-Allow-building-and-installing-static-lib.patch b/dev-libs/libntru/files/libntru-0.3-Allow-building-and-installing-static-lib.patch
new file mode 100644
index 000000000000..36c4f693dcc6
--- /dev/null
+++ b/dev-libs/libntru/files/libntru-0.3-Allow-building-and-installing-static-lib.patch
@@ -0,0 +1,78 @@
+From 5cb48a5a1bf43c5d4811295aa3fb25744c4c254d Mon Sep 17 00:00:00 2001
+From: Julian Ospald <hasufell@hasufell.de>
+Date: Mon, 17 Nov 2014 23:25:31 +0100
+Subject: [PATCH 3/6] Allow building and installing static lib
+
+Refactored the install rules a bit, so that installing the static
+lib optionally becomes a bit more convenient.
+---
+ Makefile.linux | 36 ++++++++++++++++++++++++++++++------
+ 1 file changed, 30 insertions(+), 6 deletions(-)
+
+diff --git a/Makefile.linux b/Makefile.linux
+index dbc4957..218162c 100644
+--- a/Makefile.linux
++++ b/Makefile.linux
+@@ -1,4 +1,5 @@
+ CC?=gcc
++AR?=ar
+ CFLAGS?=-g -O2
+ CFLAGS+=-Wall -Wextra -Wno-unused-parameter
+ LIBS+=-lrt
+@@ -24,24 +25,47 @@ all: lib
+
+ lib: libntru.so
+
++static-lib: libntru.a
++
+ libntru.so: $(LIB_OBJS_PATHS)
+ $(CC) $(CFLAGS) $(CPPFLAGS) -shared -Wl,-soname,libntru.so -o libntru.so $(LIB_OBJS_PATHS) $(LDFLAGS) $(LIBS)
+
+-install: lib
+- test -d "$(DESTDIR)$(INST_PFX)" || mkdir -p "$(DESTDIR)$(INST_PFX)"
+- test -d "$(DESTDIR)$(INST_LIBDIR)" || mkdir "$(DESTDIR)$(INST_LIBDIR)"
+- test -d "$(DESTDIR)$(INST_INCLUDE)" || mkdir -p "$(DESTDIR)$(INST_INCLUDE)"
+- test -d "$(DESTDIR)$(INST_DOCDIR)" || mkdir -p "$(DESTDIR)$(INST_DOCDIR)"
++libntru.a: $(LIB_OBJS_PATHS)
++ $(AR) cru libntru.a $(LIB_OBJS_PATHS)
++
++install: install-lib install-doc install-headers
++
++install-lib: lib
++ test -d "$(DESTDIR)$(INST_LIBDIR)" || mkdir -p "$(DESTDIR)$(INST_LIBDIR)"
+ install -m 0755 libntru.so "$(DESTDIR)$(INST_LIBDIR)/libntru.so"
++
++install-static-lib: static-lib
++ test -d "$(DESTDIR)$(INST_LIBDIR)" || mkdir -p "$(DESTDIR)$(INST_LIBDIR)"
++ install -m 0755 libntru.a "$(DESTDIR)$(INST_LIBDIR)/libntru.a"
++
++install-doc:
++ test -d "$(DESTDIR)$(INST_DOCDIR)" || mkdir -p "$(DESTDIR)$(INST_DOCDIR)"
+ install -m 0644 README.md "$(DESTDIR)$(INST_DOCDIR)/README.md"
++
++install-headers:
++ test -d "$(DESTDIR)$(INST_INCLUDE)" || mkdir -p "$(DESTDIR)$(INST_INCLUDE)"
+ for header in $(INST_HEADERS) ; do \
+ install -m 0644 "$(SRCDIR)/$$header" "$(DESTDIR)$(INST_INCLUDE)/" ; \
+ done
+
+-uninstall:
++uninstall: uninstall-lib uninstall-doc uninstall-headers
++
++uninstall-lib:
+ rm -f "$(DESTDIR)$(INST_LIBDIR)/libntru.so"
++
++uninstall-static-lib:
++ rm -f "$(DESTDIR)$(INST_LIBDIR)/libntru.a"
++
++uninstall-doc:
+ rm -f "$(DESTDIR)$(INST_DOCDIR)/README.md"
+ rmdir "$(DESTDIR)$(INST_DOCDIR)/"
++
++uninstall-headers:
+ for header in $(INST_HEADERS) ; do \
+ rm "$(DESTDIR)$(INST_INCLUDE)/$$header" ; \
+ done
+--
+2.1.3
+
diff --git a/dev-libs/libntru/files/libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch b/dev-libs/libntru/files/libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch
new file mode 100644
index 000000000000..101d0472faac
--- /dev/null
+++ b/dev-libs/libntru/files/libntru-0.3-Make-the-lib-target-depend-on-the-libntru.so-target.patch
@@ -0,0 +1,33 @@
+From 38e454b12c707a0d6870fb5541fad64ece17f78d Mon Sep 17 00:00:00 2001
+From: Julian Ospald <hasufell@hasufell.de>
+Date: Mon, 17 Nov 2014 22:27:39 +0100
+Subject: [PATCH 1/4] Make the "lib" target depend on the "libntru.so" target
+
+Depending on the old "lib" target caused a rebuild of libntru.so on any
+such target (e.g. installation), because "lib" is in .PHONY
+and not an expected file name.
+
+Fixing this helps with distro policies which require to not do
+compilation processes during installation phase.
+---
+ Makefile.linux | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/Makefile.linux b/Makefile.linux
+index b699998..dbc4957 100644
+--- a/Makefile.linux
++++ b/Makefile.linux
+@@ -22,7 +22,9 @@ MAKEFILENAME=$(lastword $(MAKEFILE_LIST))
+
+ all: lib
+
+-lib: $(LIB_OBJS_PATHS)
++lib: libntru.so
++
++libntru.so: $(LIB_OBJS_PATHS)
+ $(CC) $(CFLAGS) $(CPPFLAGS) -shared -Wl,-soname,libntru.so -o libntru.so $(LIB_OBJS_PATHS) $(LDFLAGS) $(LIBS)
+
+ install: lib
+--
+2.1.3
+
diff --git a/dev-libs/libntru/files/libntru-0.3-Update-VERSION-in-Makefiles.patch b/dev-libs/libntru/files/libntru-0.3-Update-VERSION-in-Makefiles.patch
new file mode 100644
index 000000000000..0c46be1c3552
--- /dev/null
+++ b/dev-libs/libntru/files/libntru-0.3-Update-VERSION-in-Makefiles.patch
@@ -0,0 +1,53 @@
+From e434656449d0797a2f6e14e33b6a0114371d0e16 Mon Sep 17 00:00:00 2001
+From: Julian Ospald <hasufell@hasufell.de>
+Date: Mon, 17 Nov 2014 22:58:29 +0100
+Subject: [PATCH 3/4] Update VERSION in Makefiles
+
+---
+ Makefile.linux | 2 +-
+ Makefile.osx | 2 +-
+ Makefile.win | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile.linux b/Makefile.linux
+index fabf8d5..3248ba8 100644
+--- a/Makefile.linux
++++ b/Makefile.linux
+@@ -7,7 +7,7 @@ SRCDIR=src
+ TESTDIR=tests
+ LIB_OBJS=bitstring.o encparams.o hash.o idxgen.o key.o mgf.o ntru.o poly.o rand.o sha1.o sha2.o
+ TEST_OBJS=test_bitstring.o test_hash.o test_idxgen.o test_key.o test_ntru.o test.o test_poly.o test_util.o
+-VERSION=0.2
++VERSION=0.3
+ INST_PFX=/usr
+ INST_LIBDIR=$(INST_PFX)/lib
+ INST_INCLUDE=$(INST_PFX)/include/libntru
+diff --git a/Makefile.osx b/Makefile.osx
+index ccbdf3e..a0f67d3 100644
+--- a/Makefile.osx
++++ b/Makefile.osx
+@@ -4,7 +4,7 @@ SRCDIR=src
+ TESTDIR=tests
+ LIB_OBJS=bitstring.o encparams.o hash.o idxgen.o key.o mgf.o ntru.o poly.o rand.o sha1.o sha2.o
+ TEST_OBJS=test_bitstring.o test_hash.o test_idxgen.o test_key.o test_ntru.o test.o test_poly.o test_util.o
+-VERSION=0.2
++VERSION=0.3
+ INST_PFX=/usr
+ INST_LIBDIR=$(INST_PFX)/lib
+ INST_INCLUDE=$(INST_PFX)/include/libntru
+diff --git a/Makefile.win b/Makefile.win
+index 7a93144..ffa7225 100644
+--- a/Makefile.win
++++ b/Makefile.win
+@@ -6,7 +6,7 @@ SRCDIR=src
+ TESTDIR=tests
+ LIB_OBJS=bitstring.o encparams.o hash.o idxgen.o key.o mgf.o ntru.o poly.o rand.o sha1.o sha2.o
+ TEST_OBJS=test_bitstring.o test_hash.o test_idxgen.o test_key.o test_ntru.o test.o test_poly.o test_util.o
+-VERSION=0.2
++VERSION=0.3
+ INST_PFX=%PROGRAMFILES%
+ INST_LIBDIR=$(INST_PFX)\libntru
+ INST_INCLUDE=$(INST_PFX)\libntru\include
+--
+2.1.3
+
diff --git a/dev-libs/libntru/libntru-0.3.ebuild b/dev-libs/libntru/libntru-0.3.ebuild
new file mode 100644
index 000000000000..6f68d0e8fcf2
--- /dev/null
+++ b/dev-libs/libntru/libntru-0.3.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libntru/libntru-0.3.ebuild,v 1.1 2014/11/17 22:32:35 hasufell Exp $
+
+EAPI=5
+
+inherit eutils toolchain-funcs multilib multilib-minimal
+
+DESCRIPTION="C Implementation of NTRUEncrypt"
+HOMEPAGE="https://github.com/tbuktu/libntru"
+SRC_URI="https://github.com/tbuktu/libntru/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="examples static-libs"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-Make-the-lib-target-depend-on-the-libntru.so-target.patch \
+ "${FILESDIR}"/${P}-Allow-building-and-installing-static-lib.patch \
+ "${FILESDIR}"/${P}-Update-VERSION-in-Makefiles.patch
+
+ multilib_copy_sources
+
+ _copy_test_dir() {
+ cp -pr "${BUILD_DIR}" "${BUILD_DIR}-test" || die
+ }
+ multilib_foreach_abi _copy_test_dir
+}
+
+multilib_src_compile() {
+ CFLAGS="${CFLAGS}" emake CC="$(tc-getCC)" $(usex static-libs "libntru.a" "")
+}
+
+src_test() {
+ _test() {
+ CFLAGS="${CFLAGS}" emake CC="$(tc-getCC)" test -j1 -C "${BUILD_DIR}-test"
+ }
+
+ multilib_foreach_abi _test
+}
+
+multilib_src_install() {
+ emake \
+ DESTDIR="${ED}" \
+ INST_LIBDIR="/usr/$(get_libdir)" \
+ INST_DOCDIR="/usr/share/doc/${PF}" \
+ install $(usex static-libs install-static-lib "")
+}
+
+multilib_src_install_all() {
+ einstalldocs
+ if use examples ; then
+ docinto examples
+ dodoc src/hybrid.c
+ fi
+}