123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168 |
- %define _noVersionedDependencies 1
- %define prereq_ge() %(LC_ALL="C" rpm -q --queryformat 'PreReq:%%{NAME} >= %%{VERSION}' %1| grep -v "is not")
- %define name suikyo
- %define version 2.1.0
- %define release 1%{?_dist_release}
- Summary: A Romaji-Kana conversion Library
- Summary(ja): ローマ字・かな変換ライブラリ
- Name: %{name}
- Version: %{version}
- Release: %{release}
- Group: Development/Libraries
- License: GPL
- URL: http://taiyaki.org/suikyo/
- Source0: %{name}-%{version}.tar.bz2
- BuildRoot: %{_tmppath}/%{name}-%{version}-root
- Requires: ruby
- BuildRequires: ruby-devel
- ### for GNU Emacs on Vine Linux
- Source100: %{name}-install.sh
- Source101: %{name}-remove.sh
- ##Source102: %{name}-init.el
- %description
- Suikyo is Romaji-Kana conversion Library.
- %description -l ja
- 水鏡はローマ字・かな変換ライブラリです.
- %package el
- Summary: elisp binding of Suikyo
- Summary(ja): 水鏡の elisp バイディング
- Group: Applications/Editors/Emacs
- PreReq: emacsen
- Requires: %{name} = %{version}-%{release}
- %prereq_ge emacsen-common
- BuildRequires: emacsen-common
- BuildArch: noarch
- %description el
- Suikyo is Romaji-Kana conversion Library.
- This package contains elisp binding of Suikyo.
- %description -l ja el
- 水鏡はローマ字・かな変換ライブラリです.
- このパッケージは水鏡の elisp バイディングを含んでいます.
- %prep
- %setup -q
- %build
- [[ ! -x configure ]] && ./autogen.sh
- %configure --with-rubydir=%{rlibdir}
- %{__make}
- %check
- %{__make} check
- %install
- rm -rf $RPM_BUILD_ROOT
- %{__make} install DESTDIR=${RPM_BUILD_ROOT} sitelibdir=%{rlibdir}
- rm -rf $RPM_BUILD_ROOT%{_datadir}/doc
- ### for GNU Emacs
- mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp/%{name}
- mkdir -p ${RPM_BUILD_ROOT}%{_libdir}/emacsen-common/packages/install
- mkdir -p ${RPM_BUILD_ROOT}%{_libdir}/emacsen-common/packages/remove
- mkdir -p ${RPM_BUILD_ROOT}%{_infodir}
- #
- # install el files
- #
- ##%{__install} -m 644 %{SOURCE102} \
- ## ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/%{name}/
- %{__cat} > \
- ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/%{name}/%{name}-init.el <<EOF
- ;;
- ;; suikyo-init.el
- ;;
- ;; for Vine Linux with emacsen-common
- ;; Munehiro Yamamoto <munepi@cg8.so-net.ne.jp>
- (defconst suikyo-version '("2.1.0" "2005-03-29"))
- (provide 'init-suikyo)
- ;; end of file
- EOF
- ##%{__cat} ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/init-suikyo.el >> \
- ## ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/%{name}/%{name}-init.el
- %{__rm} -f ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/init-suikyo.el
- ##%{__cat} >> \
- ## ${RPM_BUILD_ROOT}/%{_datadir}/emacs/site-lisp/%{name}/%{name}-init.el <<EOF
- ##
- ##;; end of file
- ##EOF
- #
- # install script (bytecompile el and install elc, remove)
- #
- %_installemacsenscript %{name} %{SOURCE100}
- %_removeemacsenscript %{name} %{SOURCE101}
- %clean
- [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}
- %post -n %{name}-el
- #
- # bytecompile and install
- #
- if [ "$1" = 2 ] ; then
- %_emacsenPackageRemove %{name}
- fi
- %_addemacsenlist %{name}
- %_emacsenPackageInstall %{name}
- %preun -n %{name}-el
- if [ "$1" = 0 ]; then
- %_emacsenPackageRemove %{name}
- %_removeemacsenlist %{name}
- fi
- %files
- %defattr(-,root,root)
- %doc AUTHORS COPYING ChangeLog README
- %{rlibdir}/*
- %{_libdir}/pkgconfig/*
- %{_datadir}/%{name}
- %files -n %{name}-el
- %defattr(-,root,root)
- %doc AUTHORS COPYING ChangeLog README
- %{_datadir}/emacs/site-lisp/%{name}/
- %{_libdir}/emacsen-common/packages/install/%{name}
- %{_libdir}/emacsen-common/packages/remove/%{name}
- %changelog
- * Sat Nov 01 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 2.1.0-1
- - initial build for VineSeed
- * Mon Mar 24 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 2.1.0-1vl5
- - initial build for VineSeed
- ### end of file
|