summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 6057895b048e9e79d34e7f4985b0c891cde81ba2 (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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# Maintainer: Vladimir Panteleev <arch-pkg at thecybershadow.net>
# Contributor: noonov <noonov@gmail.com>
# Contributor: Gaetan Bisson <bisson@archlinux.org>
# Contributor: damir <damir@archlinux.org>

_pkgname=uim
pkgname=${_pkgname}-git
pkgver=1.8.8.r50.gd1ac9d93
pkgrel=1
epoch=1
pkgdesc='Multilingual input method library'
url='https://github.com/uim/uim/wiki'
license=('custom:BSD')
arch=('i686' 'x86_64')
depends=('libxft' 'libedit')
makedepends=('git' # for cloning
			 'extra-cmake-modules' 'intltool' 'gettext' # core dependencies
			 'gtk2' 'gtk3' 'qt5-tools' 'plasma-framework' # frontend plugins
			 'anthy' 'm17n-lib' # input method plugins
			 'qt5-x11extras' # platform input context plugin
			 'ruby') # generate functable-r5rs-syntax.c etc.
optdepends=('qt5-x11extras: platform input context plugin'
            'gtk2: immodule and helper applications'
            'gtk3: immodule and helper applications'
            'emacs: uim.el bridge software'
			'm17n-lib: m17n support'
			'anthy: Japanese input method')
provides=('uim')
conflicts=('uim' 'uim-svn')
source=("git+https://github.com/uim/uim.git"
		"git+https://github.com/uim/sigscheme.git"
		"git+https://github.com/uim/libgcroots.git")
sha256sums=('SKIP'
            'SKIP'
            'SKIP')

pkgver() {
  cd "${srcdir}/${_pkgname}"
  git describe --long --tags | sed -r 's/^uim-//;s/([^-]*-g)/r\1/;s/-/./g'
}

prepare() {
  cd "${srcdir}/${_pkgname}"
  git submodule init
  git config submodule.sigscheme.url "${srcdir}/sigscheme"
  git submodule update

  cd "${srcdir}/${_pkgname}/sigscheme"
  git submodule init
  git config submodule.libgcroots.url "${srcdir}/libgcroots"
  git submodule update
}

build() {
  cd "${srcdir}/${_pkgname}/sigscheme"
  ./autogen.sh

  cd "${srcdir}/${_pkgname}/sigscheme/libgcroots"
  ./autogen.sh

  cd "${srcdir}/${_pkgname}"
  ./autogen.sh

  cmd=(./configure
	   --enable-maintainer-mode # necessary for building from Git
	   --prefix=/usr
	   --libexecdir=/usr/lib/uim
	   --with-anthy-utf8
	   --with-qt5-immodule
	   --with-qt5
	  )
  "${cmd[@]}"

  make
}

package() {
  cd "${srcdir}/${_pkgname}"
  make DESTDIR="${pkgdir}" install -j1 # FS#41112
  install -D -m644 COPYING "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
}