Import devel/crc32c

Initially ported to avoid the bundled copy in net/tg_owt, but other ports
can probably pick it up as well.

Feedback OK sthen tb
---
Collection of CRC32C implementations that dispatches to one suitable to
the hardware. CRC32C is the cyclic redundancy check that uses the iSCSI
polynomial specified in RFC 3720.
This commit is contained in:
kn 2022-12-14 15:48:54 +00:00
parent eae2f44fc2
commit 913cd5c35a
4 changed files with 43 additions and 0 deletions

29
devel/crc32c/Makefile Normal file
View File

@ -0,0 +1,29 @@
COMMENT = CRC32 implementation in hardware
CATEGORIES = devel
GH_ACCOUNT = google
GH_PROJECT = crc32c
GH_TAGNAME = 1.1.2
MAINTAINER = Klemens Nanni <kn@openbsd.org>
# BSD 3-clause
PERMIT_PACKAGE = Yes
SHARED_LIBS += crc32c 0.0 # 1.1.0
# C++11
COMPILER = base-clang ports-gcc
WANTLIB += ${COMPILER_LIBCXX} m
MODULES = devel/cmake
CONFIGURE_ARGS += -DBUILD_SHARED_LIBS=ON
# all three expect bundled but nonexistent sources
CONFIGURE_ARGS += -DCRC32C_BUILD_TESTS=OFF \
-DCRC32C_BUILD_BENCHMARKS=OFF \
-DCRC32C_USE_GLOG=OFF
.include <bsd.port.mk>

2
devel/crc32c/distinfo Normal file
View File

@ -0,0 +1,2 @@
SHA256 (crc32c-1.1.2.tar.gz) = rAeEBRMHK3/OvaboIQaKoEiJAY8k4Q5GGBBo+yFNflY=
SIZE (crc32c-1.1.2.tar.gz) = 29819

3
devel/crc32c/pkg/DESCR Normal file
View File

@ -0,0 +1,3 @@
Collection of CRC32C implementations that dispatches to one suitable to
the hardware. CRC32C is the cyclic redundancy check that uses the iSCSI
polynomial specified in RFC 3720.

9
devel/crc32c/pkg/PLIST Normal file
View File

@ -0,0 +1,9 @@
include/crc32c/
include/crc32c/crc32c.h
lib/cmake/
lib/cmake/Crc32c/
lib/cmake/Crc32c/Crc32cConfig.cmake
lib/cmake/Crc32c/Crc32cConfigVersion.cmake
lib/cmake/Crc32c/Crc32cTargets${MODCMAKE_BUILD_SUFFIX}
lib/cmake/Crc32c/Crc32cTargets.cmake
@lib lib/libcrc32c.so.${LIBcrc32c_VERSION}