migemo-vl.spec 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184
  1. ## -*- coding: utf-8-unix -*-
  2. %define _noVersionedDependencies 1
  3. %define prereq_ge() %(LC_ALL="C" rpm -q --queryformat 'PreReq:%%{NAME} >= %%{VERSION}' %1| grep -v "is not")
  4. %define origname migemo
  5. %define origver 0.40
  6. %define release 3%{?_dist_release}
  7. #%%define rlibdir ruby -r rbconfig -e 'print Config::CONFIG["rubylibdir"]'
  8. %define rubyver %(%{ruby} -r rbconfig -e 'print Config::CONFIG["rubylibdir"]'|%{__sed} -e 's/^.*\\/\\([0-9.]*\\)$/\\1/')
  9. Name: %{origname}
  10. Version: %{origver}
  11. Release: %{release}
  12. Summary: Japanese incremental search with Romaji on Emacsen
  13. Summary(ja): Emacsen 上でローマ字を使って日本語インクリメントサーチを行うツール
  14. License: GPL2
  15. Group: Applications/Editors/Emacs
  16. Source0: http://0xcc.net/migemo/migemo-%{origver}.tar.gz
  17. Source1: migemo-install.sh
  18. Source2: migemo-remove.sh
  19. Source3: vine-default-migemo.el
  20. Source4: migemo-init.el
  21. URL: http://0xcc.net/migemo/
  22. BuildArch: noarch
  23. Buildroot: %{_tmppath}/%{name}-%{version}-root
  24. BuildRequires: ruby
  25. BuildRequires: ruby-bsearch
  26. BuildRequires: ruby-romkan
  27. BuildRequires: emacsen
  28. Requires: emacsen
  29. Requires: apel
  30. Requires: ruby >= %{rubyver}
  31. Requires: ruby-bsearch >= 1.5-0vl4
  32. Requires: ruby-romkan >= 0.4-0vl3
  33. Requires(post): emacsen
  34. Requires(preun): emacsen
  35. %prereq_ge emacsen-common
  36. %description
  37. Japanese incremental search with Romaji on Emacsen
  38. %description -l ja
  39. Emacsen 上でローマ字を使って日本語インクリメントサーチを行うツール
  40. %prep
  41. %setup -q -n %{origname}-%{origver}
  42. %build
  43. %configure
  44. make emacsdir=${RPM_BUILD_ROOT}-%{emacsdir} \
  45. lispdir=%{_datadir}/emacs/site-lisp/%{origname} \
  46. rubydir=%{rlibdir}
  47. %install
  48. [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}
  49. [ "${RPM_BUILD_ROOT}" != "/" ] && mkdir -p ${RPM_BUILD_ROOT}
  50. mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp/%{origname}
  51. mkdir -p ${RPM_BUILD_ROOT}%{emacsen_pkgdir}/install
  52. mkdir -p ${RPM_BUILD_ROOT}%{emacsen_pkgdir}/remove
  53. %makeinstall emacsdir=${RPM_BUILD_ROOT}-%{emacsdir} \
  54. lispdir=${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp/%{origname} \
  55. rubydir=${RPM_BUILD_ROOT}%{rlibdir}
  56. rm -f ${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp/%{origname}/*.elc
  57. make clean
  58. cp -ar Makefile* configure* *.el *.el.in elisp-comp acinclude.m4 \
  59. install-sh mkinstalldirs missing INSTALL NEWS migemo.rb.in \
  60. README COPYING AUTHORS ChangeLog tests config.status migemo \
  61. %{SOURCE3} %{SOURCE4} \
  62. ${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp/%{origname}
  63. #
  64. # install script( bytecompile el and install elc , remove )
  65. #
  66. %_installemacsenscript %{origname} %{SOURCE1}
  67. %_removeemacsenscript %{origname} %{SOURCE2}
  68. %post
  69. #
  70. # bytecompile and install
  71. #
  72. if [ "$1" = 2 ]; then
  73. %_emacsenPackageRemove %{origname}
  74. fi
  75. %_addemacsenlist %{origname}
  76. %_emacsenPackageInstall %{origname}
  77. %preun
  78. if [ "$1" = 0 ]; then
  79. %_emacsenPackageRemove %{origname}
  80. %_removeemacsenlist %{origname}
  81. fi
  82. %clean
  83. [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}
  84. rm -rf ${RPM_BUILD_DIR}/%{origname}-%{origver}
  85. %files
  86. %defattr(-,root,root)
  87. %doc AUTHORS COPYING ChangeLog INSTALL NEWS README tests
  88. %{_bindir}/migemo*
  89. %{rlibdir}/migemo*
  90. %{_datadir}/migemo
  91. %{_datadir}/emacs/site-lisp/%{origname}
  92. %{emacsen_pkgdir}/install/%{origname}
  93. %{emacsen_pkgdir}/remove/%{origname}
  94. %changelog
  95. * Wed Jan 06 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.40-3
  96. - use %%{emacsen_pkgdir}
  97. * Tue May 5 2009 IWAI, Masaharu <iwai@alib.jp> 0.40-2
  98. - spec in UTF-8
  99. - drop Prefix tag
  100. - fix BuildRequires: emacs to emacsen
  101. - apply vine-default
  102. - update migemo-install.sh (Source1)
  103. - update migemo-remove.sh (Source2)
  104. - add vine-default-migemo.el (Source3)
  105. - add migemo-init.el (Source4)
  106. - update %%flies section
  107. - add %%{_datadir}/emacs/site-lisp/%%{origname} directory
  108. * Tue Sep 16 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.40-1
  109. - applied new versioning policy
  110. - updated Source0 URL, URL:
  111. - updated BuildRequires:
  112. * Tue Sep 12 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 0.40-0vl9
  113. - changed Group to Appliations/Editors/Emacs <BTS:VineLinux:163>
  114. * Fri Oct 22 2004 IWAI, Masaharu <iwai@alib.jp> 0.40-0vl7
  115. - add Japanese summary and description
  116. * Tue Jun 15 2004 IWAI, Masaharu <iwai@alib.jp> 0.40-0vl6
  117. - update migemo-install.sh (Source1):
  118. touch a few files: aclocal.m4 Makefile.in configure
  119. * Sun Dec 28 2003 IWAI, Masaharu <iwai@alib.jp> 0.40-0vl5
  120. - fix Requires
  121. * Fri Oct 10 2003 IWAI, Masaharu <iwai@alib.jp> 0.40-0vl4
  122. - update {Build,}Requires: more exact
  123. * Tue Oct 7 2003 IWAI, Masaharu <iwai@alib.jp> 0.40-0vl3
  124. - build with ruby-1.8.0
  125. * Sun Jun 1 2003 IWAI Masaharu <iwai@alib.jp> 0.40-0vl2
  126. - fix byte compile routine ([VineSeed-Plus:01695])
  127. - cp -ar migemo.rb.in migemo %%{_datadir}/emacs/site-lisp/%%{origname}
  128. - update migemo-install.sh (Source1)
  129. * Fri May 30 2003 IWAI Masaharu <iwai@alib.jp> 0.40-0vl1
  130. - upstream release
  131. * Fri Mar 21 2003 IWAI Masaharu <iwai@alib.jp> 0.32-0vl4
  132. - rebuild
  133. * Sat Feb 16 2002 IWAI Masaharu <iwaim@cc.mbn.or.jp> 0.32-0vl3
  134. - rebuild with ruby-romkan-0.4-0vl1
  135. * Wed Feb 6 2002 IWAI Masaharu <iwaim@cc.mbn.or.jp> 0.32-0vl2
  136. - moved the directory installed the ruby library
  137. - sitelibdir -> rubylibdir
  138. - added BuildRequires: ruby, rpm >= 3.0.6-0vl16
  139. * Wed Jan 2 2002 IWAI Masaharu <iwaim@cc.mbn.or.jp> 0.32-0vl1
  140. - first release for VIne Linux
  141. * Fri Sep 7 2001 IWAI Masaharu <iwaim@cc.mbn.or.jp>
  142. - 0.32-1
  143. - first release.