ispell.spec 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. ##
  2. ## ispell.spec -- OpenPKG RPM Specification
  3. ## Copyright (c) 2000-2001 Cable & Wireless Deutschland GmbH
  4. ## Copyright (c) 2000-2001 Ralf S. Engelschall <rse@engelschall.com>
  5. ##
  6. ## Permission to use, copy, modify, and distribute this software for
  7. ## any purpose with or without fee is hereby granted, provided that
  8. ## the above copyright notice and this permission notice appear in all
  9. ## copies.
  10. ##
  11. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  12. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  13. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  14. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  15. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  16. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  17. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  18. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  19. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  20. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  21. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  22. ## SUCH DAMAGE.
  23. ##
  24. # package information
  25. Name: ispell
  26. Summary: Interactive Spell Checker
  27. URL: http://fmg-www.cs.ucla.edu/geoff/ispell.html
  28. Vendor: R.E. Gorin, Pace Willisson, Geoff Kuenning
  29. Packager: The OpenPKG Project
  30. Distribution: OpenPKG [EXP]
  31. Group: Text
  32. License: BSD
  33. Version: 3.2.06
  34. Release: %{l_branch}.0
  35. # list of sources
  36. Source0: ftp://ftp.cs.ucla.edu/pub/ispell-3.1/ispell-%{version}.tar.gz
  37. Source1: ftp://ftp.informatik.uni-kiel.de/pub/kiel/dicts/hk-deutsch.tar.gz
  38. Source2: http://www.suse.de/~bjacke/igerman98/dict/igerman98-20001109.tar.bz2
  39. Source3: ftp://ftp.openpkg.org/DST/ispell/words.gz
  40. Patch0: ispell.patch
  41. # build information
  42. Prefix: %{l_prefix}
  43. BuildRoot: %{l_buildroot}
  44. BuildPreReq: OpenPKG, openpkg >= 20011023.0, bison
  45. PreReq: OpenPKG, openpkg >= 20011023.0
  46. AutoReq: no
  47. AutoReqProv: no
  48. %description
  49. Ispell is a fast screen-oriented spelling checker that shows you
  50. your errors in the context of the original file, and suggests
  51. possible corrections when it can figure them out. Compared to UNIX
  52. spell, it is faster and much easier to use. Ispell can also handle
  53. languages other than English.
  54. %prep
  55. %setup0 -q
  56. %patch0 -p0
  57. %{l_gzip} -d -c %{SOURCE words.gz} >$RPM_BUILD_DIR/words
  58. mkdir hk-deutsch
  59. (cd hk-deutsch; %{l_gzip} -d -c %{SOURCE hk-deutsch.tar.gz} | %{l_tar} xf -)
  60. %{l_bzip2} -d -c %{SOURCE igerman98-20001109.tar.bz2} | %{l_tar} xf -
  61. %build
  62. PATH="%{l_prefix}/bin:$PATH"; export PATH
  63. ( echo "#define MINIMENU"
  64. echo "#undef NO8BIT"
  65. echo "#define MASKBITS 64"
  66. echo "#define CC \"%{l_cc}\""
  67. echo "#define CFLAGS \"%{l_cflags -O}\""
  68. echo "#define BINDIR \"%{l_prefix}/bin\""
  69. echo "#define LIBDIR \"%{l_prefix}/share/ispell\""
  70. echo "#define MAN1DIR \"%{l_prefix}/man/man1\""
  71. echo "#define MAN4DIR \"%{l_prefix}/man/man4\""
  72. echo "#define WORDS \"$RPM_BUILD_DIR/words\""
  73. echo "#define YACC \"%{l_prefix}/bin/bison -y\""
  74. #echo "#define LANGUAGES \"{american,MASTERDICTS=american.med+,HASHFILES=americanmed+.hash,EXTRADICT=$RPM_BUILD_DIR/words}\""
  75. ) >local.h
  76. %{l_make} %{l_mflags}
  77. ( cd hk-deutsch
  78. cat worte.txt verben.txt \
  79. adjektive.txt klein.txt geographie.txt vornamen.txt \
  80. abkuerz.txt imperat.txt latein.txt informatik.txt \
  81. infoabk.txt elektronik.txt orgabk.txt marken.txt \
  82. alphabeta.txt roemisch.txt zusammen.txt | \
  83. sort -u >all.words
  84. ../buildhash all.words deutsch.aff deutsch.hash
  85. )
  86. ( cd igerman98-20001109
  87. %{l_make} %{l_mflags} \
  88. UNSQ=cat BUILDHASH=`pwd`/../buildhash \
  89. german.hash 2>/dev/null
  90. )
  91. %install
  92. rm -rf $RPM_BUILD_ROOT
  93. %{l_shtool} mkdir -f -p -m 755 \
  94. $RPM_BUILD_ROOT%{l_prefix}/bin \
  95. $RPM_BUILD_ROOT%{l_prefix}/man \
  96. $RPM_BUILD_ROOT%{l_prefix}/share/ispell
  97. ( echo "#define MINIMENU"
  98. echo "#undef NO8BIT"
  99. echo "#define MASKBITS 64"
  100. echo "#define CC \"%{l_cc}\""
  101. echo "#define CFLAGS \"%{l_cflags -O}\""
  102. echo "#define BINDIR \"$RPM_BUILD_ROOT%{l_prefix}/bin\""
  103. echo "#define LIBDIR \"$RPM_BUILD_ROOT%{l_prefix}/share/ispell\""
  104. echo "#define MAN1DIR \"$RPM_BUILD_ROOT%{l_prefix}/man/man1\""
  105. echo "#define MAN4DIR \"$RPM_BUILD_ROOT%{l_prefix}/man/man4\""
  106. echo "#define WORDS \"$RPM_BUILD_DIR/words\""
  107. #echo "#define LANGUAGES \"{american,MASTERDICTS=american.med+,HASHFILES=americanmed+.hash,EXTRADICT=$RPM_BUILD_DIR/words}\""
  108. ) >local.h
  109. %{l_make} %{l_mflags} config.sh install-basic install-deformatters install-dictbuild install-languages
  110. rm -f $RPM_BUILD_ROOT%{l_prefix}/share/ispell/american*
  111. ( cd hk-deutsch
  112. %{l_shtool} install -c -m 644 \
  113. deutsch.aff $RPM_BUILD_ROOT%{l_prefix}/share/ispell/deutsch-old.aff
  114. %{l_shtool} install -c -m 644 \
  115. deutsch.hash $RPM_BUILD_ROOT%{l_prefix}/share/ispell/deutsch-old.hash
  116. )
  117. ( cd igerman98-20001109
  118. %{l_shtool} install -c -m 644 \
  119. german.aff $RPM_BUILD_ROOT%{l_prefix}/share/ispell/deutsch.aff
  120. %{l_shtool} install -c -m 644 \
  121. german.hash $RPM_BUILD_ROOT%{l_prefix}/share/ispell/deutsch.hash
  122. )
  123. strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
  124. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
  125. %files -f files
  126. %clean
  127. rm -rf $RPM_BUILD_ROOT