Python 2 Removal - Round 1 (#1866)

* gpgme: Drop the Python 2 package

* dtc: Build with Python 3

The package in the repo is already build using Python 3, so this basically
just fixes the dependency list.

* Drop jhbuild-git

This is a really old version and upstream doesn't target cygwin, so just drop it.

* python-colorama: Drop Python 2 package

* python-mako: Drop Python 2 package

* python-pyalpm: Update to 0.9.1 and drop Python 2 package

0.8 did no longer build with the current pacman so I had to update
as well to drop Python 2.

* python-pygments: Drop Python 2 package

* python2-pathlib: Remove package

Unused

* python2-scandir: Remove package

Unused

* python-beaker: Drop Python 2 package

* python-markupsafe: Drop Python 2 package

* python-mock: Drop Python 2 package

* python2-funcsigs: Remove package

Unused

* python-nose: Drop Python 2 package

Also adds a conflict with python2-nose because the man pages and
main script got moved to the Python 3 package.

* python2-unittest2: Remove package

Unused

* python2-traceback2: Remove package

Unused

* python2-linecache2: Remove package

Unused

* python-pbr: Drop Python 2 package
This commit is contained in:
Christoph Reiter
2020-02-24 08:40:03 +01:00
committed by GitHub
parent 5c58f0c7e6
commit 6d4b3577b4
26 changed files with 170 additions and 1037 deletions

View File

@@ -3,12 +3,15 @@
# Contributor: Felix Kaiser <felix.kaiser@fxkr.net>
pkgbase=python-mock
pkgname=(python2-mock python3-mock)
pkgname=(python-mock)
pkgver=3.0.5
pkgrel=1
pkgrel=2
pkgdesc='Mocking and Patching Library for Testing'
url='https://docs.python.org/3/library/unittest.mock.html'
makedepends=('python2' 'python3')
depends=('python')
provides=("python3-mock")
conflicts=("python3-mock")
replaces=("python3-mock")
license=('BSD')
arch=('any')
source=("https://pypi.python.org/packages/source/m/mock/mock-$pkgver.tar.gz")
@@ -21,26 +24,13 @@ prepare() {
}
build() {
cd "$srcdir"
cp -rf "mock-$pkgver" "mock2-$pkgver"
cd "$srcdir/mock-$pkgver"
python3 setup.py build
cd "$srcdir/mock2-$pkgver"
python2 setup.py build
python setup.py build
}
package_python3-mock() {
depends=('python3')
package() {
cd "$srcdir/mock-$pkgver"
python3 setup.py install --optimize=1 --root="$pkgdir"
install -Dm644 LICENSE.txt "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}
package_python2-mock() {
depends=('python2')
cd "$srcdir/mock2-$pkgver"
python2 setup.py install --optimize=1 --root="$pkgdir"
python setup.py install --optimize=1 --root="$pkgdir"
install -Dm644 LICENSE.txt "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}