mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-05 06:33:50 +02:00
opendkim: migrate to Python 3.
This commit is contained in:
parent
e032422a49
commit
3197ebf9eb
2 changed files with 38 additions and 4 deletions
34
srcpkgs/opendkim/patches/python3.diff
Normal file
34
srcpkgs/opendkim/patches/python3.diff
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
--- a/contrib/repute/repute.py 2023-08-27 07:36:35.000000000 +0100
|
||||||
|
+++ b/contrib/repute/repute.py 2023-10-06 20:30:28.370530279 +0100
|
||||||
|
@@ -1,4 +1,4 @@
|
||||||
|
-#!/usr/bin/env python
|
||||||
|
+#!/usr/bin/env python3
|
||||||
|
#
|
||||||
|
# sudo yum-builddep MySQL-python / sudo apt-get build-dep python-mysqldb
|
||||||
|
# Prereq:
|
||||||
|
@@ -17,7 +17,6 @@
|
||||||
|
from saratoga.outputFormats import OutputRegistry
|
||||||
|
from twisted.enterprise import adbapi
|
||||||
|
from twisted.internet import defer
|
||||||
|
-import itertools
|
||||||
|
import json
|
||||||
|
|
||||||
|
class DKIM(object):
|
||||||
|
@@ -80,7 +79,7 @@
|
||||||
|
rows = yield self.cp.runQuery(query, {'domain': domain, 'reporter': reporter})
|
||||||
|
|
||||||
|
if len(rows) > 0:
|
||||||
|
- ret = dict(itertools.izip(fields, rows[0]))
|
||||||
|
+ ret = dict(zip(fields, rows[0]))
|
||||||
|
else:
|
||||||
|
ret = 0
|
||||||
|
defer.returnValue(ret)
|
||||||
|
@@ -104,7 +103,7 @@
|
||||||
|
|
||||||
|
rows = yield self.cp.runQuery(query, { 'reporter' : reporter } )
|
||||||
|
if len(rows) > 0:
|
||||||
|
- ret = dict(itertools.izip(fields, rows[0]))
|
||||||
|
+ ret = dict(zip(fields, rows[0]))
|
||||||
|
request.setHeader('Last-modified', rows[0][3].strftime("%A, %d, %B %Y %H:%M GMT"))
|
||||||
|
else:
|
||||||
|
ret = False
|
|
@ -1,7 +1,7 @@
|
||||||
# Template file for 'opendkim'
|
# Template file for 'opendkim'
|
||||||
pkgname=opendkim
|
pkgname=opendkim
|
||||||
version=2.10.3
|
version=2.10.3
|
||||||
revision=14
|
revision=15
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
configure_args="--with-milter=${XBPS_CROSS_BASE}/usr"
|
configure_args="--with-milter=${XBPS_CROSS_BASE}/usr"
|
||||||
hostmakedepends="pkg-config automake gettext libtool"
|
hostmakedepends="pkg-config automake gettext libtool"
|
||||||
|
@ -13,7 +13,7 @@ license="BSD-3-Clause, Sendmail"
|
||||||
homepage="http://www.opendkim.org"
|
homepage="http://www.opendkim.org"
|
||||||
distfiles="${SOURCEFORGE_SITE}/project/${pkgname}/${pkgname}-${version}.tar.gz"
|
distfiles="${SOURCEFORGE_SITE}/project/${pkgname}/${pkgname}-${version}.tar.gz"
|
||||||
checksum=43a0ba57bf942095fe159d0748d8933c6b1dd1117caf0273fa9a0003215e681b
|
checksum=43a0ba57bf942095fe159d0748d8933c6b1dd1117caf0273fa9a0003215e681b
|
||||||
python_version=2
|
python_version=3
|
||||||
|
|
||||||
pre_configure() {
|
pre_configure() {
|
||||||
autoreconf -fi
|
autoreconf -fi
|
||||||
|
@ -30,8 +30,8 @@ opendkim-devel_package() {
|
||||||
depends="${sourcepkg}>=${version}_${revision}"
|
depends="${sourcepkg}>=${version}_${revision}"
|
||||||
pkg_install() {
|
pkg_install() {
|
||||||
vmove usr/include
|
vmove usr/include
|
||||||
vmove usr/lib/*.a
|
vmove "usr/lib/*.a"
|
||||||
vmove usr/lib/*.so
|
vmove "usr/lib/*.so"
|
||||||
vmove usr/lib/pkgconfig
|
vmove usr/lib/pkgconfig
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue