1 # Build recipe for aspell.
3 # Copyright (c) 2018 Matias Fonzo, <selk@dragora.org>.
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
21 # Set 'outdir' for a nice and well-organized output directory
22 outdir="${outdir}/${arch}/dict"
24 tarname=${program}-${version}.tar.gz
27 fetch=ftp://alpha.gnu.org/gnu/aspell/$tarname
32 GNU Aspell is a Free and Open Source spell checker designed to
33 eventually replace Ispell. It can either be used as a library or as an
34 independent spell checker. Its main feature is that it does a superior
35 job of suggesting possible replacements for a misspelled word than just
36 about any other spell checker out there for the English language.
38 Unlike Ispell, Aspell can also easily check documents in UTF-8 without
39 having to use a special dictionary. Aspell will also do its best to
40 respect the current locale setting. Other advantages over Ispell
41 include support for using multiple dictionaries at once and
42 intelligently handling personal dictionaries when more than one Aspell
43 process is open at once.
46 homepage=http://www.aspell.net
49 # Source documentation
50 docs="COPYING README TODO"
51 docsdir="${docdir}/${program}-${version}"
57 unpack "${tardir}/$tarname"
61 # Set sane permissions
62 chmod -R u+w,go-w,a+rX-s .
65 CFLAGS="$QICFLAGS" CXXFLAGS="$QICXXFLAGS" LDFLAGS="$QILDFLAGS" \
67 --libdir=/usr/lib${libSuffix} \
71 --enable-pkgdatadir=/usr/lib${libSuffix}/aspell \
72 --enable-pkglibdir=/usr/lib${libSuffix}/aspell \
73 --enable-dict-dir=/usr/lib${libSuffix}/aspell \
74 --build="$(cc -dumpmachine)"
77 make -j${jobs} DESTDIR="$destdir" install-strip
79 # Compress info documents deleting index file for the package
80 rm -f "${destdir}/${infodir}/dir"
81 lzip -9 "${destdir}/${infodir}"/*
83 # Compress and link man pages (if needed)
85 cd "${destdir}/$mandir"
86 find . -type f -exec lzip -9 '{}' +
87 find . -type l | while read -r file
89 ln -sf "$(readlink -- "$file").lz" "${file}.lz"
95 mkdir -p "${destdir}${docsdir}"
96 cp -p $docs "${destdir}${docsdir}"