A new user interface for you!

File goldendict.spec of Package goldendict

# spec file for package goldendict
# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright 2008-2009 Buschmann <buschmann23@opensuse.org>
# 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/

Name:           goldendict
Summary:        Dictionary Lookup Program
License:        GPL-3.0+
Group:          Productivity/Office/Dictionary
Version:        1.0.1
Release:        0
Source0:        %{name}-%{version}.tar.xz
#The newest .tar.gz ball can be downloaded from:
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

BuildRequires:  c++_compiler make eb-devel libebl-devel
BuildRequires:  hunspell-devel >= 1.2.4
BuildRequires:  pkgconfig(Qt5Core)
BuildRequires:  pkgconfig(Qt5Gui)
BuildRequires:  pkgconfig(Qt5Help)
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(x11)
BuildRequires:  pkgconfig(xtst)
BuildRequires:  phonon-devel
BuildRequires:  libvorbis-devel
BuildRequires:  libao-devel
BuildRequires:  libpng-devel
%if 0%{?suse_version} <= 1230
BuildRequires:  libjpeg62-devel
BuildRequires:  libjpeg-devel
BuildRequires:  libtiff-devel
BuildRequires:  libzip-devel
BuildRequires:  zlib-devel
BuildRequires:  libbz2-devel
BuildRequires:  lzo-devel
BuildRequires:  xz-devel
BuildRequires:  git
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(libavformat)
%if 0%{?suse_version}
BuildRequires:  update-desktop-files

Url:            http://goldendict.org

Feature-rich dictionary lookup program.
    * Use of WebKit for an accurate articles' representation, complete with
      all formatting, colors, images and links.
    * Support of multiple dictionary file formats:
      * Babylon .BGL files
      * StarDict .ifo/.dict/.idx/.syn dictionaries
      * Dictd .index/.dict(.dz) dictionary files
      * ABBYY Lingvo .dsl source files
      * ABBYY Lingvo .lsa/.dat audio archives
    * Support for Wikipedia, Wiktionary or any other MediaWiki-based sites
    * Scan popup functionality. A small window pops up with translation of a
      word chosen from antoher application.
    * And much more...

    Konstantin Isakov

%setup -n %{name}-%{version} -q
git init

# insist on correct prefix
sed -i 's:/usr/local:/usr:g' goldendict.pro

%qmake5 \
    PREFIX=%{_prefix} "CONFIG+=zim_support" "CONFIG+=old_hunspell"
make %{?jobs:-j %jobs}

MD5SUM=$(md5sum LICENSE.txt | sed 's/ .*//')
if test -f /usr/share/doc/licenses/md5/$MD5SUM ; then
	ln -sf /usr/share/doc/licenses/md5/$MD5SUM LICENSE

%suse_update_desktop_file -r %{name} Office Dictionary

install -d %{buildroot}/%{_datadir}/%{name}/locale  
install -m 644 locale/*.qm %{buildroot}/%{_datadir}/%{name}/locale

rm -rf %{buildroot}/%{_datadir}/app-install  

  rm -rf $RPM_BUILD_ROOT

%doc LICENSE.txt