Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | DESCRIPTION = "A multilingual user input method library" |
| 2 | HOMEPAGE = "http://uim.freedesktop.org/" |
| 3 | LICENSE = "BSD-3-Clause & LGPLv2+" |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 4 | LIC_FILES_CHKSUM = "file://COPYING;md5=32463fd29aa303fb2360faeeae17256b" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 5 | SECTION = "inputmethods" |
| 6 | |
Brad Bishop | 757e94a | 2018-09-07 18:58:51 +0000 | [diff] [blame] | 7 | SRC_URI = "https://github.com/uim/uim/releases/download/uim-${PV}/uim-${PV}.tar.bz2" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 8 | |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 9 | SRC_URI_append_class-target = " file://uim-module-manager.patch \ |
| 10 | file://0001-fix-bug-for-cross-compile.patch \ |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 11 | file://0001-Add-support-for-aarch64.patch \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 12 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 13 | SRC_URI[md5sum] = "ecea4c597bab1fd4ba98ea84edcece59" |
| 14 | SRC_URI[sha256sum] = "7b1ea803c73f3478917166f04f67cce6e45ad7ea5ab6df99b948c17eb1cb235f" |
| 15 | |
| 16 | DEPENDS = "anthy fontconfig libxft libxt glib-2.0 ncurses intltool" |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 17 | DEPENDS_append_class-target = " intltool-native gtk+ gtk+3 uim-native takao-fonts" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 18 | |
| 19 | RDEPENDS_uim = "libuim0 libedit" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 20 | RDEPENDS_uim-anthy = "takao-fonts anthy libanthy0" |
| 21 | RDEPENDS_uim-anthy_append_libc-glibc = " glibc-utils glibc-gconv-euc-jp" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 22 | |
| 23 | LEAD_SONAME = "libuim.so.1" |
| 24 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 25 | inherit distro_features_check autotools pkgconfig gettext qemu gtk-immodules-cache |
| 26 | |
| 27 | REQUIRED_DISTRO_FEATURES = "x11" |
| 28 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 29 | GTKIMMODULES_PACKAGES = "uim-gtk2.0 uim-gtk3" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 30 | |
| 31 | EXTRA_OECONF += "--disable-emacs \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 32 | --without-scim \ |
| 33 | --without-m17nlib \ |
| 34 | --without-prime \ |
| 35 | --without-canna \ |
| 36 | --without-mana \ |
| 37 | --without-eb \ |
| 38 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 39 | |
| 40 | CONFIGUREOPTS_remove_class-target = "--disable-silent-rules" |
| 41 | |
| 42 | #Because m4 file's find maxdepth=2, so copy the m4 files of the deep depth. |
| 43 | do_configure_prepend () { |
| 44 | cp ${S}/sigscheme/m4/* ${S}/m4/ |
| 45 | } |
| 46 | |
| 47 | do_install_append() { |
| 48 | rm -rf ${D}/${datadir}/applications |
| 49 | } |
| 50 | |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 51 | PACKAGES =+ "uim-xim uim-utils uim-skk uim-gtk2.0 uim-gtk3 uim-fep uim-anthy uim-common libuim0 libuim-dev" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 52 | |
| 53 | FILES_${PN} = "${bindir}/uim-help \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 54 | ${libdir}/uim/plugin/libuim-* \ |
| 55 | ${libdir}/libuim-scm* \ |
| 56 | ${libdir}/libgcroots* \ |
| 57 | ${libdir}/uim/plugin/libuim-* \ |
| 58 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 59 | |
| 60 | FILES_libuim0 = "${libdir}/uim/plugin/libuim-custom-enabler.* \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 61 | ${libdir}/libuim-custom.so.* \ |
| 62 | ${datadir}/locale/ja/LC_MESSAGES/uim.mo \ |
| 63 | ${datadir}/locale/fr/LC_MESSAGES/uim.mo \ |
| 64 | ${datadir}/locale/ko/LC_MESSAGES/uim.mo \ |
| 65 | ${libdir}/libuim.so.* \ |
| 66 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 67 | FILES_libuim-dev = "${libdir}/libuim*.a \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 68 | ${libdir}/libuim*.la \ |
| 69 | ${libdir}/libuim*.so \ |
| 70 | ${includedir}/uim \ |
| 71 | ${libdir}/pkgconfig/uim.pc \ |
| 72 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 73 | FILES_uim-anthy = "${libdir}/uim/plugin/libuim-anthy.* \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 74 | ${datadir}/uim/anthy*.scm \ |
| 75 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 76 | FILES_${PN}-dbg += "${libdir}/*/*/*/.debug ${libdir}/*/*/.debug" |
| 77 | FILES_${PN}-dev += "${libdir}/uim/plugin/*.la" |
| 78 | |
| 79 | FILES_uim-utils = "${bindir}/uim-sh \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 80 | ${bindir}/uim-module-manager \ |
| 81 | ${libexecdir}/uim-helper-server \ |
| 82 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 83 | FILES_uim-xim = "${bindir}/uim-xim \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 84 | ${libexecdir}/uim-candwin-*gtk \ |
| 85 | ${libexecdir}/uim-candwin-*gtk3 \ |
| 86 | ${datadir}/man/man1/uim-xim.1 \ |
| 87 | ${sysconfdir}/X11/xinit/xinput.d/uim* \ |
| 88 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 89 | FILES_uim-common = "${datadir}/uim/pixmaps/*.png \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 90 | ${datadir}/uim \ |
| 91 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 92 | FILES_uim-fep = "${bindir}/uim-fep*" |
| 93 | |
| 94 | FILES_uim-gtk2.0 = "${libdir}/gtk-2.0 \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 95 | ${bindir}/uim-toolbar-gtk \ |
| 96 | ${bindir}/uim-toolbar-gtk-systray \ |
| 97 | ${bindir}/uim-*-gtk \ |
| 98 | ${bindir}/uim-input-pad-ja \ |
| 99 | ${libdir}/uim/uim-*-gtk \ |
| 100 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 101 | FILES_uim-gtk3 = "${libdir}/gtk-3.0 \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 102 | ${bindir}/uim-toolbar-gtk3 \ |
| 103 | ${bindir}/uim-toolbar-gtk3-systray \ |
| 104 | ${bindir}/uim-*-gtk3 \ |
| 105 | ${libdir}/uim/uim-*-gtk3 \ |
| 106 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 107 | FILES_uim-skk = "${libdir}/uim/plugin/libuim-skk.* \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 108 | ${datadir}/uim/skk*.scm \ |
| 109 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 110 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 111 | PACKAGE_WRITE_DEPS += "qemu-native" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 112 | pkg_postinst_uim-anthy() { |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 113 | if test -n "$D"; then |
| 114 | ${@qemu_run_binary(d, '$D', '${bindir}/uim-module-manager')} --register anthy --path $D${datadir}/uim |
| 115 | else |
| 116 | uim-module-manager --register anthy --path ${datadir}/uim |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 117 | fi |
| 118 | } |
| 119 | |
| 120 | pkg_prerm_uim-anthy() { |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 121 | if test -n "$D"; then |
| 122 | ${@qemu_run_binary(d, '$D', '${bindir}/uim-module-manager')} --path $D${datadir}/uim --unregister anthy |
| 123 | else |
| 124 | uim-module-manager --path ${datadir}/uim --unregister anthy |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 125 | fi |
| 126 | } |
| 127 | |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 128 | pkg_postinst_uim-skk() { |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 129 | if test -n "$D"; then |
| 130 | ${@qemu_run_binary(d, '$D', '${bindir}/uim-module-manager')} --register skk --path $D${datadir}/uim |
| 131 | else |
| 132 | uim-module-manager --register skk --path ${datadir}/uim |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 133 | fi |
| 134 | } |
| 135 | |
| 136 | pkg_postrm_uim-skk() { |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 137 | if test -n "$D"; then |
| 138 | ${@qemu_run_binary(d, '$D', '${bindir}/uim-module-manager')} --path $D${datadir}/uim --unregister skk |
| 139 | else |
| 140 | uim-module-manager --path ${datadir}/uim --unregister skk |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 141 | fi |
| 142 | } |
| 143 | |
| 144 | BBCLASSEXTEND = "native" |