From 0ac22f8d9c2226481eef6dfa554665f7a885afcd Mon Sep 17 00:00:00 2001 From: Dmitry Marakasov Date: Thu, 12 Apr 2018 12:39:41 +0000 Subject: [PATCH] - Add devel/protozero (needed for devel/osmium update) Minimalistic protocol buffer decoder and encoder in C++. Designed for high performance. Suitable for writing zero copy parsers and encoders with minimal need for run-time allocation of memory. Low-level: this is designed to be a building block for writing a very customized decoder for a stable protobuf schema. If your protobuf schema is changing frequently or lazy decoding is not critical for your application then this approach offers no value: just use the C++ API that can be generated with the Google Protobufs protoc program. WWW: https://github.com/mapbox/protozero --- devel/Makefile | 1 + devel/protozero/Makefile | 35 +++++++++++++++++++++++++++++++++++ devel/protozero/distinfo | 3 +++ devel/protozero/pkg-descr | 13 +++++++++++++ devel/protozero/pkg-plist | 12 ++++++++++++ 5 files changed, 64 insertions(+) create mode 100644 devel/protozero/Makefile create mode 100644 devel/protozero/distinfo create mode 100644 devel/protozero/pkg-descr create mode 100644 devel/protozero/pkg-plist diff --git a/devel/Makefile b/devel/Makefile index d42bf2a8aaba..43e10d573f96 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -4136,6 +4136,7 @@ SUBDIR += protobuf SUBDIR += protobuf-c SUBDIR += protobuf25 + SUBDIR += protozero SUBDIR += pructl SUBDIR += psptoolchain SUBDIR += psptoolchain-binutils diff --git a/devel/protozero/Makefile b/devel/protozero/Makefile new file mode 100644 index 000000000000..087521b16898 --- /dev/null +++ b/devel/protozero/Makefile @@ -0,0 +1,35 @@ +# Created by: Dmitry Marakasov +# $FreeBSD$ + +PORTNAME= protozero +PORTVERSION= 1.6.2 +DISTVERSIONPREFIX= v +CATEGORIES= devel + +MAINTAINER= amdmi3@FreeBSD.org +COMMENT= Minimalist protocol buffer decoder and encoder in C++ + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE.md + +USE_GITHUB= yes +GH_ACCOUNT= mapbox + +USES= cmake +TEST_TARGET= test +NO_ARCH= yes # header only library + +PORTDOCS= CHANGELOG.md README.md UPGRADING.md + +OPTIONS_DEFINE= DOCS TEST +OPTIONS_DEFAULT= TEST # no additional runtime reps +TEST_DESC= Enable additional tests, requires protobuf at build time +TEST_BUILD_DEPENDS= protoc:devel/protobuf + +post-install-DOCS-on: + @${MKDIR} ${STAGEDIR}${DOCSDIR} +.for f in ${PORTDOCS} + ${INSTALL_DATA} ${WRKSRC}/${f} ${STAGEDIR}${DOCSDIR}/ +.endfor + +.include diff --git a/devel/protozero/distinfo b/devel/protozero/distinfo new file mode 100644 index 000000000000..673fe01623db --- /dev/null +++ b/devel/protozero/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1522871786 +SHA256 (mapbox-protozero-v1.6.2_GH0.tar.gz) = 1196441f98932c219e5684248249c5fd404023843b0a862034d5daf24eb74433 +SIZE (mapbox-protozero-v1.6.2_GH0.tar.gz) = 1063745 diff --git a/devel/protozero/pkg-descr b/devel/protozero/pkg-descr new file mode 100644 index 000000000000..2dbfcf63fb6e --- /dev/null +++ b/devel/protozero/pkg-descr @@ -0,0 +1,13 @@ +Minimalistic protocol buffer decoder and encoder in C++. + +Designed for high performance. Suitable for writing zero copy parsers +and encoders with minimal need for run-time allocation of memory. + +Low-level: this is designed to be a building block for writing a +very customized decoder for a stable protobuf schema. If your +protobuf schema is changing frequently or lazy decoding is not +critical for your application then this approach offers no value: +just use the C++ API that can be generated with the Google Protobufs +protoc program. + +WWW: https://github.com/mapbox/protozero diff --git a/devel/protozero/pkg-plist b/devel/protozero/pkg-plist new file mode 100644 index 000000000000..dfb0562e709b --- /dev/null +++ b/devel/protozero/pkg-plist @@ -0,0 +1,12 @@ +include/protozero/byteswap.hpp +include/protozero/config.hpp +include/protozero/data_view.hpp +include/protozero/exception.hpp +include/protozero/iterators.hpp +include/protozero/pbf_builder.hpp +include/protozero/pbf_message.hpp +include/protozero/pbf_reader.hpp +include/protozero/pbf_writer.hpp +include/protozero/types.hpp +include/protozero/varint.hpp +include/protozero/version.hpp