Commit 00b1814e authored by Marian Buschsieweke's avatar Marian Buschsieweke Committed by Leonardo Arena

testing/py-matplotlib: Update to 2.2.3 & py3

 - Update to LTS version 2.2.3 (current version drops python 2 support)
 - Split up packages (py2-, py3-) to add python 3 support
parent 408fc973
--- ./media/audioipc/audioipc/src/cmsg.rs.orig 2018-05-09 22:19:14.748631939 +0200
+++ ./media/audioipc/audioipc/src/cmsg.rs 2018-05-09 22:19:22.961620862 +0200
@@ -106,11 +106,11 @@ impl ControlMsgBuilder {
return Err(Error::NoSpace);
}
- let cmsghdr = cmsghdr {
- cmsg_len: cmsg_len as _,
- cmsg_level: level,
- cmsg_type: kind,
- };
+ use std::mem;
+ let mut cmsghdr: cmsghdr = unsafe { mem::zeroed() };
+ cmsghdr.cmsg_len = cmsg_len as _;
+ cmsghdr.cmsg_level = level;
+ cmsghdr.cmsg_type = kind;
let cmsghdr = unsafe {
slice::from_raw_parts(&cmsghdr as *const _ as *const _, mem::size_of::<cmsghdr>())
......@@ -2,42 +2,61 @@
# Maintainer: Isaac Dunham <ibid.ag@gmail.com>
pkgname=py-matplotlib
_pkgname=matplotlib
pkgver=1.5.1
pkgrel=4
pkgver=2.2.3
pkgrel=0
pkgdesc="A Python library for plots"
url="https://matplotlib.org/"
url="https://matplotlib.org"
arch="all"
license="custom"
depends="python2 py-numpy>=1.14.3-r1 python2-tkinter py-dateutil py-parsing py-tz py-cycler"
makedepends="python2-dev gfortran py-numpy-dev freetype-dev libpng-dev tk-dev
py-setuptools"
subpackages="$pkgname-doc $pkgname-tests"
depends="py-numpy py-dateutil py-parsing py-tz py-cycler py-cairo py-kiwisolver"
makedepends="python3-dev python2-dev gfortran py-numpy-dev freetype-dev
libpng-dev tk-dev py-setuptools py2-backports_functools_lru_cache
python2-tkinter python3-tkinter"
checkdepends="pytest xvfb"
subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3
$pkgname-doc"
source="$_pkgname-$pkgver.tar.gz::https://github.com/matplotlib/$_pkgname/archive/v$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"
# matplotlib provides unit tests, but they need to be run post installation :-(
options="!check"
build() {
cd "$builddir"
python2 setup.py build || return 1
python2 setup.py build
python3 setup.py build
}
package() {
cd "$builddir"
mkdir -p "$pkgdir"
}
_py2() {
replaces="$pkgname"
depends="${depends//py-/py2-} python2-tkinter"
_py python2
# Remove documentation, doc-subpkg will use python3 version
rm -rf "$subpkgdir/usr/share"
}
_py3() {
depends="${depends//py-/py3-} python3-tkinter"
_py python3
}
python2 setup.py install --prefix=/usr --root="$pkgdir" || return 1
install -m755 -d "$pkgdir"/usr/share/licenses/custom/$pkgname
install -m644 LICENSE/* "$pkgdir"/usr/share/licenses/custom/$pkgname/
doc() {
mkdir -p "${subpkgdir}/usr"
mv "${pkgdir}/../py3-$_pkgname/usr/share" "$subpkgdir/usr/"
}
tests() {
pkgdesc="$pkgdesc (tests)"
arch="noarch"
depends="$depends py-nose"
local sitepath="$(python2 -c 'import site; print(site.getsitepackages()[0])')/$_pkgname"
_py() {
local python="$1"
pkgdesc="$pkgdesc (for $python)"
cd "$builddir"
mkdir -p "$subpkgdir"$sitepath
mv "$pkgdir"$sitepath/tests "$subpkgdir"$sitepath/
$python setup.py install --prefix=/usr --root="$subpkgdir"
install -m755 -d "$subpkgdir"/usr/share/licenses/$pkgname
install -m644 LICENSE/* "$subpkgdir"/usr/share/licenses/$pkgname/
}
md5sums="b22dc4962f36aab919a7125b3b35953b matplotlib-1.5.1.tar.gz"
sha256sums="64c9f7cce4075d05c2602108ee1795aa6455c2c1d8e4329c95c83465e3806887 matplotlib-1.5.1.tar.gz"
sha512sums="da99fffcb4fb600ed4386ce89e61725768d4209f3bd4ab174e0d8474c24b2736516a4299ceaa0714b276d7d02c3e33e39a6204e014569ec3f6249085b1ba7a0d matplotlib-1.5.1.tar.gz"
sha512sums="d118f5d56e2f578031aba22933c0b3a4423a31a04f50f08cc1aa660186546d09692a9cf401bb5f24cb296f94fbfd8707460728d501ac2bd4a624dfa89e92949b matplotlib-2.2.3.tar.gz"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment