diff --git a/security/libb2/Makefile b/security/libb2/Makefile new file mode 100644 index 00000000000..67df831d47a --- /dev/null +++ b/security/libb2/Makefile @@ -0,0 +1,37 @@ +# $OpenBSD: Makefile,v 1.1.1.1 2018/01/01 15:40:55 bcallah Exp $ + +COMMENT = library providing BLAKE2b, BLAKE2s, BLAKE2bp, BLAKE2sp +DISTNAME = libb2-0.98.20171225 +CATEGORIES = security + +SHARED_LIBS += b2 0.0 # 1.3 + +# No GH_TAGNAME +GH_ACCOUNT = BLAKE2 +GH_PROJECT = libb2 +GH_COMMIT = 60ea749837362c226e8501718f505ab138e5c19d + +MAINTAINER = Bjorn Ketelaars + +# CC0 +PERMIT_PACKAGE_CDROM = Yes + +BUILD_DEPENDS = ${MODGNU_AUTOCONF_DEPENDS} \ + ${MODGNU_AUTOMAKE_DEPENDS} \ + devel/libtool + +CONFIGURE_STYLE = gnu +CONFIGURE_ARGS = --disable-fat \ + --disable-native \ + --disable-openmp + +SEPARATE_BUILD = Yes + +AUTOCONF_VERSION = 2.69 +AUTOMAKE_VERSION = 1.15 + +pre-configure: + cd ${WRKSRC} && ${SETENV} AUTOCONF_VERSION=${AUTOCONF_VERSION} \ + AUTOMAKE_VERSION=${AUTOMAKE_VERSION} ./autogen.sh + +.include diff --git a/security/libb2/distinfo b/security/libb2/distinfo new file mode 100644 index 00000000000..db070f9c69f --- /dev/null +++ b/security/libb2/distinfo @@ -0,0 +1,2 @@ +SHA256 (libb2-0.98.20171225-60ea7498.tar.gz) = hFPmDkOFj1DIsdroNJEzyl/mzA4PeLWIFl/AVTtMGnk= +SIZE (libb2-0.98.20171225-60ea7498.tar.gz) = 275231 diff --git a/security/libb2/patches/patch-configure_ac b/security/libb2/patches/patch-configure_ac new file mode 100644 index 00000000000..b54ddbaaa78 --- /dev/null +++ b/security/libb2/patches/patch-configure_ac @@ -0,0 +1,15 @@ +$OpenBSD: patch-configure_ac,v 1.1.1.1 2018/01/01 15:40:55 bcallah Exp $ + +Do not hardcode optimization flags. + +Index: configure.ac +--- configure.ac.orig ++++ configure.ac +@@ -58,7 +58,6 @@ AC_HELP_STRING([--enable-native], + [enable_native=yes] + ) + +-AX_CHECK_COMPILE_FLAG([-O3], [CFLAGS=-O3]) + dnl Not all architectures support -march=native + AX_CHECK_COMPILE_FLAG([-march=native], [], [enable_native=no]) + diff --git a/security/libb2/pkg/DESCR b/security/libb2/pkg/DESCR new file mode 100644 index 00000000000..07ff42558f4 --- /dev/null +++ b/security/libb2/pkg/DESCR @@ -0,0 +1,5 @@ +libb2 is a C library providing BLAKE2b, BLAKE2s, BLAKE2bp, BLAKE2sp. + +BLAKE2 is a cryptographic hash function faster than MD5, SHA-1, SHA-2, +and SHA-3, yet is at least as secure as the latest standard SHA-3. +BLAKE2 is specified in RFC 7693. diff --git a/security/libb2/pkg/PLIST b/security/libb2/pkg/PLIST new file mode 100644 index 00000000000..6427c21f906 --- /dev/null +++ b/security/libb2/pkg/PLIST @@ -0,0 +1,5 @@ +@comment $OpenBSD: PLIST,v 1.1.1.1 2018/01/01 15:40:55 bcallah Exp $ +include/blake2.h +lib/libb2.a +lib/libb2.la +@lib lib/libb2.so.${LIBb2_VERSION}