File kchmviewer.spec of Package kchmviewer

#
# spec file for package kchmviewer (Version 4.1)
#
# Copyright (c) 2009 SUSE LINUX Products 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/
#

# norootforbuild


Name:           kchmviewer
BuildRequires:  libkde4-devel
BuildRequires:  chmlib-devel
License:        GPL v3 only
Group:          Productivity/Office/Other
Summary:        KDE chm Viewer (MS Windows Compressed HTML Documents)
Version:        4.1
Release:        2
Url:            http://www.kchmviewer.net/
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Source:         %name-%version.tar.bz2

%description
This is a viewer for the chm files known from the MS Windows world. It
supports complex searching for large books and has various viewing
features.



Authors:
--------
    <tim@krasnogorsk.ru>

%prep 
%setup -q

%build
  %cmake_kde4 -d build
  %make_jobs

%install
  pushd build
  %makeinstall
  popd
  %suse_update_desktop_file -G "Compressed HTML Viewer" %name  Office Viewer
  %kde_post_install
  %find_lang %name
  for i in {64,128}; do
     mkdir -p $RPM_BUILD_ROOT/usr/share/icons/hicolor/"$i"x"$i"/apps
     cp $RPM_BUILD_ROOT/usr/share/icons/crystalsvg/"$i"x"$i"/apps/kchmviewer.png $RPM_BUILD_ROOT/usr/share/icons/hicolor/"$i"x"$i"/apps/;
  done

%clean
rm -rf $RPM_BUILD_ROOT

%files -f %name.lang
%defattr(-,root,root)
/usr/bin/kchmviewer
%_libdir/kde4/kio_msits.so
/usr/share/applications/kde4/kchmviewer.desktop
/usr/share/icons/*/*/apps/kchmviewer.*
/usr/share/kde4/services/msits.protocol

%changelog
openSUSE Build Service is sponsored by