Multiple packaging changes

- The dictionary data directory will now be /usr/lib/voikko on all architectures
- Create and own /usr/lib/voikko, so different dictionary packages can own the subdirectories there
- This was suggested in the review of the voikko-fi package, see rhbz#1919688
- Use the license macro
This commit is contained in:
Ville-Pekka Vainio 2021-01-31 21:39:04 +02:00
parent 374ff8b09f
commit dae3fb1ad5

View File

@ -2,7 +2,7 @@
Name: libvoikko
Version: 4.3
Release: 2%{?dist}
Release: 3%{?dist}
Summary: Voikko is a library for spellcheckers and hyphenators
License: GPLv2+
@ -74,7 +74,9 @@ tasks on Finnish text.
%build
# Use vfst for now, no hfst yet. We need to package hfst-ospell for the hfst dictionaries.
# Use /usr/lib/voikko for the dictionaries, this is where the voikko-fi package will put them.
%configure --disable-hfst --with-dictionary-path=/usr/lib/voikko
# The dictonary path has been agreed on in reviews and fedora-devel discussions.
# This way the voikko-fi package can be noarch.
%configure --disable-hfst --with-dictionary-path=%{_prefix}/lib/voikko
# Remove rpath,
# https://fedoraproject.org/wiki/Packaging/Guidelines#Removing_Rpath
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
@ -90,10 +92,14 @@ find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} ';'
# Install the Python interface
install -d $RPM_BUILD_ROOT%{python3_sitelib}
install -pm 0644 python/libvoikko.py $RPM_BUILD_ROOT%{python3_sitelib}/
# Make the directory for the dictionary data files, so this package can own it.
mkdir -p %{buildroot}%{_prefix}/lib/voikko
%files
%doc ChangeLog COPYING README
%doc ChangeLog README
%license COPYING
%dir %{_prefix}/lib/voikko
%{_libdir}/libvoikko.so.1*
%files -n voikko-tools
@ -115,6 +121,12 @@ install -pm 0644 python/libvoikko.py $RPM_BUILD_ROOT%{python3_sitelib}/
%pycached %{python3_sitelib}/%{name}.py
%changelog
* Sun Jan 31 2021 Ville-Pekka Vainio <vpvainio AT iki.fi> - 4.3-3
- The dictionary data directory will now be /usr/lib/voikko on all architectures
- Create and own /usr/lib/voikko, so different dictionary packages can own the subdirectories there
- This was suggested in the review of the voikko-fi package, see rhbz#1919688
- Use the license macro
* Sun Jan 24 2021 Ville-Pekka Vainio <vpvainio AT iki.fi> - 4.3-2
- Bump release for a new Copr build
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild