File goldendict.spec of Package goldendict
#
# spec file for package goldendict
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define _name org.goldendict.GoldenDict
Name: goldendict
Version: 1.5.0_RC2
Release: 0
Summary: Dictionary Lookup Program
License: GPL-3.0
Group: Productivity/Office/Dictionary
Url: https://github.com/goldendict/goldendict
Source: %{name}-%{version}.tar.xz
BuildRequires: cmake
BuildRequires: cmake(Qt5LinguistTools)
BuildRequires: eb-devel
BuildRequires: gcc-c++
BuildRequires: git
BuildRequires: kf5-filesystem
BuildRequires: lzo-devel
BuildRequires: pkgconfig(Qt5Core)
BuildRequires: pkgconfig(Qt5Gui)
BuildRequires: pkgconfig(Qt5Help)
BuildRequires: pkgconfig(Qt5Multimedia)
BuildRequires: pkgconfig(Qt5Network)
BuildRequires: pkgconfig(Qt5PrintSupport)
BuildRequires: pkgconfig(Qt5Sql)
BuildRequires: pkgconfig(Qt5Svg)
BuildRequires: pkgconfig(Qt5WebKitWidgets)
BuildRequires: pkgconfig(Qt5Widgets)
BuildRequires: pkgconfig(Qt5X11Extras)
BuildRequires: pkgconfig(Qt5Xml)
BuildRequires: pkgconfig(bzip2)
BuildRequires: pkgconfig(hunspell)
BuildRequires: pkgconfig(liblzma)
BuildRequires: pkgconfig(libtiff-4)
BuildRequires: pkgconfig(libzstd)
BuildRequires: pkgconfig(ogg)
BuildRequires: pkgconfig(opencc)
BuildRequires: pkgconfig(vorbis)
BuildRequires: pkgconfig(vorbisfile)
BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(xtst)
BuildRequires: pkgconfig(zlib)
BuildRequires: update-desktop-files
# INTERNAL PLAYER
BuildRequires: pkgconfig(ao)
BuildRequires: ffmpeg-devel
#uildRequires: libavcodec-devel
#uildRequires: libavformat-devel
#uildRequires: pkgconfig(libavutil)
Recommends: %{name}-lang
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
The program has the following features:
* Use of WebKit for an accurate articles' representation, complete with all
formatting, colors, images and links.
* Support of multiple dictionary file formats, namely:
* Babylon .BGL files, complete with images and resources
* StarDict .ifo/.dict./.idx/.syn dictionaries
* Dictd .index/.dict(.dz) dictionary files
* ABBYY Lingvo .dsl source files, together with abbreviations. The files can
be optionally compressed with dictzip. Dictionary resources can be packed
together into a .zip file.
* ABBYY Lingvo .lsa/.dat audio archives. Those can be indexed separately, or
be referred to from .dsl files.
* Support for Wikipedia, Wiktionary, or any other MediaWiki-based sites to
perform lookups in.
* Ability to use arbitrary websites as dictionaries via templated Url patterns.
* Ability to run arbitrary external programs for audio playback or content
generation (text-to-speech, man pages etc) (use the latest Git version for this)
* Support for looking up and listening to pronunciations from forvo.com
* Hunspell-based morphology system, used for word stemming and spelling suggestions.
* Ability to index arbitrary directories with audio files for pronunciation lookups.
* Full Unicode case, diacritics, punctuation and whitespace folding. This
means the ability to type in words without any accents, correct case,
punctuation or spaces (e.g. typing 'Grussen' would yield 'grüßen' in German
dictionaries).
* Scan popup functionality. A small window pops up with the translation of a
word chosen from another application.
* Support for global hotkeys. You can spawn the program window at any point,
or directly translate a word from the clipboard.
* Tabbed browsing in a modern Qt 4 interface.
* Cross-platform: Linux/X11 and Windows + portable to others.
* Free software: GNU GPLv3+ license.
%lang_package
%prep
%setup -q
%build
%qmake5 \
%if 0%{?suse_version} < 1320
"CONFIG+=old_hunspell" \
%endif
"CONFIG+=zim_support" \
PREFIX=%{_prefix} \
%{name}.pro
%make_jobs
%install
%qmake5_install
%suse_update_desktop_file -r %{_name} Office Dictionary
%files
%defattr(-,root,root)
%doc CREDITS.txt LICENSE.txt README.md
%{_bindir}/%{name}
%{_datadir}/%{name}
%{_kf5_appstreamdir}/%{_name}.metainfo.xml
%defattr(644,root,root,755)
%{_datadir}/applications/%{_name}.desktop
%{_datadir}/pixmaps/%{name}.png
%exclude %{_datadir}/%{name}/locale
%files lang
%defattr(-,root,root)
%dir %{_datadir}/%{name}/locale
%{_datadir}/%{name}/locale/*.qm
%changelog