Commit 59f14144 authored by Alexander Larsson's avatar Alexander Larsson
Browse files

Add enchant and dependencies

parent 92b486bd
......@@ -47,6 +47,7 @@ PACKAGES = \
gtk2 gnome-themes-standard libproxy gsettings-desktop-schemas glib-networking libsoup \
dconf gvfs desktop-file-utils json-glib libnotify vte mozjs24 gjs \
cogl clutter clutter-gtk webkitgtk4 \
aspell hunspell-en hunspell enchant \
zenity \
$(NULL)
......
--- wordlist.orig/en_GB.dic 2005-05-26 11:49:30.000000000 +0100
+++ wordlist/en_GB.dic 2008-11-28 10:01:37.000000000 +0000
@@ -1,4 +1,4 @@
-46280
+46286
abaft
abbreviation/M
abdicate/DNGSn
@@ -2278,6 +2278,7 @@
hysterectomy/SM
Hyundai/M
ICC/M
+i
icebox/SM
icicle/SM
iconoclasm/MS
@@ -2470,6 +2471,7 @@
Ithacan
its
ix
+j
jackknife/DGMS
Jacqueline
Jaeger/M
@@ -2764,6 +2766,7 @@
Mabel/M
Macedon
Macedonia/M
+m
macintosh/SM
MacIntyre
Mackenzie
@@ -3222,6 +3225,7 @@
nuttiness/S
nymphomaniac/S
Oakland/M
+o
ob.
obeyer/EM
obfuscation/M
@@ -4797,6 +4801,7 @@
tyro/SM
UFO/S
Ukrainian/S
+u
ulcerate/SGNDn
ulcerous
Ulrika/M
@@ -4962,6 +4967,7 @@
vulnerability/SI
vulva/M
WAC
+w
wagon/SM
waitress/MS
Waldemar/M
--- wordlist.orig/en_GB.dic 2009-06-06 15:16:16.000000000 +0100
+++ wordlist/en_GB.dic 2009-06-06 15:17:28.000000000 +0100
@@ -19953,7 +19953,7 @@
technology/3wSM1
Ted/M
tee/SGdM
-TEirtza/M
+Teirtza/M
tellurium/M
temp/GMRSTD
tempera/MLS
@@ -41226,7 +41226,7 @@
adore/lRSNnGkD
Adrian/M
adroit/TYP
-ADte
+ADTe
adulterer/SM
adumbration/M
advantageousness/E
--- wordlist/en_GB.dic.orig 2012-04-10 22:51:16.471732570 +0100
+++ wordlist/en_GB.dic 2012-04-10 22:55:00.018995514 +0100
@@ -1,4 +1,4 @@
-46285
+46286
abaft
abbreviation/M
abdicate/DNGSn
@@ -22588,6 +22588,7 @@
halter/d
halyard/MS
Hamal/M
+hames
Hamlin/M
hamper/dS
handbag/SMDG
--- wordlist/scowl/speller/en.dic.supp.orig 2008-11-28 10:10:01.000000000 +0000
+++ wordlist/scowl/speller/en.dic.supp 2008-11-28 10:10:10.000000000 +0000
@@ -21,3 +21,5 @@
7th/pt
8th/pt
9th/pt
+e.g.
+i.e.
--- wordlist/scowl/r/special/abbreviations 2008-11-29 23:02:41.000000000 +0000
+++ wordlist/scowl/r/special/abbreviations 2010-07-30 11:18:33.000000000 +0100
@@ -2,6 +2,11 @@
AI
ATM
BTW
+EB
+Eb
+Ei
+EiB
+Eib
EULA
EULAs
FAQ
@@ -13,27 +18,63 @@
GB
GHz
GUI
+Gb
+Gi
+GiB
+Gib
HTML
HTTP
+IEC
IMHO
IMNSHO
IMO
ISO
+JEDEC
+KB
+Kb
+Ki
+KiB
+Kib
MB
MP3
MP3s
Mb
+Mi
+MiB
+Mib
OTOH
+PB
+Pb
+Pi
+PiB
+Pib
RFC
ROFL
RTFM
+TB
+Tb
+Ti
+TiB
+Tib
URL
USB
WWW
WYSIWYG
XML
+YB
+Yb
YMMV
+Yi
+YiB
+Yib
+ZB
+Zb
+Zi
+ZiB
+Zib
cf
+kB
+kb
pp
resp
vs
--- wordlist/en_GB.aff 2010-04-15 14:51:13.000000000 +0100
+++ wordlist/en_GB.aff 2010-04-15 14:52:07.000000000 +0100
@@ -6,6 +6,7 @@
# R 1.18, 11/04/05
SET ISO8859-1
TRY esianrtolcdugmfphbyvkw-'.zqjxSNRTLCGDMFPHBEAUYOIVKWZQJX
+WORDCHARS 0123456789'
REP 27
REP f ph
REP ph f
--- wordlist/scowl/speller/en.aff.orig 2010-04-15 14:56:37.000000000 +0100
+++ wordlist/scowl/speller/en.aff 2010-04-15 14:57:08.000000000 +0100
@@ -12,7 +12,7 @@
COMPOUNDRULE 2
COMPOUNDRULE n*1t
COMPOUNDRULE n*mp
-WORDCHARS 0123456789
+WORDCHARS 0123456789'
PFX A Y 1
PFX A 0 re .
--- wordlist/en_GB.dic 2011-02-08 11:43:16.730271377 +0000
+++ wordlist/en_GB.dic 2011-02-08 11:43:35.261482189 +0000
@@ -1,4 +1,4 @@
-46286
+46285
abaft
abbreviation/M
abdicate/DNGSn
@@ -643,7 +643,6 @@
Calder
caldera/SM
caldron's
-calender/dMS
calibrate/SAGDN
calibrater's
calico/M
--- wordlist/alt12dicts/2of12full.txt 2011-02-08 11:55:46.478837084 +0000
+++ wordlist/alt12dicts/2of12full.txt 2011-02-08 11:59:12.455202478 +0000
@@ -6468,7 +6468,6 @@
12: 12 -# -& calendar
2: 1 1# -& calendar month
2: 1 1# -& calendar year
- 4: 4 -# -& calender
12: 12 -# -& calf
9: 8 1# -& calfskin
3: 3 -# -& Calgary
diff -ru wordlist/alt12dicts/5desk.txt wordlist/alt12dicts/5desk.txt
--- wordlist/alt12dicts/5desk.txt 2011-02-08 11:55:46.548837888 +0000
+++ wordlist/alt12dicts/5desk.txt 2011-02-08 11:58:55.162003701 +0000
@@ -7353,7 +7353,6 @@
Caledonia
Caledonian
calendar
-calender
calendric
calendrical
calends
--- wordlist.orig/scowl/r/special/proper-names 2008-02-08 11:53:27.000000000 +0000
+++ wordlist/scowl/r/special/proper-names 2008-02-08 12:06:00.000000000 +0000
@@ -4,8 +4,11 @@
Barack
Bernanke
Biden
+BitTorrent
Bluetooth
Bugzilla
+Camino
+ChatZilla
Debian
ECMAScript
Emacs
@@ -13,16 +16,21 @@
Facebook
GNU
Gentoo
+Haskell
Hunspell
ISO
Ispell
LyX
+Mandriva
Mozilla
+MySpell
Netflix
PayPal
+SeaMonkey
Roku
SUSE
Slackware
+Sunbird
Thunderbird
Twitter
Ubuntu
--- wordlist.orig/scowl/speller/en.aff 2008-02-08 20:28:24.000000000 +0000
+++ wordlist/scowl/speller/en.aff 2008-02-08 20:28:45.000000000 +0000
@@ -110,13 +110,17 @@
SFX L Y 1
SFX L 0 ment .
-REP 88
+SFX i N 1
+SFX i us i us
+
+REP 90
REP a ei
REP ei a
REP a ey
REP ey a
REP ai ie
REP ie ai
+REP alot a_lot
REP are air
REP are ear
REP are eir
@@ -199,3 +203,4 @@
REP shun tion
REP shun sion
REP shun cion
+REP sitted sat
Summary: Spell checker
Name: aspell
Version: 0.60.6.1
Release: 1%{?dist}
# LGPLv2+ .. common/gettext.h
# LGPLv2 .. modules/speller/default/phonet.hpp,
# modules/speller/default/phonet.cpp,
# modules/speller/default/affix.cpp
# GPLv2+ .. ltmain.sh, misc/po-filter.c
# BSD .. myspell/munch.c
License: LGPLv2+ and LGPLv2 and GPLv2+ and BSD
Group: Applications/Text
URL: http://aspell.net/
Source: ftp://ftp.gnu.org/gnu/aspell/aspell-%{version}.tar.gz
BuildRequires: gnome-sdk-base
%description
GNU Aspell is a spell checker designed to eventually replace Ispell. It can
either be used as a library or as an independent spell checker. Its main
feature is that it does a much better job of coming up with possible
suggestions than just about any other spell checker out there for the
English language, including Ispell and Microsoft Word. It also has many
other technical enhancements over Ispell such as using shared memory for
dictionaries and intelligently handling personal dictionaries when more
than one Aspell process is open at once.
%package devel
Summary: Libraries and header files for Aspell development
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: pkgconfig
%description devel
The aspell-devel package includes libraries
and header files needed for Aspell development.
%prep
%setup -q
iconv -f iso-8859-2 -t utf-8 < manual/aspell.info > manual/aspell.info.aux
mv manual/aspell.info.aux manual/aspell.info
%build
%configure --disable-rpath
sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
make %{?_smp_mflags}
cp scripts/aspell-import examples/aspell-import
chmod 644 examples/aspell-import
cp manual/aspell-import.1 examples/aspell-import.1
%install
# make install DESTDIR=$RPM_BUILD_ROOT doesn't work
%makeinstall
mkdir -p ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60
mv ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60/ispell ${RPM_BUILD_ROOT}%{_bindir}
mv ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60/spell ${RPM_BUILD_ROOT}%{_bindir}
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//nroff-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//sgml-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//context-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//email-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//tex-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60//texinfo-filter.so
chrpath --delete ${RPM_BUILD_ROOT}%{_bindir}/aspell
chrpath --delete ${RPM_BUILD_ROOT}%{_libdir}/libpspell.so.*
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libaspell.la
rm -f ${RPM_BUILD_ROOT}%{_libdir}/libpspell.la
rm -f ${RPM_BUILD_ROOT}%{_libdir}/aspell-0.60/*-filter.la
rm -f ${RPM_BUILD_ROOT}%{_bindir}/aspell-import
rm -f ${RPM_BUILD_ROOT}%{_mandir}/man1/aspell-import.1
%find_lang %{name}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files -f %{name}.lang
%doc README TODO COPYING examples/aspell-import examples/aspell-import.1
%dir %{_libdir}/aspell-0.60
%{_bindir}/a*
%{_bindir}/ispell
%{_bindir}/pr*
%{_bindir}/run-with-aspell
%{_bindir}/spell
%{_bindir}/word-list-compress
%{_libdir}/lib*.so.*
%{_libdir}/aspell-0.60/*
%{_infodir}/aspell.*
%{_mandir}/man1/aspell.1*
%{_mandir}/man1/run-with-aspell.1*
%{_mandir}/man1/word-list-compress.1*
%{_mandir}/man1/prezip-bin.1*
%files devel
%dir %{_includedir}/pspell
%{_bindir}/pspell-config
%{_includedir}/aspell.h
%{_includedir}/pspell/pspell.h
%{_libdir}/lib*spell.so
%{_infodir}/aspell-dev.*
%{_mandir}/man1/pspell-config.1*
%changelog
* Thu Jan 22 2015 Alexander Larsson <alexl@redhat.com> - 0.60.6.1-1
- Initial version
Summary: An Enchanting Spell Checking Library
Name: enchant
Version: 1.6.0
Release: 1%{?dist}
Group: System Environment/Libraries
License: LGPLv2+
Source: http://www.abisource.com/downloads/enchant/%{version}/enchant-%{version}.tar.gz
URL: http://www.abisource.com/
BuildRequires: gnome-sdk-base
BuildRequires: glib2-devel
BuildRequires: hunspell-devel
%description
A library that wraps other spell checking backends.
%package devel
Summary: Support files necessary to compile applications with libenchant.
Group: Development/Libraries
Requires: enchant = %{version}-%{release}
Requires: glib2-devel
%description devel
Libraries, headers, and support files necessary to compile applications using libenchant.
%prep
%setup -q
%build
%configure --enable-myspell --with-myspell-dir=/usr/share/myspell --disable-static --disable-ispell --disable-aspell --disable-hspell --disable-zemberek
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT install
rm -f $RPM_BUILD_ROOT/%{_libdir}/*.la
rm -f $RPM_BUILD_ROOT/%{_libdir}/enchant/*.la
%files
%defattr(-,root,root)
%doc AUTHORS COPYING.LIB README
%{_bindir}/*
%{_libdir}/lib*.so.*
%dir %{_libdir}/enchant
%{_libdir}/enchant/lib*myspell.so*
%{_mandir}/man1/enchant.1*
%{_datadir}/enchant
%files devel
%defattr(-,root,root)
%{_libdir}/*.so
%{_libdir}/pkgconfig/enchant.pc
%{_includedir}/enchant
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
rm -rf $RPM_BUILD_ROOT
%changelog
* Thu Jan 22 2015 Alexander Larsson <alexl@redhat.com> - 1.6.0-1
- Initial version
......@@ -37,6 +37,7 @@ BuildRequires: dconf-devel
BuildRequires: libsecret-devel
BuildRequires: webkitgtk4-devel
BuildRequires: xkeyboard-config-devel
BuildRequires: enchant-devel
Requires: gnome-platform-base
Requires: gtk2 gtk2-immodules
......@@ -73,6 +74,7 @@ Requires: libsecret
Requires: webkitgtk4
Requires: xkeyboard-config
Requires: libxkbcommon libxkbcommon-x11 libwayland-cursor
Requires: enchant
%description
......
......@@ -78,6 +78,8 @@ Requires: webkitgtk4-devel
Requires: libxkbcommon-devel libxkbcommon-x11-devel
Requires: libwayland-client-devel libwayland-cursor-devel mesa-libwayland-egl-devel
Requires: xkeyboard-config-devel
Requires: hunspell-devel
Requires: enchant-devel
%description
Meta package for Gnome SDK dependencies
......
Name: hunspell-en
Summary: English hunspell dictionaries
%define upstreamid 20121024
Version: 0.%{upstreamid}
Release: 1%{?dist}
#svn export https://wordlist.svn.sourceforge.net/svnroot/wordlist/trunk wordlist
Source0: http://pkgs.fedoraproject.org/repo/pkgs/hunspell-en/wordlist-%{upstreamid}.tar.xz/10a7ff0b2209af7d22b14b219b98c9b5/wordlist-%{upstreamid}.tar.xz
Source1: http://pkgs.fedoraproject.org/repo/pkgs/hunspell-en/en_GB.zip/218909136738f4564b81ecd145ade6ee/en_GB.zip
#See http://mxr.mozilla.org/mozilla/source/extensions/spellcheck/locales/en-US/hunspell/mozilla_words.diff?raw=1
Patch0: mozilla_words.patch
Patch1: en_GB-singleletters.patch
Patch2: en_GB.two_initial_caps.patch
#See http://sourceforge.net/tracker/?func=detail&aid=2355344&group_id=10079&atid=1014602
#filter removes words with "." in them
Patch3: en_US-strippedabbrevs.patch
#See https://sourceforge.net/tracker/?func=detail&aid=2987192&group_id=143754&atid=756397
#to allow "didn't" instead of suggesting change to typographical apostrophe
Patch4: hunspell-en-allow-non-typographical.marks.patch
#See https://sourceforge.net/tracker/?func=detail&aid=3012183&group_id=10079&atid=1014602
#See https://bugzilla.redhat.com/show_bug.cgi?id=619577 add SI and IEC prefixes
Patch5: hunspell-en-SI_and_IEC.patch
#See https://sourceforge.net/tracker/?func=detail&aid=3175662&group_id=10079&atid=1014602 obscure Calender hides misspelling of Calendar
Patch6: hunspell-en-calender.patch
#valid English words that are archaic or rare in en-GB but not in en-IE
Patch7: en_IE.supplemental.patch
Group: Applications/Text
URL: http://wordlist.sourceforge.net/
License: LGPLv2+ and LGPLv2 and BSD
BuildArch: noarch
BuildRequires: gnome-sdk-base
BuildRequires: aspell
Requires: hunspell
Requires: hunspell-en-US = %{version}-%{release}
Requires: hunspell-en-GB = %{version}-%{release}
%description
English (US, UK, etc.) hunspell dictionaries
%package US
Requires: hunspell
Summary: US English hunspell dictionaries
Group: Applications/Text
%description US
US English hunspell dictionaries
%package GB
Requires: hunspell
Summary: UK English hunspell dictionaries
Group: Applications/Text
%description GB
UK English hunspell dictionaries
%prep
%setup -q -n wordlist
%setup -q -T -D -a 1 -n wordlist
%patch0 -p1 -b .mozilla
%patch1 -p1 -b .singleletters
%patch2 -p1 -b .two_initial_cap
%patch3 -p1 -b .strippedabbrevs
%patch4 -p1 -b .allow-non-typographical
%patch5 -p1 -b .SI_and_IEC
%patch6 -p1 -b .calender
%patch7 -p1 -b .en_IE
%build
make
cd scowl/speller
make hunspell
for i in README_en_CA.txt README_en_US.txt; do
if ! iconv -f utf-8 -t utf-8 -o /dev/null $i > /dev/null 2>&1; then
iconv -f ISO-8859-1 -t UTF-8 $i > $i.new
touch -r $i $i.new
mv -f $i.new $i
fi
tr -d '\r' < $i > $i.new
touch -r $i $i.new
mv -f $i.new $i
done
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/%{_datadir}/myspell
cp -p en_*.dic en_*.aff $RPM_BUILD_ROOT/%{_datadir}/myspell
cd scowl/speller
cp -p en_*.dic en_*.aff $RPM_BUILD_ROOT/%{_datadir}/myspell
pushd $RPM_BUILD_ROOT/%{_datadir}/myspell/
en_GB_aliases="en_AG en_AU en_BS en_BW en_BZ en_DK en_GH en_HK en_IE en_IN en_JM en_MW en_NA en_NG en_NZ en_SG en_TT en_ZA en_ZM en_ZW"
for lang in $en_GB_aliases; do
ln -s en_GB.aff $lang.aff
ln -s en_GB.dic $lang.dic
done
en_US_aliases="en_PH"
for lang in $en_US_aliases; do
ln -s en_US.aff $lang.aff
ln -s en_US.dic $lang.dic
done
popd
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc scowl/speller/README_en_CA.txt
%{_datadir}/myspell/*
%exclude %{_datadir}/myspell/en_GB.*
%exclude %{_datadir}/myspell/en_US.*
%files US
%defattr(-,root,root,-)
%doc scowl/speller/README_en_US.txt
%{_datadir}/myspell/en_US.*
%files GB
%defattr(-,root,root,-)
%doc README_en_GB.txt
%{_datadir}/myspell/en_GB.*
%changelog
* Thu Jan 22 2015 Alexander Larsson <alexl@redhat.com> - 0.20121024-9
- Initial version