[arch-commits] Commit in python-pyroute2/repos/community-any (5 files)
Thore Bödecker
foxxx0 at gemini.archlinux.org
Wed Nov 3 18:38:36 UTC 2021
Date: Wednesday, November 3, 2021 @ 18:38:36
Author: foxxx0
Revision: 1035648
archrelease: copy trunk to community-any
Added:
python-pyroute2/repos/community-any/PKGBUILD
(from rev 1035647, python-pyroute2/trunk/PKGBUILD)
python-pyroute2/repos/community-any/fix-wireguard-key-parsing.patch
(from rev 1035647, python-pyroute2/trunk/fix-wireguard-key-parsing.patch)
python-pyroute2/repos/community-any/fix_sphinx_css.patch
(from rev 1035647, python-pyroute2/trunk/fix_sphinx_css.patch)
Deleted:
python-pyroute2/repos/community-any/PKGBUILD
python-pyroute2/repos/community-any/fix_sphinx_css.patch
---------------------------------+
PKGBUILD | 90 +++++++++++++++++++-------------------
fix-wireguard-key-parsing.patch | 42 +++++++++++++++++
fix_sphinx_css.patch | 18 +++----
3 files changed, 97 insertions(+), 53 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2021-11-03 18:38:31 UTC (rev 1035647)
+++ PKGBUILD 2021-11-03 18:38:36 UTC (rev 1035648)
@@ -1,44 +0,0 @@
-# Maintainer: Thore Bödecker <foxxx0 at archlinux.org>
-# Contributor: brent s. <bts[at]square-r00t[dot]net>
-# Contributor: Alexander Phinikarides <alexisph _AT_ gmail _DOT_ com>
-
-pkgbase='python-pyroute2'
-_pkgbase="${pkgbase//python-/}"
-pkgname=("python-${_pkgbase}")
-pkgdesc="A pure Python netlink and Linux network configuration library"
-pkgver=0.5.19
-pkgrel=3
-arch=('any')
-url="https://docs.pyroute2.org/"
-license=('GPL2' 'Apache')
-depends=('python')
-makedepends=('python' 'python-setuptools' 'python-setuptools-scm' 'python-sphinx' 'git' 'python-aafigure' 'twine')
-source=("https://files.pythonhosted.org/packages/source/${_pkgbase:0:1}/${_pkgbase}/${_pkgbase}-${pkgver}.tar.gz")
-# source=("${_pkgbase}-${pkgver}.tar.gz::https://github.com/svinota/${_pkgbase}/archive/${pkgver}.tar.gz"
-# 'fix_sphinx_css.patch')
-sha512sums=('bd60e2adf59b8438ff4f6abf2d41cf18eb60dcef3072577648488db45ffe89bd9c7207c4eccc38eb9256533ea2950e7f20b82ae4940b1207ba71d0f261e83f6d')
-
-prepare() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
- :
-}
-
-build() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
- python setup.py build
-}
-
-check() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
- python setup.py check
-}
-
-package() {
- cd "${srcdir}/${_pkgbase}-${pkgver}"
- python setup.py install --root="${pkgdir}/" --optimize=1
- # Tests get installed into the package for some reason
- PYTHON_STDLIB="$(python -c "from sysconfig import get_path; print(get_path('stdlib'))")"
- rm -rf "${pkgdir%/}/${PYTHON_STDLIB#/}/site-packages/tests"
-}
-
-# vim:set ts=2 sw=2 et:
Copied: python-pyroute2/repos/community-any/PKGBUILD (from rev 1035647, python-pyroute2/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2021-11-03 18:38:36 UTC (rev 1035648)
@@ -0,0 +1,46 @@
+# Maintainer: Thore Bödecker <foxxx0 at archlinux.org>
+# Contributor: brent s. <bts[at]square-r00t[dot]net>
+# Contributor: Alexander Phinikarides <alexisph _AT_ gmail _DOT_ com>
+
+pkgbase='python-pyroute2'
+_pkgbase="${pkgbase//python-/}"
+pkgname=("python-${_pkgbase}")
+pkgdesc="A pure Python netlink and Linux network configuration library"
+pkgver=0.5.19
+pkgrel=4
+arch=('any')
+url="https://docs.pyroute2.org/"
+license=('GPL2' 'Apache')
+depends=('python')
+makedepends=('python' 'python-setuptools' 'python-setuptools-scm' 'python-sphinx' 'git' 'python-aafigure' 'twine')
+source=("https://files.pythonhosted.org/packages/source/${_pkgbase:0:1}/${_pkgbase}/${_pkgbase}-${pkgver}.tar.gz"
+ 'fix-wireguard-key-parsing.patch')
+# source=("${_pkgbase}-${pkgver}.tar.gz::https://github.com/svinota/${_pkgbase}/archive/${pkgver}.tar.gz"
+# 'fix_sphinx_css.patch')
+sha512sums=('bd60e2adf59b8438ff4f6abf2d41cf18eb60dcef3072577648488db45ffe89bd9c7207c4eccc38eb9256533ea2950e7f20b82ae4940b1207ba71d0f261e83f6d'
+ '612e81058337e4e9d08fb083cfaf0efae180fbdc6c4150fa122160aa91b71b005bacef6cd3f171091ee1cb7e79523470db156448368f183b87f6474eb984691a')
+
+prepare() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ patch -p1 -N -i "${srcdir}/fix-wireguard-key-parsing.patch"
+}
+
+build() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ python setup.py build
+}
+
+check() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ python setup.py check
+}
+
+package() {
+ cd "${srcdir}/${_pkgbase}-${pkgver}"
+ python setup.py install --root="${pkgdir}/" --optimize=1
+ # Tests get installed into the package for some reason
+ PYTHON_STDLIB="$(python -c "from sysconfig import get_path; print(get_path('stdlib'))")"
+ rm -rf "${pkgdir%/}/${PYTHON_STDLIB#/}/site-packages/tests"
+}
+
+# vim:set ts=2 sw=2 et:
Copied: python-pyroute2/repos/community-any/fix-wireguard-key-parsing.patch (from rev 1035647, python-pyroute2/trunk/fix-wireguard-key-parsing.patch)
===================================================================
--- fix-wireguard-key-parsing.patch (rev 0)
+++ fix-wireguard-key-parsing.patch 2021-11-03 18:38:36 UTC (rev 1035648)
@@ -0,0 +1,42 @@
+From 1fba06684062a298b22801c71a1ae091d313cc11 Mon Sep 17 00:00:00 2001
+From: K900 <me at 0upti.me>
+Date: Mon, 24 May 2021 09:57:11 +0300
+Subject: [PATCH] wireguard: fix parsing keys
+
+Load the keys from the correct place in the message, and load them as the right length as well.
+---
+ pyroute2/netlink/generic/wireguard.py | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/pyroute2/netlink/generic/wireguard.py b/pyroute2/netlink/generic/wireguard.py
+index 17b510d2..74f448e0 100644
+--- a/pyroute2/netlink/generic/wireguard.py
++++ b/pyroute2/netlink/generic/wireguard.py
+@@ -151,11 +151,11 @@ class wgdevice_peer(nla):
+ ('WGPEER_A_PROTOCOL_VERSION', 'uint32'))
+
+ class parse_peer_key(nla):
+- fields = (('key', 's'), )
++ fields = (('key', '32s'), )
+
+ def decode(self):
+ nla.decode(self)
+- self['value'] = b64encode(self['value'])
++ self['value'] = b64encode(self['key'])
+
+ def encode(self):
+ self['key'] = b64decode(self['value'])
+@@ -220,11 +220,11 @@ def decode(self):
+ self['addr'] = '{0}/{1}'.format(self['addr'], wgaddr)
+
+ class parse_wg_key(nla):
+- fields = (('key', 's'), )
++ fields = (('key', '32s'), )
+
+ def decode(self):
+ nla.decode(self)
+- self['value'] = b64encode(self['value'])
++ self['value'] = b64encode(self['key'])
+
+ def encode(self):
+ self['key'] = b64decode(self['value'])
Deleted: fix_sphinx_css.patch
===================================================================
--- fix_sphinx_css.patch 2021-11-03 18:38:31 UTC (rev 1035647)
+++ fix_sphinx_css.patch 2021-11-03 18:38:36 UTC (rev 1035648)
@@ -1,9 +0,0 @@
-diff -upr a/docs/conf.py b/docs/conf.py
---- a/docs/conf.py 2021-05-13 23:09:46.000000000 +0200
-+++ b/docs/conf.py 2021-09-01 11:32:22.089740192 +0200
-@@ -46,4 +46,4 @@ texinfo_documents = [('index',
-
-
- def setup(app):
-- app.add_stylesheet('custom.css')
-+ app.add_css_file('custom.css')
Copied: python-pyroute2/repos/community-any/fix_sphinx_css.patch (from rev 1035647, python-pyroute2/trunk/fix_sphinx_css.patch)
===================================================================
--- fix_sphinx_css.patch (rev 0)
+++ fix_sphinx_css.patch 2021-11-03 18:38:36 UTC (rev 1035648)
@@ -0,0 +1,9 @@
+diff -upr a/docs/conf.py b/docs/conf.py
+--- a/docs/conf.py 2021-05-13 23:09:46.000000000 +0200
++++ b/docs/conf.py 2021-09-01 11:32:22.089740192 +0200
+@@ -46,4 +46,4 @@ texinfo_documents = [('index',
+
+
+ def setup(app):
+- app.add_stylesheet('custom.css')
++ app.add_css_file('custom.css')
More information about the arch-commits
mailing list