File kdeutils3.spec of Package kdeutils3

#
# spec file for package kdeutils3 (Version 3.5.10)
#
# Copyright (c) 2010 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/
#


Name:           kdeutils3
BuildRequires:  gmp-devel
BuildRequires:  kdebase3-devel
BuildRequires:  net-snmp-devel
BuildRequires:  pcsc-lite
BuildRequires:  python-devel
%ifarch ppc
BuildRequires:  pbbuttonsd
%endif
Version:        3.5.10
Release:        1
License:        GPL-2.0+
Summary:        KDE Utility Programs
Url:            http://www.kde.org
Group:          Productivity/File utilities
Source0:        kdeutils-%{version}.tar.bz2
Patch0:         3_5_BRANCH.diff
Patch2:         klaptop.diff
Patch5:         disable-nonsense-security-check.diff
Patch11:        ppc.dif
Patch13:        FIXME.diff
Patch14:        ark-decoding.diff
# PATCH-FIX-UPSTREAM ark-rar_encrypted.patch ark-rar_encrypted.patch kde#35371 jm82an4zn1@sxipper.net
# -- fixes open/extract rar archives with encrypted header
Patch15:        ark-rar_encrypted.patch
# This patch replaces the old MPL-licensed headers with newer ones, licensed under GPL-2.0
# The files are taken directly from the Linux kernel sources
Patch16:        trinity-r1254856-replace-linux-headers.diff
Patch17:        kdeutils-3.5.8-alt-ark-arj-format.patch
Patch18:        kdeutils-3.5.8-alt-ark-rar-password.patch
Patch19:        kdeutils-3.5.8-alt-ark-zip-password.patch
Patch20:        kdeutils-3.5.8-alt-create-password-zip-rar-7zip.patch

BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
A couple of utility programs for KDE.

* ark           - archiver tool

* kcalc         - calculator tool

* kdepasswd     - tool that changes the user login password

* kdf           - tool that shows free space on disk

* kfloppy       - floppy formatter

* kgpg          - gpg key manager

* kwalletmanager - manager for showing and modifying passwords of
kwallet

%package devel
License:        GPL-2.0+
Summary:        Include Files and Libraries mandatory for Development
Group:          Development/Libraries/KDE

%description devel
This package contains all necessary include files and libraries needed
to develop applications that require these.

%package extra
License:        GPL-2.0+
Summary:        KDE Utility Programs
Group:          System/GUI/KDE
# usesubdirs khexedit kedit ktimer kcharselect charselectapplet kregexpeditor kjots
Provides:       kdeutils3:/opt/kde3/bin/kedit

%description extra
Small applications not used by most people.

kcharselect - browse characters

kedit       - the old KDE text editor

khexedit    - hex editor

kjots       - an application for notes

ktimer      - a timing application

SuperKaramba - a tool that allows one to easily use interactive
eye-candy

%package laptop
License:        GPL-2.0+
Summary:        KDE utility programs for laptop users
Group:          Hardware/Mobile

%description laptop
Support for various types of hardware input devices that exist, such as
those on keyboards. It contains:

* kmilo     - tool that enables special keys on some keyboards

%prep
%setup -q -n kdeutils-%{version}
%patch0
%patch17 -p1
%patch18 -p1
%patch19 -p1
%patch20 -p1
%patch2
%patch5
%ifarch ppc ppc64
%patch11
%endif
%patch13
%patch14
%patch15
pushd klaptopdaemon/linux
%patch16
popd
sed -i 1i\ '#define HAVE_STRLCAT' ksim/monitors/snmp/snmp.cpp
sed -i 1i\ '#define HAVE_STRLCAT' ksim/monitors/snmp/value.cpp
sed -i 1i\ '#define HAVE_STRLCAT' ksim/monitors/snmp/session.cpp

%ifarch s390 s390x
rm -rf kfloppy doc/kfloppy
%endif
rm -rf klaptopdaemon
. /etc/opt/kde3/common_options
update_admin

%build
. /etc/opt/kde3/common_options
DO_NOT_COMPILE=kdessh
%if 0%{?suse_version} >= 1140
sed -i 's/2.6/2.7/g' ./configure
%endif
./configure $configkde
make %{?_smp_mflags}

