lookup-vl.spec 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. %define _noVersionedDependencies 1
  2. %define prereq_ge() %(LC_ALL="C" rpm -q --queryformat 'PreReq:%%{NAME} >= %%{VERSION}' %1| grep -v "is not")
  3. %define emacsen_pkgdir /usr/lib/emacsen-common/packages
  4. %define origname lookup
  5. %define origver 1.4.1
  6. Summary: a Search Interface for Emacsen
  7. Summary(ja): Emacs 系のエディタで利用できる辞書検索インターフェース
  8. Name: %{origname}
  9. Version: %{origver}
  10. Release: 1%{?_dist_release}
  11. Source0: http://openlab.jp/edict/lookup/dist/lookup-%{version}.tar.gz
  12. Source1: %{origname}-install.sh
  13. Source2: %{origname}-remove.sh
  14. Source10: lookup-sample.dotemacs
  15. Source11: lookup-init.el
  16. Source12: vine-default-lookup.el
  17. License: GPL
  18. Group: Applications/Editors/Emacs
  19. URL: http://openlab.jp/edict/lookup/
  20. BuildRoot: %{_tmppath}/%{name}-%{version}
  21. BuildArch: noarch
  22. Requires: emacsen
  23. PreReq: emacsen flim apel
  24. BuildRequires: flim apel
  25. %prereq_ge emacsen-common
  26. PreReq: /sbin/install-info
  27. Obsoletes: lookup-emacs, lookup-xemacs
  28. Conflicts: %{origname}-el
  29. Distribution: Vine Linux
  30. Vendor: Project Vine
  31. Packager: Tomoya TAKA <taka@vinelinux.org>
  32. %description
  33. Lookup is interface on Emacs to use some dictionaries.
  34. Lookup is developed by OpenLab, Ring Server Project.
  35. %description -l ja
  36. Lookup は Emacs 系のエディタで利用できる辞書検索インターフェースです。
  37. 市販のCD-ROM 辞書やネットワークの辞書サーバを始め、様々な情報源から簡単な操作
  38. と設定で辞書検索が行なえます。
  39. %prep
  40. %setup -q -n %{origname}-%{origver}
  41. %build
  42. %configure --prefix=%{_prefix} --infodir=%{_infodir}
  43. %install
  44. [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
  45. [ "%{buildroot}" != "/" ] && mkdir -p %{buildroot}
  46. mkdir -p %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/packages
  47. mkdir -p %{buildroot}%{emacsen_pkgdir}/install
  48. mkdir -p %{buildroot}%{emacsen_pkgdir}/remove
  49. #
  50. # install el files
  51. #
  52. cp -p lisp/*.el %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}
  53. cp -p lisp/*.el.in %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}
  54. cp -p lisp/lookup-logo.* %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}
  55. cp -p packages/*.el %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/packages
  56. cp -p packages/dict-misc/*.el %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/packages
  57. cp -p packages/jitenban97/*.el %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/packages
  58. cp %{SOURCE11} %{SOURCE12} %{buildroot}%{_datadir}/emacs/site-lisp/%{origname}/
  59. #
  60. # install script (bytecompile el and install elc , remove)
  61. #
  62. %_installemacsenscript %{origname} %{SOURCE1}
  63. %_removeemacsenscript %{origname} %{SOURCE2}
  64. #
  65. # install info file
  66. #
  67. mkdir -p %{buildroot}%{_infodir}
  68. cp -p texi/lookup-guide.info %{buildroot}%{_infodir}
  69. cp -p texi/lookup.info* %{buildroot}%{_infodir}
  70. #
  71. # copy sample of ~/{.emacs.el,.xemacs.el}
  72. #
  73. cp %{SOURCE10} ./sample.dotemacs
  74. %clean
  75. [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
  76. %post
  77. #
  78. # bytecompile and install
  79. #
  80. if [ "$1" = 2 ]; then
  81. %_emacsenPackageRemove %{origname}
  82. fi
  83. %_addemacsenlist %{origname}
  84. %_emacsenPackageInstall %{origname}
  85. /sbin/install-info --info-dir=%{_infodir} %{_infodir}/lookup-guide.info.gz
  86. /sbin/install-info --info-dir=%{_infodir} %{_infodir}/lookup.info.gz
  87. %preun
  88. if [ "$1" = 0 ]; then
  89. %_emacsenPackageRemove %{origname}
  90. %_removeemacsenlist %{origname}
  91. /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/lookup-guide.info.gz
  92. /sbin/install-info --delete --info-dir=%{_infodir} %{_infodir}/lookup.info.gz
  93. fi
  94. %files
  95. %defattr(-,root,root)
  96. %doc AUTHORS COPYING ChangeLog NEWS README VERSION
  97. %doc sample.dotemacs texi/*.texi
  98. %{_datadir}/emacs/site-lisp/%{origname}
  99. %{emacsen_pkgdir}/install/%{origname}
  100. %{emacsen_pkgdir}/remove/%{origname}
  101. %{_infodir}/*
  102. %changelog
  103. * Tue Mar 30 2010 IWAI, Masaharu <iwai@alib.jp> 1.4.1-1
  104. - update to 1.4.1
  105. - add PreReq: apel
  106. - add BuildRequires: flim apel
  107. * Mon Dec 14 2009 IWAI, Masaharu <iwai@alib.jp> 1.4-2
  108. - apply vine-default
  109. - add lookup-init.el (Source11)
  110. - add vine-default-lookup.el (Source12)
  111. - update lookup-{install,remove}.sh
  112. - update sammary and description in English
  113. - rename Source10: sample.dotemacs to lookup-sample.dotemacs
  114. - add PreReq: flim :fixed <BTS:VineLinux:857>
  115. * Fri Oct 03 2008 Shu KONNO <owa@bg.wakwak.com> 1.4-1vl5
  116. - applied new versioning policy, spec in utf-8
  117. - added %%emacsen_pkgdir macro
  118. * Tue Sep 12 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.4-0vl3
  119. - changed Group to Appliations/Editors/Emacs <BTS:VineLinux:163>
  120. - s/Copyright/License/
  121. * Fri Jul 2 2004 NISHIMURA Daisuke <nishi@graco.c.u-tokyo.ac.jp> 1.4-0vl2
  122. - add missing SOURCES (ndeb-binary.el, ndnmz.el) in lookup-install.sh
  123. * Tue May 4 2004 IWAI, Masaharu <iwai@alib.jp> 1.4-0vl1
  124. - version up to 1.4 ( edict openlab version )
  125. - update URL and Source0 tags
  126. - update lookup-install.sh script: value of VERSION
  127. * Mon Mar 17 2003 IWAI Masaharu <iwai@alib.jp> 1.3-0vl4
  128. - rebuild
  129. * Sun Dec 30 2001 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 1.3-0vl3
  130. - lookup-el -> lookup again
  131. * Sat Dec 9 2001 Tomoya TAKA <taka@vinelinux.org> 1.3-0vl1
  132. - emacsenize
  133. * Sun Jun 24 2001 Tomoya TAKA <tomoya@olive.plala.or.jp>
  134. - 1.3-0vl1
  135. - add Prereq: /sbin/install-info, handle info pages in %%post and %%preun
  136. - some fix on spec file, use rpm macros
  137. * Mon Jun 26 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org>
  138. - 1.2-0vl3
  139. - BuildArch: noarch
  140. * Wed Apr 26 2000 Masaki Kawamura <kawamura@ic.sci.yamaguchi-u.ac.jp>
  141. - release for the Vine Linux 2.0