git: 9b9f2b69b614 - main - devel/py-construct-classes: Add new port

From: Emanuel Haupt <ehaupt_at_FreeBSD.org>
Date: Mon, 07 Nov 2022 15:31:49 UTC
The branch main has been updated by ehaupt:

URL: https://cgit.FreeBSD.org/ports/commit/?id=9b9f2b69b61439693ac862da3955c802af11195a

commit 9b9f2b69b61439693ac862da3955c802af11195a
Author:     Emanuel Haupt <ehaupt@FreeBSD.org>
AuthorDate: 2022-11-07 15:31:05 +0000
Commit:     Emanuel Haupt <ehaupt@FreeBSD.org>
CommitDate: 2022-11-07 15:31:42 +0000

    devel/py-construct-classes: Add new port
    
    Parse your binary data into dataclasses. Pack your dataclasses into
    binary data.
    
    construct-classes rely on construct for parsing and packing. The
    programmer needs to manually write the Construct expressions. There is
    also no type verification, so it is the programmer's responsibility that
    the dataclass and the Construct expression match.
---
 devel/Makefile                       |  1 +
 devel/py-construct-classes/Makefile  | 21 +++++++++++++++++++++
 devel/py-construct-classes/distinfo  |  3 +++
 devel/py-construct-classes/pkg-descr |  7 +++++++
 4 files changed, 32 insertions(+)

diff --git a/devel/Makefile b/devel/Makefile
index c1c8407e94d7..4d384a47567a 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -4403,6 +4403,7 @@
     SUBDIR += py-connection_pool
     SUBDIR += py-constantly
     SUBDIR += py-construct
+    SUBDIR += py-construct-classes
     SUBDIR += py-contextlib2
     SUBDIR += py-convertdate
     SUBDIR += py-cookiecutter
diff --git a/devel/py-construct-classes/Makefile b/devel/py-construct-classes/Makefile
new file mode 100644
index 000000000000..0b34c9186215
--- /dev/null
+++ b/devel/py-construct-classes/Makefile
@@ -0,0 +1,21 @@
+PORTNAME=	construct-classes
+PORTVERSION=	0.1.2
+CATEGORIES=	devel python
+MASTER_SITES=	CHEESESHOP
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	ehaupt@FreeBSD.org
+COMMENT=	Parse your binary structs into dataclasses
+WWW=		https://pypi.org/project/construct-classes/
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}construct>=2.10:devel/py-construct@${PY_FLAVOR}
+
+USES=		python
+USE_PYTHON=	autoplist distutils
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/devel/py-construct-classes/distinfo b/devel/py-construct-classes/distinfo
new file mode 100644
index 000000000000..c798431c772c
--- /dev/null
+++ b/devel/py-construct-classes/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1667833393
+SHA256 (construct-classes-0.1.2.tar.gz) = 72ac1abbae5bddb4918688713f991f5a7fb6c9b593646a82f4bf3ac53de7eeb5
+SIZE (construct-classes-0.1.2.tar.gz) = 5018
diff --git a/devel/py-construct-classes/pkg-descr b/devel/py-construct-classes/pkg-descr
new file mode 100644
index 000000000000..81a7d35d33c2
--- /dev/null
+++ b/devel/py-construct-classes/pkg-descr
@@ -0,0 +1,7 @@
+Parse your binary data into dataclasses. Pack your dataclasses into
+binary data.
+
+construct-classes rely on construct for parsing and packing. The
+programmer needs to manually write the Construct expressions. There is
+also no type verification, so it is the programmer's responsibility that
+the dataclass and the Construct expression match.