racc-vl.spec 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. %define oname racc
  2. %define ruby /usr/bin/ruby
  3. %define rversion %(%{ruby} 'print VERSION')
  4. %define rbindir %(%{ruby} -r rbconfig -e 'print Config::CONFIG["bindir"]')
  5. %define rlibdir %(%{ruby} -r rbconfig -e 'print Config::CONFIG["rubylibdir"]')
  6. %define rarchdir %(%{ruby} -r rbconfig -e 'print Config::CONFIG["archdir"]')
  7. Summary: A generator of LALR parser written by Ruby
  8. Name: %{oname}
  9. Version: 1.4.3
  10. Release: 1%{?_dist_release}
  11. License: LGPL
  12. Group: Development/Tools
  13. Source: http://www.loveruby.net/archive/racc/%{oname}-%{version}-all.tar.gz
  14. Patch1: racc-1.4.3-setup.rb.patch
  15. URL: http://www.loveruby.net/ja/prog/%{oname}.html
  16. Prefix: /usr
  17. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  18. BuildRequires: ruby, ruby-devel >= 1.8.0
  19. Requires: ruby >= 1.8.0
  20. Summary(ja): Rubyで書かれたLALR(1)パーザ生成器
  21. %description
  22. Racc is LALR(1) parser generator coded for Ruby. Written by Ruby and
  23. output Ruby source.
  24. %description -l ja
  25. raccはRubyで書かれたLALR(1)パーザ生成器で、Rubyのコードを出力します。
  26. %prep
  27. %setup -q -c
  28. cd %{oname}-%{version}-all
  29. %patch1 -p1
  30. cd ..
  31. %build
  32. cd %{oname}-%{version}-all
  33. ruby setup.rb config \
  34. --with=racc \
  35. --bin-dir=%{rbindir} \
  36. --rb-dir=%{rlibdir} \
  37. --so-dir=%{rarchdir}
  38. ruby setup.rb setup
  39. cd ..
  40. %install
  41. rm -rf ${RPM_BUILD_ROOT}
  42. mkdir -p ${RPM_BUILD_ROOT}%{rbindir}
  43. mkdir -p ${RPM_BUILD_ROOT}%{rlibdir}
  44. mkdir -p ${RPM_BUILD_ROOT}%{rarchdir}
  45. # installing binaries ...
  46. cd %{oname}-%{version}-all
  47. ruby setup.rb config \
  48. --with=racc \
  49. --bin-dir=${RPM_BUILD_ROOT}%{rbindir} \
  50. --rb-dir=${RPM_BUILD_ROOT}%{rlibdir} \
  51. --so-dir=${RPM_BUILD_ROOT}%{rarchdir}
  52. ruby setup.rb install
  53. cd ..
  54. # listing all files in %{oname}-all.files
  55. (find \
  56. $RPM_BUILD_ROOT%{rbindir} \
  57. $RPM_BUILD_ROOT%{rlibdir} \
  58. $RPM_BUILD_ROOT%{rarchdir} \
  59. -type f -o -type l) |
  60. sort | uniq | \
  61. sed -e "s,^$RPM_BUILD_ROOT,," \
  62. -e "s,\(/man/man./.*\)$,\1*," \
  63. > %{oname}.files
  64. %clean
  65. rm -rf ${RPM_BUILD_ROOT}
  66. rm -f *.files
  67. #%post -p /sbin/ldconfig -n %{oname}
  68. #%postun -p /sbin/ldconfig -n %{oname}
  69. %files -f %{oname}.files
  70. %defattr(-, root, root)
  71. %doc %{oname}-%{version}-all/packages/racc/BUGS.en
  72. %doc %{oname}-%{version}-all/packages/racc/BUGS.ja
  73. %doc %{oname}-%{version}-all/packages/racc/README.en
  74. %doc %{oname}-%{version}-all/packages/racc/README.ja
  75. %doc %{oname}-%{version}-all/packages/racc/doc.en
  76. %doc %{oname}-%{version}-all/packages/racc/doc.ja
  77. %doc %{oname}-%{version}-all/packages/racc/sample
  78. %changelog
  79. * Fri Oct 10 2008 Shu KONNO <owa@bg.wakwak.com> 1.4.3-1vl5
  80. - applied new versioning policy, spec in utf-8
  81. * Wed Dec 19 2007 Shu KONNO <owa@bg.wakwak.com> racc-1.4.3-0vl3
  82. - s/Copyright/License/
  83. * Mon Oct 06 2003 akira yamada <akira@vinelinux.org> racc-1.4.3-0vl2
  84. - build with ruby-1.8.0. it requires libruby >= 1.8.0.
  85. - obsoleted racc-runtime sub-package. runtime environment of Racc is in
  86. libruby >= 1.8.0.
  87. * Thu May 22 2003 IWAI Masaharu <iwai@alib.jp> 1.4.3-0vl1
  88. - new upstream version
  89. - update setup.rb.patch (Patch1)
  90. * Fri Mar 08 2002 akira yamada <akira@vinelinux.org> 1.4.2-0vl1
  91. - new upstream version.
  92. - update location of source and homepage.
  93. * Fri Mar 08 2002 akira yamada <akira@vinelinux.org> 1.4.1-0vl1
  94. - new upstream version.
  95. - no longer requires ruby-amstd.
  96. * Sat Oct 28 2001 akira yamada <akira@vinelinux.org> 1.3.11-0vl1
  97. - new upstream version.
  98. - corrected Reqreuis.
  99. * Thu Jul 26 2001 akira yamada <akira@vinelinux.org>
  100. - rebuild with ruby-devel-1.6.4-0vl3.
  101. * Tue Mar 20 2001 akira yamada <akira@vinelinux.org>
  102. - New upstream version 1.3.8.
  103. * Thu Mar 15 2001 akira yamada <akira@vinelinux.org>
  104. - New upstream version.
  105. * Thu Mar 15 2001 akira yamada <akira@vinelinux.org>
  106. - Initial packaging.