a6587b
Name:           libvoikko
a6587b
Version:        4.1.1
a6587b
Release:        2%{?dist}
a6587b
Summary:        Voikko is a library for spellcheckers and hyphenators
a6587b
a6587b
Group:          System Environment/Libraries
a6587b
License:        GPLv2+
a6587b
URL:            http://voikko.puimula.org
a6587b
# The usual format of stable release URLs
a6587b
Source0:        http://www.puimula.org/voikko-sources/%{name}/%{name}-%{version}.tar.gz
a6587b
# The usual format of test release URLs
a6587b
#Source0:        http://www.puimula.org/htp/testing/%%{name}-%%{version}rc1.tar.gz
a6587b
a6587b
BuildRequires:  gcc-c++
a6587b
BuildRequires:  python3-devel
a6587b
# Require the Finnish morphology because Finnish is currently the only language
a6587b
# supported by libvoikko in Fedora.
a6587b
Requires:       malaga-suomi-voikko
a6587b
a6587b
%description
a6587b
This is libvoikko, library for spellcheckers and hyphenators using Malaga
a6587b
natural language grammar development tool. The library is written in C.
a6587b
a6587b
Currently only Finnish is supported, but the API of the library has been
a6587b
designed to allow adding support for other languages later. Note however that
a6587b
Malaga is rather low level tool that requires implementing the whole morphology
a6587b
of a language as a left associative grammar. Therefore languages that have
a6587b
simple or even moderately complex morphologies and do not require morphological
a6587b
analysis in their hyphenators should be implemented using other tools such as
a6587b
Hunspell.
a6587b
a6587b
%package        devel
a6587b
Summary:        Development files for %{name}
a6587b
Group:          Development/Libraries
a6587b
Requires:       %{name}%{?_isa} = %{version}-%{release}
a6587b
Requires:       pkgconfig
a6587b
a6587b
%description    devel
a6587b
The %{name}-devel package contains libraries and header files for
a6587b
developing applications that use %{name}.
a6587b
a6587b
%package -n     voikko-tools
a6587b
Summary:        Test tools for %{name}
a6587b
Group:          Applications/Text
a6587b
Requires:       %{name}%{?_isa} = %{version}-%{release}
a6587b
a6587b
%description -n voikko-tools
a6587b
This package contains voikkospell and voikkohyphenate, small command line
a6587b
tools for testing libvoikko. These tools may also be useful for shell
a6587b
scripts.
a6587b
a6587b
%package -n python3-libvoikko
a6587b
Summary:        Python interface to %{name}
a6587b
Group:          Development/Libraries
a6587b
Requires:       %{name} = %{version}-%{release}
a6587b
BuildArch:      noarch
a6587b
%{?python_provide:%python_provide python3-libvoikko}
a6587b
a6587b
%description -n python3-libvoikko
a6587b
Python interface to libvoikko, library of Finnish language tools.
a6587b
This module can be used to perform various natural language analysis
a6587b
tasks on Finnish text.
a6587b
a6587b
%prep
a6587b
%setup -q
a6587b
a6587b
a6587b
%build
a6587b
# The dictionary path must be the same where malaga-suomi-voikko is installed
a6587b
# Use malaga for now, no hfst or vfst. We need to package foma for the vfst dictionaries.
a6587b
%configure --with-dictionary-path=%{_libdir}/voikko --disable-hfst --disable-vfst --disable-buildtools --enable-malaga
a6587b
# Remove rpath,
a6587b
# https://fedoraproject.org/wiki/Packaging/Guidelines#Removing_Rpath
a6587b
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
a6587b
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
a6587b
make %{?_smp_mflags} CXXFLAGS="$CXXFLAGS"
a6587b
a6587b
a6587b
%install
a6587b
make install INSTALL="install -p" DESTDIR=$RPM_BUILD_ROOT
a6587b
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
a6587b
# Remove static archive
a6587b
find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} ';'
a6587b
# Install the Python interface
a6587b
install -d $RPM_BUILD_ROOT%{python3_sitelib}
a6587b
install -pm 0644 python/libvoikko.py $RPM_BUILD_ROOT%{python3_sitelib}/
a6587b
a6587b
%post -p /sbin/ldconfig
a6587b
a6587b
%postun -p /sbin/ldconfig
a6587b
a6587b
a6587b
%files
a6587b
%doc ChangeLog COPYING README
a6587b
%{_libdir}/*.so.*
a6587b
a6587b
%files -n voikko-tools
a6587b
%{_bindir}/voikkospell
a6587b
%{_bindir}/voikkohyphenate
a6587b
%{_bindir}/voikkogc
a6587b
%{_mandir}/man1/voikkohyphenate.1*
a6587b
%{_mandir}/man1/voikkospell.1*
a6587b
%{_mandir}/man1/voikkogc.1*
a6587b
a6587b
%files devel
a6587b
%{_includedir}/*
a6587b
%{_libdir}/*.so
a6587b
%{_libdir}/pkgconfig/libvoikko.pc
a6587b
a6587b
%files -n python3-libvoikko
a6587b
%{python3_sitelib}/%{name}.py*
a6587b
%if ! 0%{?flatpak}
a6587b
%{python3_sitelib}/__pycache__/*
a6587b
%endif
a6587b
a6587b
%changelog
a6587b
* Thu Nov 26 2020 Mike FABIAN <mfabian@redhat.com> - 4.1.1-2
a6587b
- Fix man file names for Flatpak builds, exclude __pycache__ files from Flatpak builds
a6587b
- Resolves: rhbz#1896322
a6587b
a6587b
* Thu Oct 04 2018 Mike FABIAN <mfabian@redhat.com> - 4.1.1-1
a6587b
- Rebase to 4.1.1 from Fedora 29 (provides only python3-libvoikko,
a6587b
  removes python2-libvoikko)
a6587b
- Resolves: rhbz#1636062
a6587b
a6587b
* Wed May 23 2018 Mike FABIAN <mfabian@redhat.com> - 3.8-9
a6587b
- Add python3-devel to BuildRequires.
a6587b
- Resolves: rhbz#1580782
a6587b
a6587b
* Thu Apr 19 2018 Mike FABIAN <mfabian@redhat.com> - 3.8-8
a6587b
- Build Python 2 subpackage only for Fedora
a6587b
- Resolves: rhbz#1566121
a6587b
a6587b
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.8-7
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
a6587b
a6587b
* Sat Aug 19 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 3.8-6
a6587b
- Python 2 binary package renamed to python2-libvoikko
a6587b
  See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3
a6587b
a6587b
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.8-5
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
a6587b
a6587b
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.8-4
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
a6587b
a6587b
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.8-3
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
a6587b
a6587b
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.8-2
a6587b
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
a6587b
a6587b
* Thu Jul 14 2016 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.8-1
a6587b
- New upstream release
a6587b
a6587b
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.7.1-4
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
a6587b
a6587b
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7.1-3
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
a6587b
a6587b
* Sat May 02 2015 Kalev Lember <kalevlember@gmail.com> - 3.7.1-2
a6587b
- Rebuilt for GCC 5 C++11 ABI change
a6587b
a6587b
* Sat Oct 25 2014 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.7.1-1
a6587b
- New upstream release
a6587b
a6587b
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7-3
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
a6587b
a6587b
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
a6587b
a6587b
* Sun Jan 26 2014 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.7-1
a6587b
- New upstream release
a6587b
a6587b
* Fri Oct 18 2013 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.6.1-1
a6587b
- New upstream release
a6587b
- Remove voikkovfstc from the package, it is not built by default anymore
a6587b
- Update upstream URLs
a6587b
a6587b
* Mon Jul 29 2013 Parag <paragn AT fedoraproject DOT org> - 3.6-2
a6587b
- Ah don't add %%{?_isa} for noarch packages
a6587b
a6587b
* Mon Jul 29 2013 Parag <paragn AT fedoraproject DOT org> - 3.6-2
a6587b
- Fix spec file to follow packaging guidelines
a6587b
a6587b
* Sun Apr 14 2013 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.6-1
a6587b
- New upstream release
a6587b
a6587b
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.5-3
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
a6587b
a6587b
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.5-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
a6587b
a6587b
* Sun Jul 01 2012 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.5-1
a6587b
- New upstream release
a6587b
a6587b
* Tue Feb 28 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.4.1-2
a6587b
- Rebuilt for c++ ABI breakage
a6587b
a6587b
* Sat Feb 04 2012 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.4.1-1
a6587b
- New upstream release, fixes build with GCC 4.7
a6587b
a6587b
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.4-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
a6587b
a6587b
* Tue Dec 27 2011 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.4-1
a6587b
- Update to the latest upstream release:
a6587b
- A crash bug affecting grammar checker has been fixed.
a6587b
- New grammar checker rule for missing verbs has been added.
a6587b
a6587b
* Sun Sep 25 2011 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.3.1-0.3.rc1
a6587b
- Remove the isa macro from the malaga-suomi-voikko dependency,
a6587b
  malaga-suomi-voikko is not a library and is thus not multilib'd. The previous
a6587b
  change was a misunderstanding.
a6587b
a6587b
* Sat Sep 24 2011 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.3.1-0.2.rc1
a6587b
- Add the isa macro to the malaga-suomi-voikko dependency and drop the version.
a6587b
a6587b
* Sat Sep 24 2011 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.3.1-0.1.rc1
a6587b
- New upstream release candidate, fixes a bug which crashed Firefox when
a6587b
  using Finnish spell checking.
a6587b
a6587b
* Fri Sep 16 2011 Ville-Pekka Vainio <vpvainio AT iki.fi> - 3.3-1
a6587b
- New upstream release
a6587b
a6587b
* Sun Jun 12 2011 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.2.1-1
a6587b
- New upstream release
a6587b
- Fixes handling of embedded null characters in input strings entered through
a6587b
  Python or Java interfaces.
a6587b
a6587b
* Fri Mar 25 2011 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.2-1
a6587b
- New upstream release
a6587b
a6587b
* Tue Feb 15 2011 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.1-3
a6587b
- Add patch to fix build with GCC 4.6
a6587b
a6587b
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
a6587b
a6587b
* Mon Nov 22 2010 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.1-1
a6587b
- New upstream release
a6587b
- Remove the unneeded %%clean section, not needed in Fedora >= 13
a6587b
a6587b
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 3.0-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
a6587b
a6587b
* Thu May 27 2010 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.0-1
a6587b
- 3.0 final
a6587b
a6587b
* Thu May 13 2010 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 3.0-0.1.rc1
a6587b
- New upstream release candidate with multithread support
a6587b
- Remove unneeded BuildRoot tag
a6587b
a6587b
* Thu Feb 18 2010 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.3.1-1
a6587b
- Version 2.3.1 contains fixes for bugs found in version 2.3
a6587b
a6587b
* Sun Jan 31 2010 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.3-0.1.rc1
a6587b
- New release candidate
a6587b
- Dependency on glib has been removed
a6587b
a6587b
* Wed Nov 11 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2.2-1
a6587b
- Version 2.2.2 fixes a crash found in version 2.2.1 that can occur when the
a6587b
  APIs that use wchar_t strings as arguments are used.
a6587b
a6587b
* Mon Oct 26 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2.1-2
a6587b
- Add Python interface (package python-libvoikko, noarch)
a6587b
a6587b
* Fri Oct 09 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2.1-1
a6587b
- New upstream release, fixes bugs found in 2.2
a6587b
a6587b
* Fri Sep 18 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2-0.3.rc2
a6587b
- 2.2rc2
a6587b
- Remove getcwd() value check patch, accepted upstream
a6587b
a6587b
* Wed Sep 16 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2-0.2.rc1
a6587b
- Remove rpath which was set for the voikko-tools binaries in 64 bit
a6587b
  architechtures
a6587b
a6587b
* Tue Sep 15 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.2-0.1.rc1
a6587b
- New release candidate
a6587b
- Improvements to spelling suggestions, grammar checker etc.
a6587b
- Libvoikko now uses its own internal implementation of malaga.
a6587b
- This prevents symbol conflicts such as https://bugzilla.redhat.com/502546
a6587b
- BuildRequires malaga removed and glib2-devel added.
a6587b
- Require malaga-suomi-voikko >= 1.4, libvoikko 2.2 expects the newer
a6587b
  dictionary format
a6587b
- Add a patch to make it compile on Fedora with -Werror
a6587b
a6587b
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
a6587b
a6587b
* Sat May 2 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-1
a6587b
- 2.1 final, including fixes to grammar checking
a6587b
a6587b
* Fri Apr 17 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-0.5.rc4
a6587b
- 2.1rc4:
a6587b
  - Fix invalid use of delete vs. delete[]
a6587b
  - Limit the scope of some variables
a6587b
a6587b
* Mon Apr 13 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-0.4.rc3
a6587b
- 2.1rc3, remove patch
a6587b
a6587b
* Sat Apr 11 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-0.3.rc2
a6587b
- Patch to current SVN HEAD, includes a fix for a memory leak in the grammar
a6587b
  checker
a6587b
a6587b
* Mon Apr 6 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-0.2.rc2
a6587b
- New release candidate
a6587b
- Both patches applied upstream
a6587b
a6587b
* Mon Apr 6 2009 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.1-0.1.rc1
a6587b
- New release candidate
a6587b
- Improvements on grammar checking and dictionary loading
a6587b
- Raise malaga-suomi-voikko dependency to 1.3-10, which has the new dictionary
a6587b
  data directory layout needed by this version of libvoikko
a6587b
- Add BuildRequires python for running the trie compiler during build
a6587b
- Add patch for GCC 4.4 and glibc 2.90 compliance
a6587b
- Add patch to fix warn_unused_result errors
a6587b
a6587b
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0-2
a6587b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
a6587b
a6587b
* Thu Aug 28 2008 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.0-1
a6587b
- libvoikko 2.0
a6587b
a6587b
* Sat Aug 23 2008 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 2.0-0.1.rc1
a6587b
- New release candidate, including the new voikkogc tool in voikko-tools
a6587b
- Add defattr to voikko-tools
a6587b
- Drop upstreamed pkg-config patch
a6587b
a6587b
* Fri May 30 2008 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 1.7-3
a6587b
- Add Requires pkgconfig to -devel
a6587b
a6587b
* Mon May 26 2008 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 1.7-2
a6587b
- Add patch which makes a libvoikko.pc file for pkg-config
a6587b
a6587b
* Sat May 24 2008 Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> - 1.7-1
a6587b
- libvoikko 1.7
a6587b
a6587b
* Thu May 22 2008 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.7-0.2.rc2
a6587b
- Don't BuildRequire the Finnish data files, this should make Koji builds a bit
a6587b
  quicker
a6587b
a6587b
* Sun May 11 2008 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.7-0.1.rc2
a6587b
- New release candidate
a6587b
a6587b
* Sun Mar 02 2008 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-3
a6587b
- Put voikkospell and voikkohyphenate into a separate voikko-tools
a6587b
  subpackage to decrease the size of the binary libvoikko package
a6587b
a6587b
* Sat Feb 16 2008 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-2
a6587b
- Rebuild for GCC 4.3
a6587b
a6587b
* Tue Dec 04 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-1
a6587b
- libvoikko 1.6
a6587b
- Add versioned BuildRequires and Requires as per the Voikko release notes
a6587b
  at http://voikko.sourceforge.net/releases.html
a6587b
a6587b
* Mon Dec 03 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-0.4.rc4
a6587b
- Upstream released a new release candidate
a6587b
a6587b
* Wed Nov 28 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-0.3.rc3
a6587b
- Upstream released a new release candidate
a6587b
a6587b
* Wed Nov 28 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-0.2.rc2
a6587b
- Upstream released a new release candidate
a6587b
a6587b
* Tue Nov 27 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.6-0.1.rc1
a6587b
- Upstream released a new release candidate
a6587b
a6587b
* Thu Nov 08 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.5-1
a6587b
- Bump Release for the first Fedora build
a6587b
a6587b
* Wed Nov 07 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.5-0.3
a6587b
- libvoikko-devel: remove unneeded Requires: malaga-devel
a6587b
- install with -p so that timestamps are preserved
a6587b
a6587b
* Wed Nov 07 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.5-0.2
a6587b
- Requires only malaga-suomi-voikko, BR malaga-devel and malaga-suomi-voikko
a6587b
- Remove static archive
a6587b
a6587b
* Wed Oct 24 2007 - Ville-Pekka Vainio <vpivaini AT cs.helsinki.fi> 1.5-0.1
a6587b
- Initial package