%install
. /etc/opt/kde3/common_options
make DESTDIR=%{buildroot} $INSTALL_TARGET
# remove unwanted files
%suse_update_desktop_file KEdit       Utility TextEditor
%suse_update_desktop_file superkaramba Utility DesktopUtility
%suse_update_desktop_file KCharSelect Utility Accessibility
%suse_update_desktop_file khexedit    Utility Editor
%suse_update_desktop_file Kjots       Utility TimeUtility
%suse_update_desktop_file ktimer      Utility TimeUtility
%suse_update_desktop_file kwikdisk    System  Applet
%suse_update_desktop_file kdf         System  Filesystem
%suse_update_desktop_file ark         System  Archiving
%suse_update_desktop_file kcalc       Utility Calculator
%suse_update_desktop_file kgpg        Utility Security
%suse_update_desktop_file irkick      Applet
%suse_update_desktop_file kwalletmanager Applet
%suse_update_desktop_file kregexpeditor  Utility Editor
%suse_update_desktop_file kcmdf
%suse_update_desktop_file kcmlirc
%suse_update_desktop_file kwalletconfig
%suse_update_desktop_file thinkpad
%suse_update_desktop_file kvaio
%ifnarch s390 s390x
%suse_update_desktop_file KFloppy     System  Filesystem
%endif
kde_post_install

%clean
rm -rf %{buildroot}

%post extra -p /sbin/ldconfig

%postun extra -p /sbin/ldconfig

%post laptop -p /sbin/ldconfig

%postun laptop -p /sbin/ldconfig

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%dir /opt/kde3/share/icons/*/*/mimetypes
%dir /opt/kde3/share/icons/hicolor/16x16
%dir /opt/kde3/share/icons/hicolor/16x16/apps
%dir /opt/kde3/share/icons/hicolor/16x16/devices
%dir /opt/kde3/share/icons/hicolor/32x32
%dir /opt/kde3/share/icons/hicolor/32x32/apps
%dir /opt/kde3/share/icons/*/scalable/apps
%dir /opt/kde3/share/config.kcfg
/opt/kde3/bin/ark
/opt/kde3/bin/irkick
/opt/kde3/bin/kcalc
/opt/kde3/bin/kd*
/opt/kde3/bin/kgpg
/opt/kde3/bin/kw*
/opt/kde3/%{_lib}/kde3/ark.*
/opt/kde3/%{_lib}/kde3/irkick.*
/opt/kde3/%{_lib}/kde3/kcalc.*
%exclude /opt/kde3/%{_lib}/kde3/kcm_kvaio*
/opt/kde3/%{_lib}/kde3/kcm_k*
/opt/kde3/%{_lib}/kde3/ksim_*
/opt/kde3/%{_lib}/kde3/libarkpart.*
/opt/kde3/%{_lib}/libkdeinit_ark.*
/opt/kde3/%{_lib}/libkdeinit_irkick.*
/opt/kde3/%{_lib}/libkdeinit_kcalc.*
/opt/kde3/%{_lib}/libksimcore.*
/opt/kde3/share/applications/kde/ark.desktop
/opt/kde3/share/applications/kde/irkick.desktop
/opt/kde3/share/applications/kde/kc*
/opt/kde3/share/applications/kde/kd*
/opt/kde3/share/applications/kde/kgpg.desktop
#/opt/kde3/share/applications/kde/ksim.desktop
/opt/kde3/share/applications/kde/kw*
/opt/kde3/share/apps/ark
/opt/kde3/share/apps/irkick
/opt/kde3/share/apps/kcalc
/opt/kde3/share/apps/kconf_update/kcalcrc.upd
/opt/kde3/share/apps/kdf
/opt/kde3/share/apps/kgpg
/opt/kde3/share/apps/kicker/extensions/ksim.desktop
/opt/kde3/share/apps/konqueror
/opt/kde3/share/apps/ksim
/opt/kde3/share/apps/kwalletmanager
/opt/kde3/share/apps/profiles
/opt/kde3/share/apps/remotes
/opt/kde3/share/autostart/*
%config /opt/kde3/share/config/*rc
%doc %lang(en) /opt/kde3/share/doc/HTML/en/ark
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcalc
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kdf
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kgpg
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kinfocenter/blockdevices
%doc %lang(en) /opt/kde3/share/doc/HTML/en/ksim
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kwallet
%doc %lang(en) /opt/kde3/share/doc/HTML/en/irkick
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcmlirc
/opt/kde3/share/icons/*/*/*/ark.*
/opt/kde3/share/icons/*/*/*/irkick.*
/opt/kde3/share/icons/*/*/*/kcalc.*
/opt/kde3/share/icons/*/*/*/kcmdf.*
/opt/kde3/share/icons/*/*/*/kdf.*
/opt/kde3/share/icons/*/*/*/kgpg.*
/opt/kde3/share/icons/*/*/*/ksim_cpu.*
/opt/kde3/share/icons/*/*/*/ksim.*
/opt/kde3/share/icons/*/*/*/ktimer.*
/opt/kde3/share/icons/*/*/*/kwalletmanager.*
/opt/kde3/share/icons/*/*/*/kwikdisk.*
/opt/kde3/share/services/ark_part.desktop
/opt/kde3/share/services/kwallet*
/opt/kde3/share/config.kcfg/ark.kcfg
%ifnarch s390 s390x
/opt/kde3/share/icons/*/*/*/kfloppy.*
/opt/kde3/share/applications/kde/KFloppy.desktop
/opt/kde3/bin/kfloppy
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kfloppy
%endif

%files extra
%defattr(-,root,root)
/opt/kde3/bin/kcharselect
/opt/kde3/bin/kedit
/opt/kde3/bin/khexedit
/opt/kde3/bin/kjots
/opt/kde3/bin/kregexpeditor
/opt/kde3/bin/ktimer
/opt/kde3/bin/superkaramba
/opt/kde3/%{_lib}/kde3/kcharselect_panelapplet.*
/opt/kde3/%{_lib}/kde3/kedit.*
/opt/kde3/%{_lib}/kde3/libkregexpeditorgui.*
/opt/kde3/%{_lib}/kde3/libkhexedit2part.*
/opt/kde3/%{_lib}/libkdeinit_kedit.*
/opt/kde3/%{_lib}/libkregexpeditorcommon.*
/opt/kde3/%{_lib}/libkhexeditcommon.*
/opt/kde3/share/applications/kde/KCharSelect.desktop
/opt/kde3/share/applications/kde/KEdit.desktop
/opt/kde3/share/applications/kde/khexedit.desktop
/opt/kde3/share/applications/kde/Kjots.desktop
/opt/kde3/share/applications/kde/kregexpeditor.desktop
/opt/kde3/share/applications/kde/ktimer.desktop
/opt/kde3/share/applications/kde/superkaramba.desktop
/opt/kde3/share/apps/kedit
/opt/kde3/share/apps/khexedit*
/opt/kde3/share/apps/kicker/applets/kcharselectapplet.desktop
/opt/kde3/share/apps/kjots
/opt/kde3/share/apps/kregexpeditor
/opt/kde3/share/apps/superkaramba
/opt/kde3/share/config.kcfg/kedit.kcfg
/opt/kde3/share/apps/kconf_update/kcharselect.upd
/opt/kde3/%{_lib}/kde3/libkbyteseditwidget.*
/opt/kde3/share/config.kcfg/kcalc.kcfg
/opt/kde3/share/config.kcfg/kgpg.kcfg
/opt/kde3/share/config.kcfg/kjots.kcfg
/opt/kde3/share/icons/*/*/*/kcharselect.png
/opt/kde3/share/icons/*/*/*/kedit.png
/opt/kde3/share/icons/*/*/*/khexedit.png
/opt/kde3/share/icons/*/*/*/kjots.png
/opt/kde3/share/icons/*/*/*/kregexpeditor.*
/opt/kde3/share/icons/*/*/*/superkaramba.*
/opt/kde3/share/icons/*/*/*/superkaramba_theme.*
/opt/kde3/share/mimelnk/application/x-superkaramba.desktop
/opt/kde3/share/services/kregexpeditorgui.desktop
/opt/kde3/share/services/kbyteseditwidget.desktop
/opt/kde3/share/services/khexedit2part.desktop
/opt/kde3/share/apps/kcharselect
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kedit
%doc %lang(en) /opt/kde3/share/doc/HTML/en/khexedit
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcharselect
%doc %lang(en) /opt/kde3/share/doc/HTML/en/superkaramba
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kjots
%doc %lang(en) /opt/kde3/share/doc/HTML/en/KRegExpEditor
%doc %lang(en) /opt/kde3/share/doc/HTML/en/ktimer

%files laptop
%defattr(-,root,root)
/opt/kde3/%{_lib}/libkmilo.*
/opt/kde3/%{_lib}/kde3/kmilo*
/opt/kde3/%{_lib}/kde3/kded_kmilo*
/opt/kde3/%{_lib}/kde3/kcm_kvaio*
/opt/kde3/%{_lib}/kde3/kcm_thinkpad.*
/opt/kde3/share/applications/kde/kvaio.desktop
/opt/kde3/share/applications/kde/thinkpad.desktop
/opt/kde3/share/services/kded/kmilod.desktop
/opt/kde3/share/services/kmilo
/opt/kde3/share/servicetypes/kmilo
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcontrol/kcmlowbat*
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcontrol/laptop
%doc %lang(en) /opt/kde3/share/doc/HTML/en/kcontrol/powerctrl

%files devel
%defattr(-,root,root)
/opt/kde3/include/kmultiformlistbox*
/opt/kde3/include/ksim
/opt/kde3/include/kwidgetstreamer.h

%changelog
openSUSE Build Service is sponsored by