File kde3-kmess.spec of Package kmess
#
# spec file for package kde3-kmess
#
# Copyright (c) 2013 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/
#
%define name1 kmess
%define _iconsdir /usr/share/icons
Name: kde3-%{name1}
Version: 1.5.2
Release: 0
Source0: http://ovh.dl.sourceforge.net/sourceforge/kmess/%{name1}-%{version}.tar.gz
Source1: kmess.desktop
Url: http://kmess.sourceforge.net
BuildRequires: kdebase3-devel
BuildRequires: kdenetwork3-devel
BuildRequires: libxslt-devel
BuildRequires: update-desktop-files
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Summary: Yet another MSN messenger for KDE
License: GPL-2.0
Group: Productivity/Networking/Instant Messenger
%description
KMess is an easy-to-use MSN Messenger client for KDE. Install it
if you want an MSN Messenger client.
%prep
%setup -q -n %{name1}-%{version}
sed -i 1i\ '#include <cmath>' kmess/xautolock.cpp
sed -i 's|abs(|fabs(|g' kmess/xautolock.cpp
%build
CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" \
./configure --build=%{_target_platform} \
--prefix=%{_prefix} \
--libdir=%{_libdir} \
--disable-debug \
--enable-mt \
--enable-shared \
--disable-static \
--disable-objprelink \
--with-pic \
--with-gnu-ld \
--disable-rpath \
--disable-embedded \
--enable-fast-install=yes \
--with-qt-dir=%{_prefix}/lib/qt3 \
--with-xinerama
# --enable-final
# do not use this, makes kmess fail to compile
make
%install
make install DESTDIR=$RPM_BUILD_ROOT
install -m644 $RPM_BUILD_ROOT%{_iconsdir}/hicolor/16x16/apps/%{name1}.png -D $RPM_BUILD_ROOT%{_miconsdir}/%{name1}.png
install -m644 $RPM_BUILD_ROOT%{_iconsdir}/hicolor/32x32/apps/%{name1}.png -D $RPM_BUILD_ROOT%{_iconsdir}/%{name1}.png
install -m644 $RPM_BUILD_ROOT%{_iconsdir}/hicolor/48x48/apps/%{name1}.png -D $RPM_BUILD_ROOT%{_liconsdir}/%{name1}.png
#Relativisation of symlink, rpm fails to do it
rm -f $RPM_BUILD_ROOT%{_datadir}/doc/HTML/en/%{name1}/common
install -m 0644 %SOURCE1 $RPM_BUILD_ROOT%{_datadir}/applications/kde/kmess.desktop
%suse_update_desktop_file -n kmess
%find_lang %{name1}
%files -f %{name1}.lang
%defattr(-,root,root)
#%doc %{_docdir}/HTML/*/%{name1}
%doc AUTHORS INSTALL TODO README ChangeLog
%doc %{_datadir}/doc/HTML/en/kmess/*
%{_bindir}/%{name1}
%{_datadir}/apps/%{name1}
%exclude %{_iconsdir}/kmess.png
%{_datadir}/applications/kde/kmess.desktop
%{_iconsdir}/hicolor/16x16/apps/%{name1}.png
%{_iconsdir}/hicolor/22x22/apps/kmess.png
%{_iconsdir}/hicolor/32x32/apps/%{name1}.png
%{_iconsdir}/hicolor/48x48/apps/%{name1}.png
%{_iconsdir}/hicolor/64x64/apps/kmess.png
%{_iconsdir}/hicolor/128x128/apps/kmess.png
%{_iconsdir}/locolor/16x16/apps/%{name1}.png
%{_iconsdir}/locolor/22x22/apps/kmess.png
%{_iconsdir}/locolor/32x32/apps/%{name1}.png
%dir %{_datadir}/emoticons/KMess-new
%{_datadir}/emoticons/KMess-new/*.png
%{_datadir}/emoticons/KMess-new/emoticons.xml
%{_datadir}/sounds/%{name1}*.ogg
%{_datadir}/applications/kde
%{_datadir}/apps
%{_datadir}/doc/HTML
%{_datadir}/doc/HTML/en
%{_datadir}/doc/HTML/en/kmess
%{_datadir}/emoticons
%{_datadir}/icons/locolor
%{_datadir}/icons/locolor/16x16
%{_datadir}/icons/locolor/22x22
%{_datadir}/icons/locolor/22x22/apps
%{_datadir}/icons/locolor/32x32
%{_datadir}/icons/locolor/32x32/apps
%changelog