summaryrefslogtreecommitdiff
path: root/extra/fcitx/PKGBUILD
blob: 02dfbebc0f33a147e46b047951947b66839f862b (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
# $Id: PKGBUILD 153564 2012-03-16 02:38:35Z eric $
# Maintainer: Andrea Scarpino <andrea@archlinux.org>
# Contributor: csslayer <wengxt AT gmail com>

pkgbase=fcitx
pkgname=('fcitx' 'fcitx-gtk2' 'fcitx-gtk3' 'fcitx-qt')
pkgver=4.2.1
pkgrel=1
arch=('i686' 'x86_64')
url="http://code.google.com/p/fcitx/"
license=('GPL')
makedepends=('cmake' 'intltool' 'doxygen' 'gtk2' 'gtk3' 'qt' 'dbus-glib' 'icu')
source=("http://fcitx.googlecode.com/files/${pkgbase}-${pkgver}.tar.xz")
sha1sums=('74ad009cde48fb1efd48f8d2490fa36ddf36d215')

build() {
  cd "${srcdir}"
  mkdir build
  cd build
  cmake ../${pkgbase}-${pkgver} \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DENABLE_OPENCC=OFF \
    -DENABLE_GTK3_IM_MODULE=ON \
    -DENABLE_QT_IM_MODULE=ON
  make
}

package_fcitx() {
  pkgdesc="Free Chinese Input Toy of X - Input Method Server for X window system"
  depends=('dbus-core' 'pango' 'libxinerama' 'gtk-update-icon-cache' \
           'shared-mime-info' 'hicolor-icon-theme' 'desktop-file-utils')
  install=fcitx.install

  cd "${srcdir}"/build
  make DESTDIR="${pkgdir}" install

  rm -r "${pkgdir}"/usr/lib/{gtk-2.0,gtk-3.0,qt}
}

package_fcitx-gtk2() {
  pkgdesc='GTK2 IM Module for fcitx'
  depends=('gtk2' 'dbus-glib' 'fcitx')
  install=fcitx-gtk2.install

  cd "${srcdir}"/build/src/frontend/gtk2
  make DESTDIR="${pkgdir}" install
}

package_fcitx-gtk3() {
  pkgdesc='GTK3 IM Module for fcitx'
  depends=('gtk3' 'dbus-glib' 'fcitx')
  install=fcitx-gtk3.install

  cd "${srcdir}"/build/src/frontend/gtk3
  make DESTDIR="${pkgdir}" install
}

package_fcitx-qt() {
  pkgdesc='QT IM Module for fcitx'
  depends=('qt' 'icu' 'fcitx')

  cd "${srcdir}"/build/src/frontend/qt
  make DESTDIR="${pkgdir}" install
}