diff options
author | Eric Berquist | 2015-06-17 11:45:27 -0400 |
---|---|---|
committer | Eric Berquist | 2015-06-17 11:45:27 -0400 |
commit | 00cdbc130825e167dce3f24366a9d21786d6d47c (patch) | |
tree | d19c4eb2750c1e4a0c7f444188fef0bd12db05de | |
download | aur-00cdbc130825e167dce3f24366a9d21786d6d47c.tar.gz |
Initial import
-rw-r--r-- | .SRCINFO | 22 | ||||
-rw-r--r-- | PKGBUILD | 55 |
2 files changed, 77 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..cd31f592f5fe --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,22 @@ +pkgbase = python-cclib-git + pkgdesc = A library for parsing and interpreting the results of computational chemistry packages. (git version) + pkgver = 1.3.2.r1726.4a8a952 + pkgrel = 1 + url = http://cclib.github.io + arch = any + license = LGPL + makedepends = git + source = git+https://github.com/cclib/cclib + sha256sums = SKIP + +pkgname = python-cclib-git + depends = python + depends = python-numpy + provides = python-cclib + conflicts = python-cclib + +pkgname = python2-cclib-git + depends = python2 + depends = python2-numpy + provides = python2-cclib + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..4764cf128e57 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,55 @@ +# Maintainer: Eric Berquist <eric dot berquist at gmail dot com> + +_name="cclib" +pkgbase="python-${_name}-git" +pkgname=("python-${_name}-git" "python2-${_name}-git") +pkgver=1.3.2.r1726.4a8a952 +pkgrel=1 +pkgdesc="A library for parsing and interpreting the results of computational chemistry packages. (git version)" +arch=("any") +url="http://cclib.github.io" +license=("LGPL") +makedepends=("git") +source=("git+https://github.com/${_name}/${_name}") +sha256sums=('SKIP') + +package_python-cclib-git() { + depends=("python" "python-numpy") + provides=("python-cclib") + conflicts=("python-cclib") + cd "${srcdir}/${_name}" + python setup.py install --root="${pkgdir}" --optimize=1 + find "${pkgdir}" -name "*.pyc" -delete + find "${pkgdir}" -type d -empty -delete +} + +package_python2-cclib-git() { + depends=("python2" "python2-numpy") + provides=("python2-cclib") + conflics=("python2-cclib") + cd "${srcdir}/${_name}" + python2 setup.py install --root="${pkgdir}" --optimize=1 + find "${pkgdir}" -name "*.pyc" -delete + find "${pkgdir}" -type d -empty -delete + # Keep /usr/bin driver scripts, but not the default name. + cd "${pkgdir}/usr/bin" + for i in $(ls); do + mv "${i}" "${i}2" + done +} + +pkgver() { + cd "${srcdir}/${_name}" + _parent_ver=$(git log --tags --simplify-by-decoration --pretty="format:%d" | head -n 1 | cut -d " " -f 3 | tr -d ")" | tr -d v) + _parent_major_ver=$(echo "${_parent_ver}" | cut -d "." -f 1) + _parent_minor_ver=$(echo "${_parent_ver}" | cut -d "." -f 2) + _parent_patch_ver=$(echo "${_parent_ver}" | cut -d "." -f 3) + # Don't use the patch version of the parent tag. + _git_patch_ver=$((_parent_patch_ver+1)) + printf "%s.%s.%s.r%s.%s" \ + "${_parent_major_ver}" \ + "${_parent_minor_ver}" \ + "${_git_patch_ver}" \ + "$(git rev-list --count HEAD)" \ + "$(git rev-parse --short HEAD)" +} |