wok view scim/receipt @ rev 24347

Up expat (2.4.4)
author Pascal Bellard <pascal.bellard@slitaz.org>
date Wed Feb 02 09:41:22 2022 +0000 (2022-02-02)
parents 7bee98929640
children 0262035dc1e7
line source
1 # SliTaz package receipt.
3 PACKAGE="scim"
4 VERSION="1.4.18"
5 CATEGORY="utilities"
6 SHORT_DESC="Smart Common Input Method (SCIM)."
7 MAINTAINER="rocky@slitaz.org"
8 LICENSE="LGPL2.1"
9 WEB_SITE="https://www.scim-im.org/"
11 TARBALL="$PACKAGE-$VERSION.tar.gz"
12 WGET_URL="https://github.com/scim-im/$PACKAGE/archive/$VERSION.tar.gz"
14 DEPENDS="gcc-lib-base gtk+"
15 BUILD_DEPENDS="gtk+-dev libtool xz gettext-tools"
16 CONFIG_FILES="/etc/scim/config /etc/scim/global"
18 current_version()
19 {
20 wget -O - ${WGET_URL%/arch*}/releases 2>/dev/null | \
21 sed '/archive.*tar/!d;s|.*/\(.*\).tar.*|\1|;q'
22 }
24 # Rules to configure and make the package.
25 compile_rules()
26 {
27 # while read file; do
28 # [ -f done.$file ] && continue
29 # echo "Apply $file..."
30 # patch -p1 -i $stuff/$file || return 1
31 # touch done.$file
32 # done <<EOT
33 #scim-glibc-2.10.patch
34 #EOT
36 ./bootstrap &&
37 ./configure \
38 --prefix=/usr \
39 --sysconfdir=/etc \
40 --with-x \
41 --with-gtk-im-module-dir=$(ls -d /usr/lib/gtk-2*/2*/immodules/) \
42 --mandir=/usr/share/man \
43 --infodir=/usr/share/info \
44 $CONFIGURE_ARGS 2>&1 | grep -v po/POTFILES &&
45 make $MAKEFLAGS -j 1 &&
46 make DESTDIR=$DESTDIR install
47 }
49 # Rules to gen a SliTaz package suitable for Tazpkg.
50 genpkg_rules()
51 {
52 mkdir -p $fs/usr/share/pixmaps
54 cp -a $install/etc $fs/
55 cp -a $install/usr/bin $fs/usr
56 cp -a $install/usr/lib $fs/usr
57 cp -a $install/usr/share/scim $fs/usr/share
58 cp $install/usr/share/pixmaps/scim-setup.png \
59 $fs/usr/share/pixmaps
61 find $fs/usr/lib -name '*.la' -exec rm {} \;
62 find $fs/usr/lib -name '*.a' -exec rm {} \;
63 rm -rf $fs/usr/lib/pkgconfig
65 chmod +x $fs/usr/bin/scim-setup
66 }
68 post_install()
69 {
70 newline
71 action 'Updating gtk.immodules... '
72 chroot "$1/" /usr/bin/gtk-query-immodules-2.0 > $1/etc/gtk-2.0/gtk.immodules
73 status
75 cat <<EOT
76 In order to start scim and use chinese after boot time,
77 add the following code to your autostart.sh(openbox):
78 ------------
79 export XMODIFIERS=@im=SCIM
80 export XIM="scim"
81 export XINPUT="xim"
82 export XIM_PROGRAM="scim -d"
83 export GTK_IM_MODULE=scim
84 export QT_IM_MODULE=scim
85 scim -d &
86 ------------
87 EOT
88 }
90 post_remove()
91 {
92 /usr/bin/gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules
93 }