summaryrefslogtreecommitdiff
path: root/sysutils/py-python-consul
diff options
context:
space:
mode:
Diffstat (limited to 'sysutils/py-python-consul')
-rw-r--r--sysutils/py-python-consul/Makefile30
-rw-r--r--sysutils/py-python-consul/distinfo3
-rw-r--r--sysutils/py-python-consul/files/patch-setup.py23
-rw-r--r--sysutils/py-python-consul/pkg-descr3
4 files changed, 59 insertions, 0 deletions
diff --git a/sysutils/py-python-consul/Makefile b/sysutils/py-python-consul/Makefile
new file mode 100644
index 000000000000..8c373f4f7990
--- /dev/null
+++ b/sysutils/py-python-consul/Makefile
@@ -0,0 +1,30 @@
+# $FreeBSD$
+
+PORTNAME= python-consul
+PORTVERSION= 1.1.0
+DISTVERSIONPREFIX= v
+PORTREVISION= 1
+CATEGORIES= sysutils python
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= jhixson@FreeBSD.org
+COMMENT= Python client for consul
+
+LICENSE= MIT
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= ${LOCALBASE}/bin/consul:sysutils/consul \
+ ${PYTHON_PKGNAMEPREFIX}requests>=2.0.0:www/py-requests@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}six>=1.4:devel/py-six@${PY_FLAVOR}
+RUN_DEPENDS= ${LOCALBASE}/bin/consul:sysutils/consul \
+ ${PYTHON_PKGNAMEPREFIX}requests>=2.0.0:www/py-requests@${PY_FLAVOR} \
+ ${PYTHON_PKGNAMEPREFIX}six>=1.4:devel/py-six@${PY_FLAVOR}
+
+USES= python:2.7-3.6+
+
+USE_PYTHON= distutils autoplist
+
+USE_GITHUB= yes
+GH_ACCOUNT= cablehead
+
+.include <bsd.port.mk>
diff --git a/sysutils/py-python-consul/distinfo b/sysutils/py-python-consul/distinfo
new file mode 100644
index 000000000000..2c88b19ac75f
--- /dev/null
+++ b/sysutils/py-python-consul/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1546923514
+SHA256 (cablehead-python-consul-v1.1.0_GH0.tar.gz) = 5ad41822e2791fb5edc986e17bae6978573fbe44e7075fb12243e74008abfe13
+SIZE (cablehead-python-consul-v1.1.0_GH0.tar.gz) = 27548878
diff --git a/sysutils/py-python-consul/files/patch-setup.py b/sysutils/py-python-consul/files/patch-setup.py
new file mode 100644
index 000000000000..bf913532c37e
--- /dev/null
+++ b/sysutils/py-python-consul/files/patch-setup.py
@@ -0,0 +1,23 @@
+--- setup.py.orig 2018-07-09 03:59:48 UTC
++++ setup.py
+@@ -22,14 +22,15 @@ description = "Python client for Consul (http://www.co
+
+ py_modules = [os.path.splitext(x)[0] for x in glob.glob('consul/*.py')]
+
++# Issue #123: skip installation of consul.aio if python version < 3.4.2
++# as this version or later is required by aiohttp
++if sys.version_info < (3, 4, 2):
++ if 'consul/aio' in py_modules:
++ py_modules.remove('consul/aio')
+
++
+ class Install(install):
+ def run(self):
+- # Issue #123: skip installation of consul.aio if python version < 3.4.2
+- # as this version or later is required by aiohttp
+- if sys.version_info < (3, 4, 2):
+- if 'consul/aio' in self.distribution.py_modules:
+- self.distribution.py_modules.remove('consul/aio')
+ install.run(self)
+
+
diff --git a/sysutils/py-python-consul/pkg-descr b/sysutils/py-python-consul/pkg-descr
new file mode 100644
index 000000000000..324d40156bc4
--- /dev/null
+++ b/sysutils/py-python-consul/pkg-descr
@@ -0,0 +1,3 @@
+Python client for consul (WWW: http://www.consul.io)
+
+WWW: https://github.com/cablehead/python-consul