aboutsummaryrefslogtreecommitdiffstats
path: root/solar-python
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2016-06-23 19:49:46 +0200
committerMattias Andrée <maandree@kth.se>2016-06-23 19:49:46 +0200
commitea6115bb9d50849f32a6a51c0cf8460b20710663 (patch)
treeed9055fd5bec768d3df08fcdbe81fe2c45f96e4f /solar-python
parentUpdate metar (diff)
downloadaur-packages-ea6115bb9d50849f32a6a51c0cf8460b20710663.tar.gz
aur-packages-ea6115bb9d50849f32a6a51c0cf8460b20710663.tar.bz2
aur-packages-ea6115bb9d50849f32a6a51c0cf8460b20710663.tar.xz
Add solar-python
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'solar-python')
-rw-r--r--solar-python/PKGBUILD27
-rw-r--r--solar-python/solar-python.install20
l---------solar-python/upload1
3 files changed, 48 insertions, 0 deletions
diff --git a/solar-python/PKGBUILD b/solar-python/PKGBUILD
new file mode 100644
index 0000000..39adbc7
--- /dev/null
+++ b/solar-python/PKGBUILD
@@ -0,0 +1,27 @@
+# Maintainer: Mattias Andrée <`base64 -d`(bWFhbmRyZWUK)@member.fsf.org>
+
+pkgname=solar-python
+pkgver=2.4
+pkgrel=1
+pkgdesc="Solar data calculation and prediction library for Python"
+arch=(any)
+url="https://github.com/maandree/solar-python"
+license=('AGPL3')
+depends=(python3)
+makedepends=(make coreutils python3 texinfo)
+install=solar-python.install
+source=($url/archive/$pkgver.tar.gz)
+sha256sums=(fda9576e26d4e46989d36cfba0208bf7167a063c4f5b62cf9c7f9a0bfacfb740)
+
+
+build() {
+ cd "$srcdir/$pkgname-$pkgver"
+ make PREFIX=/usr PY_MAJOR="$(python -V | cut -d ' ' -f 2 | cut -d . -f 1)" PY_MINOR="$(python -V | cut -d ' ' -f 2 | cut -d . -f 2)"
+}
+
+
+package() {
+ cd "$srcdir/$pkgname-$pkgver"
+ make PREFIX=/usr PY_MAJOR="$(python -V | cut -d ' ' -f 2 | cut -d . -f 1)" PY_MINOR="$(python -V | cut -d ' ' -f 2 | cut -d . -f 2)" install DESTDIR="$pkgdir"
+}
+
diff --git a/solar-python/solar-python.install b/solar-python/solar-python.install
new file mode 100644
index 0000000..0227091
--- /dev/null
+++ b/solar-python/solar-python.install
@@ -0,0 +1,20 @@
+_file="solar-python"
+
+infodir="usr/share/info"
+file="${_file}.info"
+
+
+post_install() {
+ [[ -x "usr/bin/install-info" ]] || return 0
+ install-info -- "${infodir}/${file}" "${infodir}/dir" 2> /dev/null
+}
+
+post_upgrade() {
+ post_install "$1"
+}
+
+pre_remove() {
+ [[ -x "usr/bin/install-info" ]] || return 0
+ install-info --delete -- "${infodir}/${file}" "${infodir}/dir" 2> /dev/null
+}
+
diff --git a/solar-python/upload b/solar-python/upload
new file mode 120000
index 0000000..1e7a8be
--- /dev/null
+++ b/solar-python/upload
@@ -0,0 +1 @@
+../upload \ No newline at end of file