pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

py-pynetbox: add a draft of a package.



Module Name:	pkgsrc-wip
Committed By:	Havard Eidnes <he%NetBSD.org@localhost>
Pushed By:	he
Date:		Thu Jan 25 01:33:56 2024 +0100
Changeset:	e7993ef36654585d1077b0f3a0c85c4262535186

Added Files:
	py-pynetbox/DESCR
	py-pynetbox/Makefile
	py-pynetbox/PLIST
	py-pynetbox/TODO
	py-pynetbox/distinfo

Log Message:
py-pynetbox: add a draft of a package.

This doesn't actually install, I'm apparently unable to figure
out how to properly mix upstream's instructions and pkgsrc, setting
to use the correct build & install methods -- one of the great
mysteries to me in the pkgsrc / python environment.

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=e7993ef36654585d1077b0f3a0c85c4262535186

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 py-pynetbox/DESCR    |  4 ++++
 py-pynetbox/Makefile | 30 ++++++++++++++++++++++++++++++
 py-pynetbox/PLIST    |  0
 py-pynetbox/TODO     | 16 ++++++++++++++++
 py-pynetbox/distinfo |  5 +++++
 5 files changed, 55 insertions(+)

diffs:
diff --git a/py-pynetbox/DESCR b/py-pynetbox/DESCR
new file mode 100644
index 0000000000..dce5660003
--- /dev/null
+++ b/py-pynetbox/DESCR
@@ -0,0 +1,4 @@
+Python API client library for NetBox.
+
+    Note: Version 6.7 and later of the library only supports NetBox
+    3.3 and above.
diff --git a/py-pynetbox/Makefile b/py-pynetbox/Makefile
new file mode 100644
index 0000000000..8ad03906e2
--- /dev/null
+++ b/py-pynetbox/Makefile
@@ -0,0 +1,30 @@
+# $NetBSD$
+
+DISTNAME=	pynetbox-7.3.3
+PKGNAME=	${PYPKGPREFIX}-${DISTNAME}
+CATEGORIES=	net
+MASTER_SITES=	${MASTER_SITE_GITHUB:=netbox-community/}
+GITHUB_PROJECT=	pynetbox
+GITHUB_TAG=	v${PKGVERSION_NOREV}
+
+MAINTAINER=	pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=	http://github.com/netbox-community/pynetbox
+COMMENT=	Python API client library for NetBox
+LICENSE=	apache-2.0
+
+EGG_NAME=	${DISTNAME}
+
+DEPENDS+=	${PYPKGPREFIX}-requests>2.20.0<3.0:../../devel/py-requests
+DEPENDS+=	${PYPKGPREFIX}-packaging<24.0:../../devel/py-packaging
+
+# Needed for installation:
+#DEPENDS+=	${PYPKGPREFIX}-wheel-[0-9]*:../../devel/py-wheel
+#DEPENDS+=	${PYPKGPREFIX}-pip-[0-9]*:../../devel/py-pip
+#TOOL_DEPENDS+=	${PYPKGPREFIX}-setuptools_scm->=0:../../devel/py-setuptools_scm
+
+PYTHON_VERSIONED_DEPENDENCIES=	setuptools_scm
+
+.include "../../lang/python/extension.mk"
+.include "../../lang/python/egg.mk"
+.include "../../lang/python/versioned_dependencies.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/py-pynetbox/PLIST b/py-pynetbox/PLIST
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/py-pynetbox/TODO b/py-pynetbox/TODO
new file mode 100644
index 0000000000..41de919dcb
--- /dev/null
+++ b/py-pynetbox/TODO
@@ -0,0 +1,16 @@
+Figure out how this is supposed to be built / installed.
+
+The package has a setup.py file which contains
+    setup_requires=["setuptools_scm"],
+and after adding it as a DEPENDS, I now get an error message
+saying
+
+  File "/usr/pkg/lib/python3.10/site-packages/setuptools_scm/__init__.py", line 109, in _version_missing
+    raise LookupError(
+LookupError: setuptools-scm was unable to detect version for /usr/pkgsrc/wip/py-pynetbox/work/pynetbox-7.3.3.
+
+Make sure you're either building from a fully intact git repository or PyPI tarballs. Most other sources (such as GitHub's tarballs, a git checkout without the .git folder) don't contain the necessary metadata and will not work.
+
+For example, if you're using pip, instead of https://github.com/user/proj/archive/master.zip use git+https://github.com/user/proj.git#egg=proj
+
+But ... what if anything of this do we follow in pkgsrc?
diff --git a/py-pynetbox/distinfo b/py-pynetbox/distinfo
new file mode 100644
index 0000000000..ba1a87ad14
--- /dev/null
+++ b/py-pynetbox/distinfo
@@ -0,0 +1,5 @@
+$NetBSD$
+
+BLAKE2s (pynetbox-7.3.3.tar.gz) = 8be837bbd6075f4eb4bb5789da5db97154f0a6a53ea8fab4bf7b542a29b034d1
+SHA512 (pynetbox-7.3.3.tar.gz) = 6429ef378dbae875a26ee80cc9e7868ae0812f6758249410447f65b033eb61de7679d83d6925ec866af2ee3aa7ccddd380a997751912a7073553030ffe01c79c
+Size (pynetbox-7.3.3.tar.gz) = 64602 bytes


Home | Main Index | Thread Index | Old Index