summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorUniversebenzene2019-02-25 12:23:59 +0800
committerUniversebenzene2019-02-25 12:23:59 +0800
commitb53381ba192256fa83a373f34d1e6c2f455fd272 (patch)
tree420e712f90281dbd57a9e86977259dcf210a7341
parentfcdca5a26275c979674637d608272e3ea078897b (diff)
downloadaur-b53381ba192256fa83a373f34d1e6c2f455fd272.tar.gz
Add contional before python2 testing
-rw-r--r--.SRCINFO7
-rw-r--r--PKGBUILD17
-rw-r--r--python2-pydl.install5
3 files changed, 21 insertions, 8 deletions
diff --git a/.SRCINFO b/.SRCINFO
index fe5640aa505b..7ddc0ff292f9 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,5 +1,5 @@
# Generated by mksrcinfo v8
-# Sat Feb 23 08:05:05 UTC 2019
+# Mon Feb 25 04:18:49 UTC 2019
pkgbase = python-pydl
pkgdesc = Python replacements for functions that are part of the IDL built-in library or part of astronomical IDL libraries
pkgver = 0.7.0
@@ -19,7 +19,9 @@ pkgbase = python-pydl
makedepends = python2-astropy-helpers
makedepends = python-sphinx-astropy
source = https://files.pythonhosted.org/packages/source/p/pydl/pydl-0.7.0.tar.gz
+ source = python2-pydl.install
md5sums = 0bf0921aef8f5acbf192ac5c49f0d46c
+ md5sums = 49781cc7f77b9620ebd1252f17c0aa9e
pkgname = python-pydl
depends = python
@@ -29,10 +31,11 @@ pkgname = python-pydl
optdepends = python-pydl-doc: Documentation for PyDL
pkgname = python2-pydl
+ install = python2-pydl.install
depends = python2
depends = python2-astropy
depends = python2-matplotlib
- optdepends = python2-pytest: For testing
+ optdepends = python2-pytest32: For testing
optdepends = python-pydl-doc: Documentation for PyDL
pkgname = python-pydl-doc
diff --git a/PKGBUILD b/PKGBUILD
index ee3b0e106092..dd72723ef67a 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -10,8 +10,10 @@ url="http://pydl.readthedocs.io/"
license=('BSD')
makedepends=('python-setuptools' 'python-setuptools' 'python-astropy' 'python-astropy-helpers' 'python2-astropy-helpers' 'python-sphinx-astropy')
checkdepends=('python-pytest-astropy' 'python2-pytest32' 'python2-matplotlib' 'python2-astropy')
-source=("https://files.pythonhosted.org/packages/source/${_pyname:0:1}/${_pyname}/${_pyname}-${pkgver}.tar.gz")
-md5sums=('0bf0921aef8f5acbf192ac5c49f0d46c')
+source=("https://files.pythonhosted.org/packages/source/${_pyname:0:1}/${_pyname}/${_pyname}-${pkgver}.tar.gz"
+ "python2-${_pyname}.install")
+md5sums=('0bf0921aef8f5acbf192ac5c49f0d46c'
+ '49781cc7f77b9620ebd1252f17c0aa9e')
prepare() {
cd ${srcdir}/${_pyname}-${pkgver}
@@ -38,15 +40,18 @@ check() {
cd ${srcdir}/${_pyname}-${pkgver}
python setup.py test
- msg "Checking Python2"
- cd ${srcdir}/${_pyname}-${pkgver}-py2
- python2 setup.py test
+ if [ -z $(pacman -Qsq python2-pytest-cov) ]; then
+ msg "Checking Python2"
+ cd ${srcdir}/${_pyname}-${pkgver}-py2
+ python2 setup.py test
+ fi
}
package_python2-pydl() {
depends=('python2' 'python2-astropy' 'python2-matplotlib')
- optdepends=('python2-pytest: For testing'
+ optdepends=('python2-pytest32: For testing'
'python-pydl-doc: Documentation for PyDL')
+ install=python2-${_pyname}.install
cd ${srcdir}/${_pyname}-${pkgver}
install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}/"
diff --git a/python2-pydl.install b/python2-pydl.install
new file mode 100644
index 000000000000..22bee3e3b28d
--- /dev/null
+++ b/python2-pydl.install
@@ -0,0 +1,5 @@
+post_install() {
+ echo "
+ ==> If you want to run the testing for python2 version of PyDL, you need to remove the python2-pytest-cov package first.
+ "
+}