fcitx/fcitx.spec

316 lines
9.4 KiB
RPMSpec
Raw Normal View History

2010-04-18 02:06:31 +00:00
%define _xinputconf %{_sysconfdir}/X11/xinit/xinput.d/fcitx.conf
2011-09-09 09:01:15 +00:00
%{!?gtk2_binary_version: %define gtk2_binary_version %(pkg-config --variable=gtk_binary_version gtk+-2.0)}
%{!?gtk3_binary_version: %define gtk3_binary_version %(pkg-config --variable=gtk_binary_version gtk+-3.0)}
2010-04-18 02:06:31 +00:00
2010-05-16 02:25:09 +00:00
Name: fcitx
2010-07-20 02:56:31 +00:00
Summary: Free Chinese Input Toy for X (XIM)
2011-12-24 17:25:26 +00:00
Version: 4.1.2
2011-12-24 18:29:42 +00:00
Release: 2%{?dist}
2010-07-20 02:56:31 +00:00
License: GPLv2+
2010-11-19 12:47:05 +00:00
Group: User Interface/Desktops
2010-07-20 02:56:31 +00:00
URL: http://code.google.com/p/%{name}/
2011-09-09 09:01:15 +00:00
Source0: http://%{name}.googlecode.com/files/%{name}-%{version}_all.tar.bz2
2010-07-20 02:56:31 +00:00
Source1: xinput-%{name}
2011-09-09 09:33:35 +00:00
BuildRequires: pango-devel, dbus-devel, opencc-devel
BuildRequires: wget, intltool, chrpath, sysconftool, opencc
2011-09-09 09:01:15 +00:00
BuildRequires: cmake, libtool, doxygen, libicu-devel
BuildRequires: qt-devel, gtk3-devel, gtk2-devel, libicu
2011-09-09 11:46:27 +00:00
BuildRequires: libX11-devel, qt-x11, dbus-glib-devel, dbus-x11
BuildRequires: desktop-file-utils
Requires: %{name}-data = %{version}-%{release}
Requires: imsettings
2011-09-09 09:01:15 +00:00
Requires(post): %{_sbindir}/alternatives
2010-04-18 02:06:31 +00:00
Requires(postun): %{_sbindir}/alternatives
2011-08-02 09:29:49 +00:00
Requires: %{name}-libs = %{version}-%{release}
2011-09-10 17:28:40 +00:00
Requires: %{name}-gtk3 = %{version}-%{release}
2011-12-24 17:25:26 +00:00
Requires: %{name}-gtk22 = %{version}-%{release}
2010-04-18 02:06:31 +00:00
%description
2010-11-19 12:47:05 +00:00
FCITX(Free Chinese Input Toy of X) is a collection of Simplified Chinese
2010-04-18 02:06:31 +00:00
input methods for Linux. It supports Pinyin, QuWei and Table-based input
methods. It's small and fast.
%package data
Summary: Data files of FCITX
2010-11-19 12:47:05 +00:00
Group: System Environment/Libraries
2011-09-09 12:14:43 +00:00
BuildArch: noarch
2010-11-19 12:47:05 +00:00
%description data
2011-08-02 09:29:49 +00:00
The %{name}-data package provides shared datas for FCITX.
%package libs
Summary: Shared libraries for FCITX
Group: System Environment/Libraries
%description libs
The %{name}-libs package provides shared libraries for FCITX
2010-11-19 12:47:05 +00:00
%package devel
Summary: Development files for FCITX
Group: Development/Libraries
Requires: %{name}-libs = %{version}-%{release}
Requires: libX11-devel
%description devel
The %{name}-devel package contains libraries and header files necessary for
developing programs using FCITX libraries.
2010-04-18 02:06:31 +00:00
2011-09-09 09:01:15 +00:00
%package table-chinese
Summary: Chinese table of FCITX
Group: System Environment/Libraries
BuildArch: noarch
2011-08-02 09:29:49 +00:00
Requires: %{name} = %{version}-%{release}
2011-09-09 09:01:15 +00:00
%description table-chinese
The %{name}-table-chinese package provides other Chinese table for FCITX.
2011-09-09 09:01:15 +00:00
%package gtk2
Summary: FCITX im module for gtk2
Group: System Environment/Libraries
2011-09-09 09:01:15 +00:00
Requires: %{name} = %{version}-%{release}
Requires: %{name}-libs = %{version}-%{release}
2011-09-09 09:01:15 +00:00
%description gtk2
This package contains ibus im module for gtk2.
2011-09-09 09:01:15 +00:00
%package gtk3
Summary: FCITX im module for gtk3
Group: System Environment/Libraries
2011-09-09 09:01:15 +00:00
Requires: %{name} = %{version}-%{release}
Requires: %{name}-libs = %{version}-%{release}
Requires: imsettings-gnome
2011-09-09 09:01:15 +00:00
%description gtk3
This package contains fcitx im module for gtk3.
2011-09-09 09:01:15 +00:00
%package qt4
Summary: FCITX im module for qt4
Group: System Environment/Libraries
2011-09-09 09:01:15 +00:00
Requires: %{name} = %{version}-%{release}
Requires: %{name}-libs = %{version}-%{release}
2011-09-09 09:01:15 +00:00
%description qt4
This package contains fcitx im module for qt4.
2010-04-18 02:06:31 +00:00
%prep
2010-11-19 12:47:05 +00:00
%setup -q
2010-04-18 02:06:31 +00:00
%build
2011-09-09 09:01:15 +00:00
mkdir -p build
pushd build
cmake .. -DENABLE_GTK3_IM_MODULE=On -DENABLE_QT_IM_MODULE=On -DENABLE_OPENCC=On -DCMAKE_INSTALL_PREFIX=%{_prefix} -DLIB_INSTALL_DIR=%{_libdir}
2010-04-18 02:06:31 +00:00
make %{?_smp_mflags}
%install
2011-09-09 09:01:15 +00:00
pushd build
2010-04-18 02:06:31 +00:00
make install INSTALL="install -p" DESTDIR=%{buildroot}
2010-11-19 12:47:05 +00:00
rm -f %{buildroot}%{_libdir}/*.la
2011-09-09 09:01:15 +00:00
popd
2010-04-18 02:06:31 +00:00
2010-11-19 13:44:58 +00:00
# remove rpath
chrpath --delete %{buildroot}%{_bindir}/{*PYMB,mb2org,fcitx,readPYBase}
# fix doc path
2010-12-17 11:58:48 +00:00
#mkdir __doc
#mv %{buildroot}%{_datadir}/%{name}/doc/* __doc
2011-09-09 09:01:15 +00:00
#rm -rf %{buildroot}%{_datadir}/%-DENABLE_GTK3_IM_MODULE=On -DENABLE_QT_IM_MODULE=On{name}/doc
2010-12-17 11:58:48 +00:00
#rm -f __doc/{API.txt,Develop_Readme*,fcitx_trunk.doxyfile}
2010-04-18 02:06:31 +00:00
# install xinput config file
install -pm 644 -D %{SOURCE1} %{buildroot}%{_xinputconf}
2010-11-19 12:47:05 +00:00
%find_lang %{name}
2010-04-18 02:06:31 +00:00
2011-09-09 11:46:27 +00:00
desktop-file-install --delete-original \
--dir ${RPM_BUILD_ROOT}%{_datadir}/applications \
${RPM_BUILD_ROOT}%{_datadir}/applications/%{name}-kimpanel.desktop
desktop-file-install --delete-original \
--dir ${RPM_BUILD_ROOT}%{_datadir}/applications \
${RPM_BUILD_ROOT}%{_datadir}/applications/%{name}-configtool.desktop
desktop-file-install --delete-original \
--dir ${RPM_BUILD_ROOT}%{_datadir}/applications \
${RPM_BUILD_ROOT}%{_datadir}/applications/%{name}.desktop
2010-04-18 02:06:31 +00:00
%clean
rm -rf %{buildroot}
2011-08-02 09:29:49 +00:00
%post
2010-04-18 02:06:31 +00:00
%{_sbindir}/alternatives --install %{_sysconfdir}/X11/xinit/xinputrc xinputrc %{_xinputconf} 55 || :
2011-09-09 11:46:27 +00:00
update-desktop-database %{_datadir}/applications &>/dev/null || :
2010-04-18 02:06:31 +00:00
2011-08-02 09:29:49 +00:00
%postun
2010-04-18 02:06:31 +00:00
if [ "$1" = "0" ]; then
%{_sbindir}/alternatives --remove xinputrc %{_xinputconf} || :
# if alternative was set to manual, reset to auto
[ -L %{_sysconfdir}/alternatives/xinputrc -a "`readlink %{_sysconfdir}/alternatives/xinputrc`" = "%{_xinputconf}" ] && %{_sbindir}/alternatives --auto xinputrc || :
fi
2011-09-09 11:46:27 +00:00
update-desktop-database %{_datadir}/applications &>/dev/null || :
2010-04-18 02:06:31 +00:00
2011-08-02 09:29:49 +00:00
%post libs -p /sbin/ldconfig
%postun libs -p /sbin/ldconfig
2011-09-09 09:01:15 +00:00
%post gtk2
%{_bindir}/update-gtk-immodules %{_host} || :
%postun gtk2
%{_bindir}/update-gtk-immodules %{_host} || :
%post gtk3
%{_bindir}/gtk-query-immodules-3.0-%{__isa_bits} --update-cache || :
%postun gtk3
%{_bindir}/gtk-query-immodules-3.0-%{__isa_bits} --update-cache || :
2010-11-19 12:47:05 +00:00
%files -f %{name}.lang
2010-04-18 02:06:31 +00:00
%defattr(-,root,root,-)
%doc AUTHORS ChangeLog THANKS TODO COPYING
2010-12-17 11:58:48 +00:00
#%doc __doc/*
2010-04-18 02:06:31 +00:00
%config %{_xinputconf}
2011-12-24 17:13:31 +00:00
%{_bindir}/fcitx-*
%{_bindir}/fcitx
2011-12-24 18:29:42 +00:00
%{_bindir}/createPYMB
%{_bindir}/mb2org
%{_bindir}/mb2txt
%{_bindir}/readPYBase
%{_bindir}/readPYMB
%{_bindir}/scel2org
%{_bindir}/txt2mb
%{_datadir}/applications/%{name}-skin-installer.desktop
2011-09-09 09:01:15 +00:00
%{_datadir}/applications/%{name}-kimpanel.desktop
2010-12-17 11:58:48 +00:00
%{_datadir}/applications/%{name}-configtool.desktop
%{_datadir}/applications/%{name}.desktop
2011-12-24 18:29:42 +00:00
%{_datadir}/mime/packages/x-fskin.xml
2010-12-17 11:58:48 +00:00
%{_docdir}/%{name}/
%{_mandir}/man1/createPYMB.1.gz
%{_mandir}/man1/fcitx-remote.1.gz
%{_mandir}/man1/fcitx.1.gz
%{_mandir}/man1/mb2org.1.gz
%{_mandir}/man1/mb2txt.1.gz
%{_mandir}/man1/readPYBase.1.gz
%{_mandir}/man1/readPYMB.1.gz
%{_mandir}/man1/scel2org.1.gz
%{_mandir}/man1/txt2mb.1.gz
2011-08-02 09:29:49 +00:00
%files libs
%defattr(-,root,root,-)
%doc
2011-12-24 17:13:31 +00:00
%{_bindir}/fcitx4-config
2011-08-02 09:29:49 +00:00
%{_libdir}/libfcitx*.so.*
2011-09-09 09:01:15 +00:00
%{_libdir}/%{name}/*.so
2010-04-18 02:06:31 +00:00
%files data
2010-11-19 12:47:05 +00:00
%defattr(-,root,root,-)
%doc
2011-09-09 09:01:15 +00:00
%{_datadir}/icons/hicolor/16x16/apps/%{name}.png
%{_datadir}/icons/hicolor/22x22/apps/%{name}.png
%{_datadir}/icons/hicolor/24x24/apps/%{name}.png
%{_datadir}/icons/hicolor/32x32/apps/%{name}.png
%{_datadir}/icons/hicolor/48x48/apps/%{name}.png
%{_datadir}/icons/hicolor/128x128/apps/%{name}.png
%{_datadir}/icons/hicolor/48x48/status/*.png
%{_datadir}/icons/hicolor/32x32/status/*.png
%{_datadir}/%{name}/data/
%{_datadir}/%{name}/configdesc/
%{_datadir}/%{name}/pinyin/
%{_datadir}/%{name}/skin/
%{_datadir}/%{name}/addon/
%{_datadir}/%{name}/table/wbx.conf
%{_datadir}/%{name}/table/wbx.mb
2010-11-19 12:47:05 +00:00
%files devel
%defattr(-,root,root,-)
%doc
%{_libdir}/libfcitx*.so
%{_libdir}/pkgconfig/fcitx*.pc
%{_includedir}/fcitx*
2011-09-09 09:01:15 +00:00
%{_datadir}/cmake/%{name}/
2010-11-19 12:47:05 +00:00
2011-09-09 09:01:15 +00:00
%files table-chinese
2011-08-02 02:19:48 +00:00
%defattr(-,root,root,-)
%doc
2011-09-09 09:01:15 +00:00
%{_datadir}/%{name}/table/qxm.conf
%{_datadir}/%{name}/table/qxm.mb
%{_datadir}/%{name}/table/cangjie.conf
%{_datadir}/%{name}/table/cj.mb
%{_datadir}/%{name}/table/db.conf
%{_datadir}/%{name}/table/db.mb
%{_datadir}/%{name}/table/erbi.conf
%{_datadir}/%{name}/table/erbi.mb
%{_datadir}/%{name}/table/wanfeng.conf
%{_datadir}/%{name}/table/wanfeng.mb
%{_datadir}/%{name}/table/wbpy.conf
%{_datadir}/%{name}/table/wbpy.mb
%{_datadir}/%{name}/table/zrm.conf
%{_datadir}/%{name}/table/zrm.mb
%files gtk2
%defattr(-,root,root,-)
2011-09-09 09:01:15 +00:00
%{_libdir}/gtk-2.0/%{gtk2_binary_version}/immodules/im-fcitx.so
2011-09-09 09:01:15 +00:00
%files gtk3
%defattr(-,root,root,-)
2011-09-09 09:01:15 +00:00
%{_libdir}/gtk-3.0/%{gtk3_binary_version}/immodules/im-fcitx.so
2011-09-09 09:01:15 +00:00
%files qt4
%defattr(-,root,root,-)
2011-09-09 15:38:31 +00:00
%{_libdir}/qt4/plugins/inputmethods/qtim-fcitx.so
2010-04-18 02:06:31 +00:00
%changelog
2011-12-24 18:29:42 +00:00
* Sun Dec 25 2011 Liang Suilong <liangsuilong@gmail.com> - 4.1.2-2
- Fix the spec
2011-12-24 17:13:31 +00:00
* Sun Dec 25 2011 Liang Suilong <liangsuilong@gmail.com> - 4.1.2-1
- Update to 4.1.2
- move fcitx4-config to devel
2011-09-10 17:28:40 +00:00
* Fri Sep 09 2011 Liang Suilong <liangsuilong@gmail.com> - 4.1.1-2
- Update xinput-fcitx
- Add fcitx-gtk3 as fcitx requires
2011-09-09 12:14:43 +00:00
* Fri Sep 09 2011 Liang Suilong <liangsuilong@gmail.com> - 4.1.1-1
- Upstream to fcitx-4.1.1
2011-09-09 09:01:15 +00:00
* Fri Sep 09 2011 Liang Suilong <liangsuilong@gmail.com> - 4.1.0-1
- Upstream to fcitx-4.1.0
- Add fcitx-gtk2 as FCITX im module for gtk2
- Add fcitx-gtk3 as FCITX im module for gtk3
- Add fcitx-qt4 as FCITX im module for qt4
2011-08-01 18:41:13 +00:00
* Tue Aug 02 2011 Liang Suilong <liangsuilong@gmail.com> - 4.0.1-5
- Fix that %files lists a wrong address
2011-08-02 09:29:49 +00:00
- Separate fcitx-libs again
2011-08-01 18:41:13 +00:00
* Tue Aug 02 2011 Liang Suilong <liangsuilong@gmail.com> - 4.0.1-4
- Separates varieties of tables from FCITX
- Merge fcitx-libs into fcitx
* Sun Jul 03 2011 Liang Suilong <liangsuilong@gmail.com> - 4.0.1-3
- Support GNOME 3 tray icon
- Fix that main window is covered by GNOME Shell
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.0.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
2010-11-19 12:47:05 +00:00
* Fri Nov 19 2010 Chen Lei <supercyper@163.com> - 4.0.0-1
- Update to 4.0.0
2010-07-20 02:56:31 +00:00
2010-06-14 12:05:03 +00:00
* Mon Jun 14 2010 Chen Lei <supercyper@163.com> - 3.6.3-5.20100514svn_utf8
- Remove BR:libXext-devel
2010-05-16 02:25:09 +00:00
* Fri May 14 2010 Chen Lei <supercyper@163.com> - 3.6.3-4.20100514svn_utf8
- svn 365
2010-04-18 16:08:51 +00:00
* Sun Apr 18 2010 Chen Lei <supercyper@163.com> - 3.6.3-3.20100410svn_utf8
- Exclude xpm files
2010-04-18 02:06:31 +00:00
* Sat Apr 17 2010 Chen Lei <supercyper@163.com> - 3.6.3-2.20100410svn_utf8
- Update License tag
- Add more explanation for UTF-8 branch
* Mon Apr 12 2010 Chen Lei <supercyper@163.com> - 3.6.3-1.20100410svn_utf8
- Initial Package