Accepting request 81948 from home:stecue
Immodules packaged. FCITX should work in GNOME3 environment now. .spec, .changes file improved. OBS-URL: https://build.opensuse.org/request/show/81948 OBS-URL: https://build.opensuse.org/package/show/M17N/fcitx?expand=0&rev=8
This commit is contained in:
parent
2c6c4bf0ed
commit
ee9a7ea383
62
fcitx-README.suse
Normal file
62
fcitx-README.suse
Normal file
@ -0,0 +1,62 @@
|
|||||||
|
fcitx README for SuSE
|
||||||
|
How to start using fcitx
|
||||||
|
|
||||||
|
English:
|
||||||
|
|
||||||
|
1.openSUSE can start fcitx automatically when your locale is set to en, zh_CN.
|
||||||
|
The setup script is a link in /etc/X11/xim.d/YOUR-LOCALE/30-fcitx which link to /etc/X11/xim.d/fcitx.
|
||||||
|
The number "30" makes fcitx have priority over other input-method (e.g 50-scim or 90-xcin ).
|
||||||
|
If you prefer not using fcitx, mv 30-fcitx to 80-fcitx (for example). Or see 2.
|
||||||
|
|
||||||
|
2.If for some reason can't start fcitx when login Xwindow
|
||||||
|
There is another input-method who has higher priority then fcitx (e.g 10-oxim)
|
||||||
|
You can edit ~/.xim, see ~/.xim.template for more informations.
|
||||||
|
Or edit ~/.profile, add
|
||||||
|
export INPUT_METHOD="fcitx"
|
||||||
|
After installing fcitx, there's a template for fcitx: /usr/share/doc/packages/fcitx/xim.fcitx.suse.template
|
||||||
|
copy this file to ~/.xim, then you can use fcitx next login X.
|
||||||
|
|
||||||
|
3.You want to use your own input-method other than system setting
|
||||||
|
(1)System setting:
|
||||||
|
Edit /etc/sysconfig/language , set INPUT_METHOD="scim-bridge", or whatever you want,Make sure your start-up script is put in /etc/X11/xim.d/ with same name ypu mention.
|
||||||
|
(2)For specific language setting:
|
||||||
|
Link a start-up script in /etc/X11/xim.d/ to your locale with a higher priority (smaller number), eg
|
||||||
|
ln -s /etc/X11/xim.d/scim-bridge /etc/X11/xim.d/zh_CN/20-scim-bridge
|
||||||
|
(3)Personal setting:
|
||||||
|
Edit ~/.profile add
|
||||||
|
export INPUT_METHOD="scim-bridge" or whatever script in /etc/X11/xim.d/
|
||||||
|
or white your own ~/.xim, see ~/.xim.template for more informations.
|
||||||
|
|
||||||
|
4.Bug report or any suggestion to
|
||||||
|
http://code.google.com/p/fcitx/
|
||||||
|
|
||||||
|
|
||||||
|
Chinese:
|
||||||
|
|
||||||
|
1.当您使用的语系是en 或zh_CN时,SuSE 会自动启动fcitx
|
||||||
|
启动的script是/etc/X11/xim.d/YOUR-LOCALE/30-fcitx,这是一个到上层目录fcitx的连结
|
||||||
|
"30"这个数字使他的优先顺序高于90-xcin及50-scim
|
||||||
|
如果您不喜欢这个顺序,修改连结的名称为(例如:80-fcitx),或参考2.
|
||||||
|
|
||||||
|
2.重新登入X后,如果不能用fcitx...可能是:
|
||||||
|
有别的输入法的优先顺序高于fcitx(例如:10-oxim)
|
||||||
|
您可以编辑~/.xim,请参考~/.xim.template
|
||||||
|
安装fcitx后,会有一个范本:/usr/share/doc/packages/fcitx/xim.fcitx.suse.template
|
||||||
|
将这个档案复制到您的~/.xim,当您下次登入X时就可以使用fcitx了
|
||||||
|
或编辑~/.profile,加入
|
||||||
|
export INPUT_METHOD="fcitx"
|
||||||
|
|
||||||
|
3.如果您想要自己选择输入法而非使用系统设定
|
||||||
|
(1)全系统设定:
|
||||||
|
编辑 /etc/sysconfig/language, 设定 INPUT_METHOD="ibus" 或其他你想用的输入法,
|
||||||
|
请注意你的启动程序必须位于 /etc/X11/xim.d/,并和您指定的名称相同
|
||||||
|
(2)针对特定语言:
|
||||||
|
将您的启动程序连结到你的语系中,并前置较高的优先顺序(较小数字),例如
|
||||||
|
ln -s /etc/X11/xim.d/fcitx /etc/X11/xim.d/zh_CN/20-scim-bridge
|
||||||
|
(3)个人设定:
|
||||||
|
编辑 ~/.profile 加入
|
||||||
|
export INPUT_METHOD="fcitx" 或其他在 /etc/X11/xim.d/ 的启动程序
|
||||||
|
或自行编写启动程序 ~/.xim,请参考 ~/.xim.template
|
||||||
|
|
||||||
|
5.臭虫回报或建议请至
|
||||||
|
http://code.google.com/p/fcitx/
|
36
fcitx.changes
Normal file
36
fcitx.changes
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
------------------------------------------------------------------
|
||||||
|
Tue Sep 13 04:01:59 UTC 2011 - stecue@gmail.com
|
||||||
|
|
||||||
|
- im-modules packaged. Thanks to hillwood (hillwood@linuxfans.org)!
|
||||||
|
- xim is still the default method.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Sep 9 15:02:04 UTC 2011 - stecue@gmail.com
|
||||||
|
|
||||||
|
- upstream version 4.1.1
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Sep 7 19:49:14 UTC 2011 - stecue@gmail.com
|
||||||
|
|
||||||
|
- upstream version 4.1.0
|
||||||
|
* support im-module (gtk2, gtk3 and qt), not packaged yet
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Tue Jun 14 00:56:36 UTC 2011 swyear <swyear@gmail.com>
|
||||||
|
- Add start up script, README and template
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Tue May 17 00:00:00 UTC 2011 stecue <stecue@gmail.com>
|
||||||
|
- upstream version 4.0.1.
|
||||||
|
- Add xim dependency for openSUSE 11.4
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Sat Sep 18 00:00:00 UTC 2010 CSSlayer <wengxt@gmail.com>
|
||||||
|
- Make it works with newest
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Fri Jun 11 00:00:00 UTC 2004 xyb <xyb76@sina.com>
|
||||||
|
- Add data/tables.conf
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Mon Feb 2 00:00:00 UTC 2004 xyb <xyb76@sina.com>
|
||||||
|
- Fix spec bug(patch by hamigua).
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
* Thu Jan 15 00:00:00 UTC 2004 xyb <xyb76@sina.com>
|
||||||
|
- skeleton RPM
|
60
fcitx.spec
60
fcitx.spec
@ -1,7 +1,7 @@
|
|||||||
Name: fcitx
|
Name: fcitx
|
||||||
Version: 4.1.1
|
Version: 4.1.1
|
||||||
Release: 1
|
Release: 1
|
||||||
Summary: Free Chinese Input Toy for X (XIM)
|
Summary: Free Chinese Input Toy for X
|
||||||
Packager: hillwood <hillwood@linuxfans.org>
|
Packager: hillwood <hillwood@linuxfans.org>
|
||||||
URL: http://www.fcitx.org/
|
URL: http://www.fcitx.org/
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
@ -9,6 +9,8 @@ License: GPL
|
|||||||
Source: %{name}-%{version}_all.tar.bz2
|
Source: %{name}-%{version}_all.tar.bz2
|
||||||
Source1: xim.d-fcitx
|
Source1: xim.d-fcitx
|
||||||
Source2: xinput-fcitx.conf
|
Source2: xinput-fcitx.conf
|
||||||
|
Source3: fcitx-README.suse
|
||||||
|
Source4: xim.fcitx.suse.template
|
||||||
BuildRequires: cairo-devel
|
BuildRequires: cairo-devel
|
||||||
BuildRequires: pango-devel
|
BuildRequires: pango-devel
|
||||||
%if 0%{?suse_version}
|
%if 0%{?suse_version}
|
||||||
@ -24,7 +26,9 @@ BuildRequires: qt-devel
|
|||||||
BuildRequires: intltool
|
BuildRequires: intltool
|
||||||
BuildRequires: cmake
|
BuildRequires: cmake
|
||||||
BuildRequires: gtk2-devel
|
BuildRequires: gtk2-devel
|
||||||
|
#If you do not use immodule-fcitx, you have to use immodule-fcitx
|
||||||
%if 0%{?suse_version} > 1130
|
%if 0%{?suse_version} > 1130
|
||||||
|
Requires: gtk2-immodule-xim, gtk3-immodule-xim
|
||||||
BuildRequires: gtk3-devel
|
BuildRequires: gtk3-devel
|
||||||
%endif
|
%endif
|
||||||
%if 0%{?fedora} > 14
|
%if 0%{?fedora} > 14
|
||||||
@ -38,7 +42,9 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}
|
|||||||
FCITX is a simplified Chinese input server. It supports Tables,
|
FCITX is a simplified Chinese input server. It supports Tables,
|
||||||
Pinyin and QuWei input method. It's small and fast.
|
Pinyin and QuWei input method. It's small and fast.
|
||||||
|
|
||||||
|
Since version 4.1, FCITX itself can be use as an im-module. XIM
|
||||||
|
can still be used but not necessary.
|
||||||
|
|
||||||
%package devel
|
%package devel
|
||||||
Summary: Development files for %{name}
|
Summary: Development files for %{name}
|
||||||
Group: Development/Libraries
|
Group: Development/Libraries
|
||||||
@ -51,7 +57,8 @@ The %{name}-devel package includes the header files for the %{name} package.
|
|||||||
Summary: Gtk2 IM Module for %{name}
|
Summary: Gtk2 IM Module for %{name}
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
Requires: %{name} = %{version}-%{release}
|
Requires: %{name} = %{version}-%{release}
|
||||||
Requires: gtk2-immodule-xim
|
#XIM is not necessary if using immodule-fcitx.
|
||||||
|
#Requires: gtk2-immodule-xim
|
||||||
|
|
||||||
%description gtk2
|
%description gtk2
|
||||||
This package contains %{name} im module for gtk2
|
This package contains %{name} im module for gtk2
|
||||||
@ -61,7 +68,8 @@ This package contains %{name} im module for gtk2
|
|||||||
Summary: Gtk3 IM Module for %{name}
|
Summary: Gtk3 IM Module for %{name}
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
Requires: %{name} = %{version}-%{release}
|
Requires: %{name} = %{version}-%{release}
|
||||||
Requires: gtk3-immodule-xim
|
#XIM is not necessary if using immodule-fcitx.
|
||||||
|
#Requires: gtk3-immodule-xim
|
||||||
|
|
||||||
%description gtk3
|
%description gtk3
|
||||||
This package contains %{name} im module for gtk3
|
This package contains %{name} im module for gtk3
|
||||||
@ -97,12 +105,14 @@ cd build
|
|||||||
|
|
||||||
%if 0%{?suse_version}
|
%if 0%{?suse_version}
|
||||||
%if 0%{?suse_version} < 1140
|
%if 0%{?suse_version} < 1140
|
||||||
cmake .. -DENABLE_GTK3_IM_MODULE=off \
|
cmake .. -DENABLE_GTK2_IM_MODULE=On \
|
||||||
|
-DENABLE_GTK3_IM_MODULE=Off \
|
||||||
-DENABLE_QT_IM_MODULE=On \
|
-DENABLE_QT_IM_MODULE=On \
|
||||||
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
||||||
-DLIB_INSTALL_DIR=%{_libdir}
|
-DLIB_INSTALL_DIR=%{_libdir}
|
||||||
%else
|
%else
|
||||||
cmake .. -DENABLE_GTK3_IM_MODULE=On \
|
cmake .. -DENABLE_GTK2_IM_MODULE=On \
|
||||||
|
-DENABLE_GTK3_IM_MODULE=On \
|
||||||
-DENABLE_QT_IM_MODULE=On \
|
-DENABLE_QT_IM_MODULE=On \
|
||||||
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
|
||||||
-DLIB_INSTALL_DIR=%{_libdir}
|
-DLIB_INSTALL_DIR=%{_libdir}
|
||||||
@ -137,14 +147,14 @@ cmake .. -DENABLE_GTK3_IM_MODULE=off \
|
|||||||
make
|
make
|
||||||
|
|
||||||
%install
|
%install
|
||||||
rm -rf $RPM_BUILD_ROOT
|
#rm -rf $RPM_BUILD_ROOT
|
||||||
|
|
||||||
cd build
|
cd build
|
||||||
make DESTDIR=$RPM_BUILD_ROOT install
|
make DESTDIR=$RPM_BUILD_ROOT install
|
||||||
|
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
rm $RPM_BUILD_ROOT/usr/share/doc/ -r
|
#rm $RPM_BUILD_ROOT/usr/share/doc/ -r
|
||||||
|
|
||||||
%if 0%{?suse_version}
|
%if 0%{?suse_version}
|
||||||
%suse_update_desktop_file fcitx Utility DesktopUtility
|
%suse_update_desktop_file fcitx Utility DesktopUtility
|
||||||
@ -152,13 +162,27 @@ rm $RPM_BUILD_ROOT/usr/share/doc/ -r
|
|||||||
%suse_update_desktop_file fcitx-configtool System SystemSetup
|
%suse_update_desktop_file fcitx-configtool System SystemSetup
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/X11/xim.d/
|
mkdir -p $RPM_BUILD_ROOT/etc/X11/xim.d/
|
||||||
install -m 644 $RPM_SOURCE_DIR/xim.d-fcitx $RPM_BUILD_ROOT/etc/X11/xim.d/fcitx
|
install -m 644 $RPM_SOURCE_DIR/xim.d-fcitx $RPM_BUILD_ROOT/etc/X11/xim.d/fcitx
|
||||||
|
|
||||||
|
rm -f $RPM_BUILD_ROOT%{_libdir}/libfcitx-config.la
|
||||||
|
|
||||||
|
pushd $RPM_BUILD_ROOT/etc/X11/xim.d/
|
||||||
|
for lang in en zh_CN ; do
|
||||||
|
mkdir $lang
|
||||||
|
pushd $lang
|
||||||
|
ln -s ../fcitx 30-fcitx
|
||||||
|
popd
|
||||||
|
done
|
||||||
|
popd
|
||||||
|
|
||||||
%else
|
%else
|
||||||
mkdir -p $RPM_BUILD_ROOT/etc/X11/xinit/xinput.d/
|
mkdir -p $RPM_BUILD_ROOT/etc/X11/xinit/xinput.d/
|
||||||
install -m 644 $RPM_SOURCE_DIR/xinput-fcitx.conf $RPM_BUILD_ROOT/etc/X11/xinit/xinput.d/fcitx.conf
|
install -m 644 $RPM_SOURCE_DIR/xinput-fcitx.conf $RPM_BUILD_ROOT/etc/X11/xinit/xinput.d/fcitx.conf
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%find_lang %{name}
|
%find_lang %{name}
|
||||||
|
|
||||||
|
#%fdupes -s %{buildroot}
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
[ ${RPM_BUILD_ROOT} != "/" ] && rm -rf ${RPM_BUILD_ROOT}
|
[ ${RPM_BUILD_ROOT} != "/" ] && rm -rf ${RPM_BUILD_ROOT}
|
||||||
|
|
||||||
@ -197,7 +221,7 @@ touch var/adm/SuSEconfig/run-gtk
|
|||||||
%{_datadir}/%{name}/data/*
|
%{_datadir}/%{name}/data/*
|
||||||
%{_datadir}/%{name}/pinyin/*
|
%{_datadir}/%{name}/pinyin/*
|
||||||
%{_datadir}/%{name}/table/*
|
%{_datadir}/%{name}/table/*
|
||||||
#%{_datadir}/doc/%{name}/
|
%{_datadir}/doc/%{name}/
|
||||||
%{_datadir}/applications/*.desktop
|
%{_datadir}/applications/*.desktop
|
||||||
%{_datadir}/icons/*
|
%{_datadir}/icons/*
|
||||||
%{_mandir}/man1/*.gz
|
%{_mandir}/man1/*.gz
|
||||||
@ -223,6 +247,8 @@ touch var/adm/SuSEconfig/run-gtk
|
|||||||
%{_datadir}/%{name}/skin/classic
|
%{_datadir}/%{name}/skin/classic
|
||||||
%if 0%{?suse_version}
|
%if 0%{?suse_version}
|
||||||
%dir /etc/X11/xim.d
|
%dir /etc/X11/xim.d
|
||||||
|
%dir /etc/X11/xim.d/en
|
||||||
|
%dir /etc/X11/xim.d/zh_CN
|
||||||
/etc/X11/xim.d/*
|
/etc/X11/xim.d/*
|
||||||
%else
|
%else
|
||||||
%dir /etc/X11/xinit/xinput.d
|
%dir /etc/X11/xinit/xinput.d
|
||||||
@ -261,17 +287,3 @@ touch var/adm/SuSEconfig/run-gtk
|
|||||||
%{_libdir}/qt4/*
|
%{_libdir}/qt4/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Sat Sep 10 2011 hillwood <hillwood@linuxfans.org>
|
|
||||||
- add gtk2-immodule-xim and gtk3-immodule-xim require
|
|
||||||
|
|
||||||
* Fri Sep 9 2011 hillwood <hillwood@linuxfans.org>
|
|
||||||
- update to 4.1.1
|
|
||||||
|
|
||||||
* Mon Sep 5 2011 hillwood <hillwood@linuxfans.org>
|
|
||||||
- update to 4.1.0.
|
|
||||||
|
|
||||||
* Thu May 17 2011 hillwood <hillwood@linuxfans.org>
|
|
||||||
- add gtk-immodule-xim require
|
|
||||||
|
|
||||||
* Mon Mar 14 2011 hillwood <hillwood@linuxfans.org>
|
|
||||||
- first package for 4.0.1
|
|
||||||
|
22
xim.fcitx.suse.template
Normal file
22
xim.fcitx.suse.template
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#~/.xim template for users to set fcitx as default input method
|
||||||
|
#copy this file to ~/.xim
|
||||||
|
#logout and login again, that's all
|
||||||
|
#for more infomations, see ~/.xim.template
|
||||||
|
|
||||||
|
#if any program can't input Chinese, try export LC_CTYPE=zh_CN.UTF-8, e.g
|
||||||
|
|
||||||
|
#export LC_CTYPE=zh_CN.UTF-8
|
||||||
|
export XMODIFIERS="@im=fcitx"
|
||||||
|
export GTK_IM_MODULE=xim
|
||||||
|
export QT_IM_SWITCHER=imsw-multi
|
||||||
|
export QT_IM_MODULE=xim
|
||||||
|
fcitx -d
|
||||||
|
|
||||||
|
## Note for FCITX version >= 4.1
|
||||||
|
#Since FCITX 4.1, you can use fcitx itself (besides xim) as the immodule,so the following code might work better (fcitx-gtk2/3, fcitx-qt must be installed), especially when you are using gnome3.
|
||||||
|
|
||||||
|
#export XMODIFIERS="@im=fcitx"
|
||||||
|
#export GTK_IM_MODULE=fcitx
|
||||||
|
#export QT_IM_MODULE=fcitx
|
||||||
|
#fcitx -d
|
||||||
|
#
|
Loading…
Reference in New Issue
Block a user