dparser.spec 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. ##
  2. ## dparser.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2009 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ##
  5. ## Permission to use, copy, modify, and distribute this software for
  6. ## any purpose with or without fee is hereby granted, provided that
  7. ## the above copyright notice and this permission notice appear in all
  8. ## copies.
  9. ##
  10. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  11. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  12. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  13. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  14. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  15. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  16. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  17. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  18. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  19. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  20. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  21. ## SUCH DAMAGE.
  22. ##
  23. # package information
  24. Name: dparser
  25. Summary: Scannerless GLR Parser Generator
  26. URL: http://dparser.sourceforge.net/
  27. Vendor: John Plevyak
  28. Packager: OpenPKG Foundation e.V.
  29. Distribution: OpenPKG Community
  30. Class: PLUS
  31. Group: CompilerCompiler
  32. License: BSD
  33. Version: 1.21
  34. Release: 20090702
  35. # list of sources
  36. Source0: http://switch.dl.sourceforge.net/dparser/d-%{version}-src.tar.gz
  37. # build information
  38. Prefix: %{l_prefix}
  39. BuildRoot: %{l_buildroot}
  40. BuildPreReq: OpenPKG, openpkg >= 20040130, make
  41. PreReq: OpenPKG, openpkg >= 20040130
  42. AutoReq: no
  43. AutoReqProv: no
  44. %description
  45. DParser is an simple but powerful tool for parsing. You can specify
  46. the form of the text to be parsed using a combination of regular
  47. expressions and grammar productions. Because of the parsing
  48. technique (technically a scannerless GLR parser based on the Tomita
  49. algorithm) there are no restrictions. The grammar can be ambiguous,
  50. right or left recursive, have any number of null productions, and
  51. because there is no separate tokenizer, can include whitespace in
  52. terminals and have terminals which are prefixes of other terminals.
  53. DParser handles not just well formed computer languages and data
  54. files, but just about any wacky situation that occurs in the real
  55. world.
  56. %track
  57. prog dparser = {
  58. version = %{version}
  59. url = http://sourceforge.net/projects/dparser/files/
  60. regex = d-(__VER__)-src\.tar\.gz
  61. }
  62. %prep
  63. %setup -q -n d
  64. %build
  65. %{l_make} %{l_mflags} \
  66. CC="%{l_cc}"
  67. %install
  68. rm -rf $RPM_BUILD_ROOT
  69. %{l_shtool} mkdir -f -p -m 755 \
  70. $RPM_BUILD_ROOT%{l_prefix}/bin \
  71. $RPM_BUILD_ROOT%{l_prefix}/include/dparser \
  72. $RPM_BUILD_ROOT%{l_prefix}/lib \
  73. $RPM_BUILD_ROOT%{l_prefix}/man/man1 \
  74. $RPM_BUILD_ROOT%{l_prefix}/share/dparser
  75. %{l_shtool} install -c -s -m 755 \
  76. make_dparser $RPM_BUILD_ROOT%{l_prefix}/bin/
  77. %{l_shtool} install -c -m 644 \
  78. dparse.h dparse_tables.h dsymtab.h \
  79. $RPM_BUILD_ROOT%{l_prefix}/include/dparser/
  80. %{l_shtool} install -c -m 644 \
  81. libdparse.a $RPM_BUILD_ROOT%{l_prefix}/lib/
  82. %{l_shtool} install -c -m 644 \
  83. make_dparser.1 $RPM_BUILD_ROOT%{l_prefix}/man/man1/
  84. %{l_shtool} install -c -m 644 \
  85. sample.g sample_parser.c manual.html \
  86. $RPM_BUILD_ROOT%{l_prefix}/share/dparser/
  87. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
  88. %files -f files
  89. %clean
  90. rm -rf $RPM_BUILD_ROOT