git: 5e19bd196486 - main - x11-fonts/py-gflanguages: Add py-gflanguages 0.4.0

From: Po-Chuan Hsieh <sunpoet_at_FreeBSD.org>
Date: Thu, 09 Jun 2022 23:19:31 UTC
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=5e19bd196486ae4969dc280948f70fc72dcf8015

commit 5e19bd196486ae4969dc280948f70fc72dcf8015
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-06-09 23:09:44 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-06-09 23:16:01 +0000

    x11-fonts/py-gflanguages: Add py-gflanguages 0.4.0
    
    This python module provides an API with data about languages/regions/scripts for
    use in the language-support categorization of the font families in the Google
    Fonts collection.
    
    You can also directly access the raw textproto files on the Lib/gflanguages/data
    directory:
    - languages
    - regions
    - scripts
    
    WWW: https://github.com/googlefonts/lang
---
 x11-fonts/Makefile                            |  1 +
 x11-fonts/py-gflanguages/Makefile             | 23 +++++++++++++++++++++++
 x11-fonts/py-gflanguages/distinfo             |  3 +++
 x11-fonts/py-gflanguages/files/patch-setup.py | 11 +++++++++++
 x11-fonts/py-gflanguages/pkg-descr            | 11 +++++++++++
 5 files changed, 49 insertions(+)

diff --git a/x11-fonts/Makefile b/x11-fonts/Makefile
index 2aaa803093bc..2145235afb76 100644
--- a/x11-fonts/Makefile
+++ b/x11-fonts/Makefile
@@ -225,6 +225,7 @@
     SUBDIR += py-defcon
     SUBDIR += py-fontMath
     SUBDIR += py-fontmake
+    SUBDIR += py-gflanguages
     SUBDIR += py-glyphsLib
     SUBDIR += py-opentype-sanitizer
     SUBDIR += py-opentypespec
diff --git a/x11-fonts/py-gflanguages/Makefile b/x11-fonts/py-gflanguages/Makefile
new file mode 100644
index 000000000000..ac006cd89657
--- /dev/null
+++ b/x11-fonts/py-gflanguages/Makefile
@@ -0,0 +1,23 @@
+# Created by: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
+
+PORTNAME=	gflanguages
+PORTVERSION=	0.4.0
+CATEGORIES=	x11-fonts python
+MASTER_SITES=	CHEESESHOP
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	sunpoet@FreeBSD.org
+COMMENT=	Python API for evaluating language support in the Google Fonts collection
+
+LICENSE=	APACHE20
+LICENSE_FILE=	${WRKSRC}/LICENSE.txt
+
+BUILD_DEPENDS=	${PYTHON_PKGNAMEPREFIX}setuptools_scm>=4:devel/py-setuptools_scm@${PY_FLAVOR}
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}protobuf>=0,1:devel/py-protobuf@${PY_FLAVOR}
+
+USES=		python:3.7+
+USE_PYTHON=	autoplist concurrent distutils
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/x11-fonts/py-gflanguages/distinfo b/x11-fonts/py-gflanguages/distinfo
new file mode 100644
index 000000000000..088f7be282ad
--- /dev/null
+++ b/x11-fonts/py-gflanguages/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1654774052
+SHA256 (gflanguages-0.4.0.tar.gz) = c1ef3c27b741fcf5064ebbf4e3d9ef2bef037e9ec620c9a9d0aa5c3add2124bf
+SIZE (gflanguages-0.4.0.tar.gz) = 673638
diff --git a/x11-fonts/py-gflanguages/files/patch-setup.py b/x11-fonts/py-gflanguages/files/patch-setup.py
new file mode 100644
index 000000000000..14b5b6f0c94d
--- /dev/null
+++ b/x11-fonts/py-gflanguages/files/patch-setup.py
@@ -0,0 +1,11 @@
+--- setup.py.orig	2022-03-04 21:26:42 UTC
++++ setup.py
+@@ -51,7 +51,7 @@ setup(
+         'Programming Language :: Python :: 3'
+     ],
+     python_requires=">=3.7",
+-    setup_requires=['setuptools_scm>=4,<6.1'],
++    setup_requires=['setuptools_scm>=4'],
+     install_requires=[
+         'protobuf'
+     ]
diff --git a/x11-fonts/py-gflanguages/pkg-descr b/x11-fonts/py-gflanguages/pkg-descr
new file mode 100644
index 000000000000..bc226511208f
--- /dev/null
+++ b/x11-fonts/py-gflanguages/pkg-descr
@@ -0,0 +1,11 @@
+This python module provides an API with data about languages/regions/scripts for
+use in the language-support categorization of the font families in the Google
+Fonts collection.
+
+You can also directly access the raw textproto files on the Lib/gflanguages/data
+directory:
+- languages
+- regions
+- scripts
+
+WWW: https://github.com/googlefonts/lang