libpbc: Import as wip/libpbc.

Add buildlink3.mk for libpbc.
This commit is contained in:
ng0 2019-05-07 21:22:33 +00:00
parent 6cfcbc2808
commit 815f02773d
8 changed files with 153 additions and 0 deletions

View File

@ -1944,6 +1944,7 @@ SUBDIR+= libpano12
SUBDIR+= libpar2
SUBDIR+= libparsifal
SUBDIR+= libpatterns
SUBDIR+= libpbc
SUBDIR+= libpsurface
SUBDIR+= libpthread-stubs
SUBDIR+= libpusb

20
libpbc/DESCR Normal file
View File

@ -0,0 +1,20 @@
The PBC (Pairing-Based Cryptography) library is a free C library built
on the GMP library that performs the mathematical operations
underlying pairing-based cryptosystems.
It provides routines such as elliptic curve generation, elliptic curve
arithmetic and pairing computation.
The API is abstract enough that the PBC library can be used even if
the programmer possesses only an elementary understanding of pairings.
There is no need to learn about elliptic curves or much of number
theory. (The minimum requirement is some knowledge of cyclic groups
and properties of the pairing.)
Boneh-Lynn-Shacham short signatures
Hess identity-based signatures
Joux tripartite Diffie-Hellman
Paterson identity-based signatures
Yuan-Li identity-based authenticated key agreement
Zhang-Kim identity-based blind/ring signatures
Zhang-Safavi-Naini-Susilo signatures

20
libpbc/Makefile Normal file
View File

@ -0,0 +1,20 @@
# $NetBSD: Makefile,v 1.4 2014/09/25 19:12:03 jperkin Exp $
DISTNAME= pbc-0.5.14
CATEGORIES= security
MASTER_SITES= http://crypto.stanford.edu/pbc/files/
MAINTAINER= agc@NetBSD.org
HOMEPAGE= http://crypto.stanford.edu/pbc/
COMMENT= Pair-based cryptographic library based on Gap Diffie Helman groups
LICENSE= gnu-lgpl-v2
AUTO_MKDIRS= yes
GNU_CONFIGURE= yes
USE_LIBTOOL= yes
USE_TOOLS+= bison flex
.include "../../devel/gmp/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"

27
libpbc/PLIST Normal file
View File

@ -0,0 +1,27 @@
@comment $NetBSD: PLIST,v 1.2 2014/02/26 04:00:57 agc Exp $
include/pbc/pbc.h
include/pbc/pbc_a1_param.h
include/pbc/pbc_a_param.h
include/pbc/pbc_curve.h
include/pbc/pbc_d_param.h
include/pbc/pbc_e_param.h
include/pbc/pbc_f_param.h
include/pbc/pbc_field.h
include/pbc/pbc_fieldquadratic.h
include/pbc/pbc_fp.h
include/pbc/pbc_g_param.h
include/pbc/pbc_hilbert.h
include/pbc/pbc_i_param.h
include/pbc/pbc_memory.h
include/pbc/pbc_mnt.h
include/pbc/pbc_multiz.h
include/pbc/pbc_pairing.h
include/pbc/pbc_param.h
include/pbc/pbc_poly.h
include/pbc/pbc_random.h
include/pbc/pbc_singular.h
include/pbc/pbc_ternary_extension_field.h
include/pbc/pbc_test.h
include/pbc/pbc_utils.h
include/pbc/pbc_z.h
lib/libpbc.la

17
libpbc/buildlink3.mk Normal file
View File

@ -0,0 +1,17 @@
# $NetBSD$
BUILDLINK_TREE+= pbc
.if !defined(PBC_BUILDLINK3_MK)
PBC_BUILDLINK3_MK:=
BUILDLINK_API_DEPENDS.pbc+= pbc>=0.5.14
BUILDLINK_PKGSRCDIR.pbc?= ../../wip/libpbc
pkgbase:= pbc
.include "../../mk/pkg-build-options.mk"
.include "../../devel/gmp/buildlink3.mk"
.endif # PBC_BUILDLINK3_MK
BUILDLINK_TREE+= -pbc

8
libpbc/distinfo Normal file
View File

@ -0,0 +1,8 @@
$NetBSD: distinfo,v 1.3 2015/11/04 01:17:49 agc Exp $
SHA1 (pbc-0.5.14.tar.gz) = 8947f1a5a32d5c2d1f5113ccbb1e0d25ca5ce1c9
RMD160 (pbc-0.5.14.tar.gz) = 7cf2fb398960d34d7207798296ceb8324af34a17
SHA512 (pbc-0.5.14.tar.gz) = d75d4ceb3f67ee62c7ca41e2a91ee914fbffaeb70256675aed6734d586950ea8e64e2f16dc069d71481eddb703624df8d46497005fb58e75cf098dd7e7961333
Size (pbc-0.5.14.tar.gz) = 654515 bytes
SHA1 (patch-configure) = 002434b4553fb85e8b9077c5fc9d4ccff7a8d1b7
SHA1 (patch-configure.ac) = a87bcbcb292df27729697fdab3b0fd2215e087a4

View File

@ -0,0 +1,30 @@
$NetBSD: patch-configure,v 1.1 2014/02/26 04:00:57 agc Exp $
The test for string equality in test(1) is "="
--- configure.orig 2013-06-14 20:43:05.000000000 -0700
+++ configure 2014-02-25 10:54:12.000000000 -0800
@@ -12888,12 +12888,14 @@
done
test -n "$YACC" || YACC="yacc"
+if false; then
if test "x$YACC" != "xbison -y"; then
echo "************************"
echo "bison not found"
echo "************************"
exit -1
fi
+fi
# Checks for libraries.
lib_err_msg="add its path to LDFLAGS\nsee ./configure --help"
@@ -13532,7 +13534,7 @@
CFLAGS="$CFLAGS -Wall -W -Wfloat-equal -Wpointer-arith -Wcast-align -Wstrict-prototypes -Wredundant-decls \
-Wendif-labels -Wshadow -pipe -ffast-math -U__STRICT_ANSI__ -std=gnu99"
-if test "$with_debug" == "y"; then
+if test "$with_debug" = "y"; then
CFLAGS="$CFLAGS -g3 -O0"
elif test "$with_enable_optimized" != "no"; then
CFLAGS="$CFLAGS -g -O2"

View File

@ -0,0 +1,30 @@
$NetBSD: patch-configure.ac,v 1.1 2014/02/26 04:00:57 agc Exp $
The test for string equality in test(1) is "="
--- configure.ac.orig 2013-06-14 20:43:00.000000000 -0700
+++ configure.ac 2014-02-25 10:52:06.000000000 -0800
@@ -86,12 +86,14 @@
fi
AC_PROG_YACC
+if false; then
if test "x$YACC" != "xbison -y"; then
echo "************************"
echo "bison not found"
echo "************************"
exit -1
fi
+fi
# Checks for libraries.
lib_err_msg="add its path to LDFLAGS\nsee ./configure --help"
@@ -148,7 +150,7 @@
CFLAGS="$CFLAGS -Wall -W -Wfloat-equal -Wpointer-arith -Wcast-align -Wstrict-prototypes -Wredundant-decls \
-Wendif-labels -Wshadow -pipe -ffast-math -U__STRICT_ANSI__ -std=gnu99"
-if test "$with_debug" == "y"; then
+if test "$with_debug" = "y"; then
CFLAGS="$CFLAGS -g3 -O0"
elif test "$with_enable_optimized" != "no"; then
CFLAGS="$CFLAGS -g -O2"