summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 597dcf2d50e31fb47d81265ba849ddefbaec7450 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Maintainer: Christoph Robbert <chrobbert@gmail.com>
# Contributor: Alexander Rødseth <rodseth@gmail.com>
# Contributor: Brad Fanella <bradfanella@archlinux.us>
# Contributor: jrutila
# Contributor: grimi <grimi@poczta.fm>
# Contributor: jht <stefano@inventati.org>

pkgname=wxglade
pkgver=0.9.3
pkgrel=1
pkgdesc='GUI designer for wxWidgets that can generate Python, C++, Perl, Lisp and XRC code'
arch=('any')
license=('MIT')
url='http://wxglade.sourceforge.net/'
depends=('python2' 'wxpython' 'desktop-file-utils')
makedepends=('gendesk' 'imagemagick')
install="$pkgname.install"
source=("https://github.com/wxGlade/wxGlade/archive/v$pkgver.tar.gz"
        'wxglade.sh')
sha256sums=('2f2cfc5aa7d9904cfb38a404c2c01945c36d8fcf856eb705e3fbccd6c566038f'
            '4549c2034453475f06265fa1c845db3b4c006ab9b17d0386aecd2a276577a6e0')

prepare() {
  gendesk -f -n --pkgname "$pkgname" --pkgdesc "$pkgdesc" --exec 'wxglade %F' \
    --name 'wxGlade' --mimetypes 'application/x-wxg'
  convert "wxGlade-$pkgver/icons/icon.xpm" "$pkgname.png"
}

package() {
  mkdir -p "$pkgdir/usr/bin" "$pkgdir/usr/share/doc/wxGlade"

  # TODO: Update man pages upstream
  #install -Dm644 "wxGlade-$pkgver/docs/man/$pkgname.1" \
  #  "$pkgdir/usr/share/man/man1/$pkgname.1"
  rm -rf "wxGlade-$pkgver/docs/man"
  mv "wxGlade-$pkgver/docs/"* "$pkgdir/usr/share/doc/wxGlade/"
  cp -R "wxGlade-$pkgver/" "$pkgdir/usr/share/wxGlade/"

  python2 -m compileall "$pkgdir/usr/share/wxGlade/"

  install -Dm755 "$srcdir/$pkgname.sh" "$pkgdir/usr/bin/$pkgname"
  install -Dm644 "wxGlade-$pkgver/LICENSE.txt" \
    "$pkgdir/usr/share/licenses/$pkgname/LICENSE.txt"
  install -Dm644 "$pkgname.png" \
    "$pkgdir/usr/share/pixmaps/$pkgname.png"
  install -Dm644 "$pkgname.desktop" \
    "$pkgdir/usr/share/applications/$pkgname.desktop"
}

# vim:set ts=2 sw=2 et: