[8058] | 1 | %define ver 0.1.0 |
---|
| 2 | %define rel 1 |
---|
| 3 | |
---|
| 4 | %define from_git 1 |
---|
| 5 | %if %{from_git} |
---|
| 6 | %define githash 51112956 |
---|
| 7 | %endif |
---|
| 8 | |
---|
| 9 | Summary: Japanese Kana Kanji Engine for Fcitx |
---|
| 10 | Name: fcitx-kkc |
---|
| 11 | Version: %{ver} |
---|
| 12 | %if %{from_git} |
---|
| 13 | Release: %{rel}.git%{githash}%{_dist_release} |
---|
| 14 | %else |
---|
| 15 | Release: %{rel}%{_dist_release} |
---|
| 16 | %endif |
---|
| 17 | License: GPLv3 |
---|
| 18 | Group: System Environment/Libraries |
---|
| 19 | URL: https://fcitx-im.org |
---|
| 20 | %if %{from_git} |
---|
| 21 | Source0: %{name}-%{githash}.tar.xz |
---|
| 22 | %else |
---|
| 23 | Source0: http://download.fcitx-im.org/fcitx-kkc/%{name}-%{version}.tar.xz |
---|
| 24 | %endif |
---|
| 25 | BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot |
---|
| 26 | BuildRequires: cmake |
---|
| 27 | BuildRequires: fcitx-devel >= 4.2.8 |
---|
| 28 | BuildRequires: libkkc-devel >= 0.2.3 |
---|
| 29 | Requires: fcitx |
---|
| 30 | |
---|
| 31 | Distribution: Vine Linux |
---|
| 32 | Vendor: Project Vine |
---|
| 33 | Packager: iwaim |
---|
| 34 | |
---|
| 35 | %description |
---|
| 36 | Japanese Kana Kanji Engine for Fcitx. |
---|
| 37 | |
---|
| 38 | %prep |
---|
| 39 | %if %{from_git} |
---|
| 40 | %setup -q -n %{name}-%{githash} |
---|
| 41 | %else |
---|
| 42 | %setup -q |
---|
| 43 | %endif |
---|
| 44 | |
---|
| 45 | %build |
---|
| 46 | %__mkdir build |
---|
| 47 | pushd build |
---|
| 48 | %cmake ENABLE_QT=On .. |
---|
| 49 | make %{?_smp_mflags} |
---|
| 50 | popd |
---|
| 51 | |
---|
| 52 | %install |
---|
| 53 | rm -rf $RPM_BUILD_ROOT |
---|
| 54 | pushd build |
---|
| 55 | make install DESTDIR=$RPM_BUILD_ROOT INSTALL="install -p" |
---|
| 56 | popd |
---|
| 57 | |
---|
| 58 | %find_lang %{name} |
---|
| 59 | |
---|
| 60 | %clean |
---|
| 61 | rm -rf $RPM_BUILD_ROOT |
---|
| 62 | |
---|
| 63 | %post |
---|
| 64 | /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : |
---|
| 65 | |
---|
| 66 | %postun |
---|
| 67 | if [ $1 -eq 0 ] ; then |
---|
| 68 | /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null |
---|
| 69 | /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : |
---|
| 70 | fi |
---|
| 71 | |
---|
| 72 | %posttrans |
---|
| 73 | /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : |
---|
| 74 | |
---|
| 75 | %files -f %{name}.lang |
---|
| 76 | %defattr(-,root,root,-) |
---|
| 77 | %doc COPYING |
---|
| 78 | %{_libdir}/fcitx/fcitx-kkc.so |
---|
| 79 | %{_libdir}/fcitx/qt/libfcitx-kkc-config.so |
---|
| 80 | %{_datadir}/fcitx/addon/fcitx-kkc.conf |
---|
| 81 | %{_datadir}/fcitx/configdesc/fcitx-kkc.desc |
---|
| 82 | %{_datadir}/fcitx/imicon/kkc.png |
---|
| 83 | %{_datadir}/fcitx/inputmethod/kkc.conf |
---|
| 84 | %dir %{_datadir}/fcitx/kkc |
---|
| 85 | %{_datadir}/fcitx/kkc/dictionary_list |
---|
| 86 | %{_datadir}/fcitx/kkc/rule |
---|
| 87 | %{_datadir}/icons/hicolor/64x64/apps/fcitx-kkc.png |
---|
| 88 | %dir %{_includedir}/fcitx/module/kkc |
---|
| 89 | %{_includedir}/fcitx/module/kkc/fcitx-kkc.h |
---|
| 90 | |
---|
| 91 | %changelog |
---|
| 92 | * Sun Dec 22 2013 IWAI, Masaharu <iwaim.sub@gmail.com> 0.1.0-1.git51112956 |
---|
| 93 | - initial relase |
---|
| 94 | |
---|