summaryrefslogtreecommitdiff
path: root/pcr
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2014-02-02 11:04:58 -0500
committerLuke Shumaker <LukeShu@sbcglobal.net>2014-02-02 16:22:56 -0500
commit9ba2ac0cd2a6f3e6af1a0f01f50f29a8009e9145 (patch)
tree0e443f5b246df9afd4f13c447deb0175568b64d8 /pcr
parent7ed3cba3fbcfcd90def8d7d39c58d29ae6aa07b9 (diff)
add pcr/pumpa
Diffstat (limited to 'pcr')
-rw-r--r--pcr/pumpa/PKGBUILD84
-rw-r--r--pcr/pumpa/pumpa.install11
2 files changed, 95 insertions, 0 deletions
diff --git a/pcr/pumpa/PKGBUILD b/pcr/pumpa/PKGBUILD
new file mode 100644
index 000000000..a5f6ee21c
--- /dev/null
+++ b/pcr/pumpa/PKGBUILD
@@ -0,0 +1,84 @@
+# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net>
+# Maintainer (AUR): speps <speps dot aur dot archlinux dot org>
+
+pkgbase=pumpa
+pkgname=(pumpa-qt4 pumpa-qt5 pumpa-l10n)
+pkgver=0.8.2
+pkgdesc="A simple pump.io client"
+url="http://sjoberg.fi/software/pumpa.html"
+license=('GPL3')
+
+pkgrel=1
+arch=('i686' 'x86_64')
+makedepends=('aspell' 'qjson' 'qt5-base')
+source=("http://gitorious.org/pumpa/pumpa/archive/v$pkgver.tar.gz")
+md5sums=('cb1a75b1365063198bd02b76e3fce2c5')
+
+prepare() {
+ cd $pkgbase-$pkgbase
+
+ # icon path fix
+ sed -i 's|/.*/||' $pkgbase.desktop
+}
+
+build() {
+ cd "$srcdir"/$pkgbase-$pkgbase
+ mkdir build-pumpa-qt4
+ cd build-pumpa-qt4
+ qmake-qt4 ..
+ make
+
+ cd "$srcdir"/$pkgbase-$pkgbase
+ mkdir build-pumpa-qt5
+ cd build-pumpa-qt5
+ qmake ..
+ make
+}
+
+package_pumpa-qt4() {
+ pkgdesc+=" (Qt4)"
+ depends+=('pumpa-l10n' 'aspell' 'qjson')
+ install="$pkgbase.install"
+ _package_common Qt4
+}
+
+package_pumpa-qt5() {
+ pkgdesc+=" (Qt5)"
+ depends=('pumpa-l10n' 'aspell' 'qt5-base')
+ install="$pkgbase.install"
+ _package_common Qt5
+}
+
+package_pumpa-l10n() {
+ pkgdesc+=" (localizations)"
+
+ cd $pkgbase-$pkgbase
+ install -d "$pkgdir/usr/share/locale"
+ install -Dm644 translations/*.qm \
+ "$pkgdir/usr/share/locale"
+}
+
+_package_common() {
+ local toolkit=$1
+ cd $pkgbase-$pkgbase
+
+ # bin
+ install -Dm755 build-$pkgname/$pkgbase \
+ "$pkgdir/usr/bin/$pkgname"
+
+ # icon
+ install -Dm644 images/$pkgbase.png \
+ "$pkgdir/usr/share/pixmaps/$pkgname.png"
+
+ # desktop file
+ install -d "$pkgdir/usr/share/applications"
+ sed -e "s|$pkgbase|$pkgname|" -e "s|Pumpa|& ($toolkit)|" \
+ < $pkgbase.desktop \
+ > "$pkgdir/usr/share/applications/$pkgname.desktop"
+
+ # man page
+ install -d "$pkgdir/usr/share/man/man1"
+ sed -e "s|$pkgbase|$pkgname|" -e "s|${pkgbase^^}|${pkgname^^}|" \
+ < docs/$pkgbase.1 \
+ > "$pkgdir/usr/share/man/man1/$pkgname.1"
+}
diff --git a/pcr/pumpa/pumpa.install b/pcr/pumpa/pumpa.install
new file mode 100644
index 000000000..e111ef946
--- /dev/null
+++ b/pcr/pumpa/pumpa.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ post_install
+}