Name: kdesdk
Version: 4.4.1
Release: 1%{?_dist_release}
Summary: The KDE Software Development Kit (SDK)
Summary(ja): KDE ソフトウェア開発キット
Source: ftp://ftp.kde.org/pub/kde/stable/%{version}/src/%{name}-%{version}.tar.bz2

URL: http://www.kde.org/
License: GPLv2
Group: Applications/Development

BuildRoot: %{_tmppath}/%{name}-%{version}-root
BuildRequires: kdepimlibs-devel >= %{version}
BuildRequires: plasma-devel >= %{version}
BuildRequires: strigi-devel
BuildRequires: flex
BuildRequires: apr-devel
BuildRequires: libxml2-devel
BuildRequires: libxslt-devel
BuildRequires: libtool-ltdl-devel
BuildRequires: subversion-devel
BuildRequires: libboost-devel
BuildRequires: libical-devel
# for libiberty (used by kmtrace for cp_demangle)
# IMPORTANT: check licensing from time to time, currently libiberty is still
#            GPLv2+/LGPLv2+
BuildRequires: binutils
BuildRequires: hunspell-devel

Requires: kdepimlibs >= %{version}
Requires: %{name}-libs = %{version}-%{release}

Provides:      kaider = %{version}-%{release}
Obsoletes:     kaider < %{version}-%{release}


%description
This is a collection of applications and tools used by KDE developers.
It also has example code for use in learning KDE programming or starting
a new KDE application.

* cervisia: a CVS frontend
* kate: advanced text editor
* kbugbuster: a tool to manage the KDE bug report system
* kcachegrind: a browser for data produced by profiling tools (e.g. cachegrind)
* kompare: diff tool
* kuiviewer: displays designer's UI files
* lokalize: computer-aided translation system focusing on productivity and performance
* umbrello: UML modeller and UML diagram tool

%package libs
Summary: Runtime libraries for %{name}
Group:   System Environment/Libraries

%description libs
%{summary}.

%package devel
Summary: Development files for kdesdk.
Group: Development/Libraries
Requires: %{name}-libs = %{version}-%{release}
Requires: kdepimlibs-devel

%description devel
Development files (headers) for kdesdk.

%package utils
Summary: Text utilities from %{name}
Group:   Applications/Text

%description utils
%{summary}, including:
po2xml
split2po
swappo
xml2pot


%prep
%setup -q

%build
mkdir -p %{_target_platform}
pushd %{_target_platform}
unset QTDIR || : ; . /etc/profile.d/qt4.sh
%cmake \
    -DCMAKE_BUILD_TYPE=release \
    -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \
    -DDATA_INSTALL_DIR:PATH=%{_datadir}/kde4/apps \
    -DINCLUDE_INSTALL_DIR:PATH=%{_includedir}/kde4 \
    -DLIB_INSTALL_DIR:PATH=%{_libdir} \
    -DLIBEXEC_INSTALL_DIR:PATH=%{_libexecdir}/kde4 \
    -DSYSCONF_INSTALL_DIR:PATH=%{_sysconfdir} \
    ..
popd

make %{?_smp_mflags} -C %{_target_platform}

%install
rm -rf $RPM_BUILD_ROOT
make install/fast DESTDIR=$RPM_BUILD_ROOT -C %{_target_platform}

# unpackaged files
rm -f $RPM_BUILD_ROOT%{_libdir}/libantlr.so
# This one fits better into krazy2 (it requires krazy2), and the version in
# kdesdk does not understand lib64.
rm -f $RPM_BUILD_ROOT%{_bindir}/krazy-licensecheck

# move devel symlinks
mkdir -p $RPM_BUILD_ROOT%{_libdir}/kde4/devel
pushd $RPM_BUILD_ROOT%{_libdir}
for i in lib*.so
do
  case "$i" in
    libkateinterfaces.so)
      linktarget=`readlink "$i"`
      rm -f "$i"
      ln -sf "../../$linktarget" "kde4/devel/$i"
      ;;
  esac
done
popd


%clean
rm -rf $RPM_BUILD_ROOT

%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null ||:
touch --no-create %{_datadir}/icons/locolor &> /dev/null ||:
touch --no-create %{_datadir}/icons/oxygen &> /dev/null ||:

%posttrans
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null ||:
gtk-update-icon-cache %{_datadir}/icons/locolor &> /dev/null ||:
gtk-update-icon-cache %{_datadir}/icons/oxygen &> /dev/null ||:
update-desktop-database -q &> /dev/null ||:


%postun
if [ $1 -eq 0 ] ; then
  touch --no-create %{_datadir}/icons/hicolor &> /dev/null ||:
  touch --no-create %{_datadir}/icons/locolor &> /dev/null ||:
  touch --no-create %{_datadir}/icons/oxygen &> /dev/null ||:
  gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null ||:
  gtk-update-icon-cache %{_datadir}/icons/locolor &> /dev/null ||:
  gtk-update-icon-cache %{_datadir}/icons/oxygen &> /dev/null ||:
  update-desktop-database -q &> /dev/null ||:
fi

%post libs -p /sbin/ldconfig

%postun libs -p /sbin/ldconfig


%files
%defattr(-,root,root)
%doc COPYING README kdepalettes
%doc /usr/share/doc/HTML/en/*
%{_bindir}/*
# -utils
%exclude %{_bindir}/po2xml
%exclude %{_bindir}/split2po
%exclude %{_bindir}/swappo
%exclude %{_bindir}/xml2pot
%{_datadir}/config/*
%{_datadir}/kde4/apps/cervisia
%{_datadir}/kde4/apps/cervisiapart
%{_datadir}/kde4/apps/kabc
%{_datadir}/kde4/apps/katepart
%{_datadir}/kde4/apps/kate
%{_datadir}/kde4/apps/kbugbuster
%{_datadir}/kde4/apps/kcachegrind
%{_datadir}/kde4/apps/kconf_update
%{_datadir}/kde4/apps/kio_perldoc
%{_datadir}/kde4/apps/kdevappwizard
%{_datadir}/kde4/apps/kmtrace
%{_datadir}/kde4/apps/kompare
%{_datadir}/kde4/apps/kpartloader
%{_datadir}/kde4/apps/ktexteditor_snippets
%{_datadir}/kde4/apps/kuiviewer
%{_datadir}/kde4/apps/kuiviewerpart
%{_datadir}/kde4/apps/lokalize
%{_datadir}/kde4/apps/umbrello
%{_datadir}/applications/kde4/*
%{_datadir}/config.kcfg/*
%{_datadir}/dbus-1/interfaces/*
%{_datadir}/kde4/services/*
%{_datadir}/kde4/servicetypes/*
%{_datadir}/mime/packages/kateplugin_katesnippets_tng.xml
%{_datadir}/icons/hicolor/*/*/*
%{_datadir}/icons/locolor/*/*/*
%{_datadir}/icons/oxygen/*/*/*
%{_mandir}/man1/*
%{_libdir}/libkdeinit4*.so
%{_libdir}/libkomparedialogpages.so
%{_libdir}/libkomparediff2.so
%{_libdir}/strigi/*.so
%{_datadir}/strigi/fieldproperties/
%{_libdir}/kde4/*.so
# -devel
%exclude %{_libdir}/kde4/devel/

%files libs
%defattr(-,root,root,-)
%{_libdir}/lib*.so.*
# -utils
%exclude %{_libdir}/libantlr.so.*

%files devel
%defattr(-,root,root)
%{_includedir}/kde4/*
%{_libdir}/lib*.so
%exclude %{_libdir}/libkomparedialogpages.so
%exclude %{_libdir}/libkomparediff2.so
%{_libdir}/kde4/devel/lib*.so

%files utils
%defattr(-,root,root,-)
%{_bindir}/po2xml
%{_bindir}/split2po
%{_bindir}/swappo
%{_bindir}/xml2pot
%{_libdir}/libantlr.so.*

%changelog
* Sat Mar 13 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.4.1-1
- new upstream release
- built with new toolchain

* Wed Nov 25 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.3-1
- new upstream release

* Mon Oct 26 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.2-1
- new upstream release

* Thu Sep 10 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.1-1
- new upstream release

* Sun Aug 30 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.0-1
- new upstream release

* Wed May 13 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 3.5.8-1
- applied new versioning policy
- changed Group to Applications/Development

* Mon Oct 29 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.8-0vl2
- rebuild for VineSeed

* Mon Oct 29 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.8-0vl1
- new upstream release
- disable subversion support

* Wed Jun 27 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.7-0vl2
- build for VineSeed
- added --with-qt-libraries configure option

* Tue Jun 26 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.7-0vl1
- new upstream release
- add Patch0 to build kioslave/svn

* Tue Oct  3 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.5-0vl2
- rebuild for VineSeed

* Tue Oct  3 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.5-0vl1
- new upstream release

* Wed Aug  2 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.4-0vl2
- rebuild for VineSeed

* Wed Aug  2 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.4-0vl1
- new upstream release

* Wed May 31 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.3-0vl2
- rebuild for VineSeed

* Wed May 31 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.3-0vl1
- new upstream release
- use ap?-config for Vine3.x and use ap?-1-config for VineSeed
- add --with-svn-include=%%{_includedir}/subversion-1

* Wed Mar 22 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.2-0vl2
- rebuild for VineSeed

* Wed Mar 22 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.2-0vl1
- new upstream release

* Wed Feb  1 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.1-0vl2
- rebuild for VineSeed

* Wed Feb  1 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.1-0vl1
- new upstream release
- add BuildPrereq: expat-devel
- add Requires: kdebindings >= %%{version}

* Thu Dec  8 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.0-0vl2
- rebuild for VineSeed

* Thu Dec  8 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.0-0vl1
- new upstream release
- add BuildPrereq: apache2-devel subversion-devel
- add Requires: apache2-apr subversion

* Tue Nov 15 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.0-0vl0.rc1
- new upstream release

* Tue Oct 18 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.92-0vl1
- new upstream release
- delete Patch0

* Wed Sep 21 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.91-0vl1
- new upstream release
- add Patch0
- update %%files

* Mon Jul 25 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.2-0vl2
- rebuild for VineSeed

* Mon Jul 25 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.2-0vl1
- new upstream release

* Mon Jul  4 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.1-0vl2
- build for VineSeed
- add --disable-rpath to configure option

* Mon Jun  6 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.1-0vl1
- new upstream release
- use %%{?_smp_mflags} for make option

* Sat Mar 19 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.0-0vl2
- rebuild for VineSeed

* Sat Mar 19 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.4.0-0vl1
- new upstream release
- clean up changelog to use (double-percent) everywhere

* Sun Jan  2 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.3.2-0vl2
- rebuild for VineSeed

* Sun Jan  2 2005 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.3.2-0vl1
- new upstream release

* Fri Nov 12 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.3.1-0vl2
- rebuild with db4-4.2.52-6vl3 (VineSeed)

* Tue Nov  9 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.3.1-0vl1
- source upgrade
- update %%files
- add BuildPrereq: kdepim-devel >= %%{version} libart_lgpl-devel
- add Requires: kdepim >= %%{version}

* Tue Aug 10 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.2.3-0vl2
- rebuild with qt32

* Tue Jun 15 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.2.3-0vl1
- source upgrade
- remove lines about vine26

* Sat May  1 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.2.2-0vl1
- source upgrade

* Tue Mar  9 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.2.1-0vl1
- source upgrade

* Sat Jan 17 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.5-0vl2
- rebuild for VineSeedPlus

* Sun Jan 11 2004 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.5-0vl1
- source upgrade
- build for VinePlus/2.6
- (VinePlus/2.6) BuildPrereq: autoconf258

* Thu Jan  8 2004 Tomoya TAKA <taka@vinelinux.org> 3.1.4-0vl4
- remove alpha fron ExcludeArch

* Sun Dec 28 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.4-0vl3
- build for VineSeed with new toolchain and qt-3.2.3

* Sun Nov  2 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.4-0.26vl2
- rebuild with qt-3.2.1-0.26vl3

* Sun Oct 19 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.4-0vl2
- rebuild with qt-3.2.1-0vl3

* Sat Sep 20 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.4-0vl1
- build with gcc-3.2.3

* Sat Sep 20 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.4-0.26vl1
- source upgrade
- BuildPrereq: qt-devel >= 3.2.1 arts-devel >= 1:1.1.4

* Sat Aug  2 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.3-0.26vl1
- rebuild for Vine2.6

* Mon Jul 21 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.3-0vl1
- source upgrade
- change spec to build with gcc295
- change make option for SMP and add script

* Sat Jun 21 2003 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.1.2-0vl1
- source upgrade (MD5SUMS = 279b42135756e0e3640cf5f6612f572d)
- built with libpng >= 1.2.5 when %%{vine26} is set to 0 (ie VineSeedPlus)
- change spec to build both VineSeed and Vine2.5/2.6
- change spec to make monolithic package only
- remove Source900 and Patch0
- revised description
- change spec to build with g++-2.95.3

* Sat Oct 19 2002 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.0.4-0vl2
- objprelink2 support only ix86 (add %%ifarch %%{ix86} ... )

* Sun Oct 13 2002 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.0.4-0vl1
- source upgrade
- BuildPrereq: autoconf253 objprelink2
- remove kbugbuster

* Mon Jul 15 2002 AKIYAMA Kazuhito <akiyama@karen.servepics.com> 3.0.2-0vl1
- source upgrade

* Sun May 26 2002 AKIYAMA Kazuhito <akiyama@karen.servepics.com> 3.0-5vl1
- merged with rawhide 3.0.0-5
- add configure option `--with-xinerama --enable-final'
- add BuildPrereq: autoconf252 automake15
- add %%define monolithic 1
- There is Vine's previous changes, hacked for Vine 
 -- Sat Mar 23 2002 AKIYAMA Kazuhito <akiyama@karen.servepics.com> 2.2.2-1vl1
  - build for VineSeed
  - objprelink (i386 only)
  - add Requires and BuildPrereq

* Tue Apr 16 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-5
- Rename libraries

* Tue Apr  2 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-4
- Fix bug #62259

* Sun Mar 31 2002 Than Ngo <than@redhat.com> 3.0.0-3
- fix bug #62388

* Wed Mar 27 2002 Than Ngo <than@redhat.com> 3.0.0-2
- final

* Tue Mar 26 2002 Than Ngo <than@redhat.com> 3.0.0-0.cvs20020326.1
- update

* Sun Mar 24 2002 Than Ngo <than@redhat.com> 3.0.0-0.cvs20020324.1
- update
- fix bug #61671, #61670, #61656
- add more buildrequires

* Wed Jan 09 2002 Tim Powers <timp@redhat.com>
- automated rebuild

* Wed Jan  2 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-0.cvs20020102.1
- Update
- Split in subpackages

* Mon Aug  6 2001 Than Ngo <than@redhat.com> 2.2-1
- update to 2.2 release

* Sat Aug  04 2001 Than Ngo <than@redhat.com> 2.2-0.cvs20010804.1
- update
- fix bug #50665

* Tue Jul 24 2001 Bernhard Rosenkraenzer <bero@redhat.com> 2.2-0.cvs20010724.1
- Remove extractrc (it's in kdevelop)
- remove ia64 workarounds

* Mon Jul 23 2001 Bernhard Rosenkraenzer <bero@redhat.com> 2.2-0.cvs20010723.1
- update

* Wed Feb 21 2001 Than Ngo <than@redhat.com>
- 2.1-respin
- fix dangling symlink

* Tue Feb 20 2001 Than Ngo <than@redhat.com>
- update to 2.1

* Fri Feb 16 2001 Than Ngo <than@redhat.com>
- fix to build against glibc
- obsolete ktranslator kless (from powertools)
- clean up specfile
- add missing %%post and %%postun (ldconfig)

* Tue Feb  6 2001 Bernhard Rosenkraenzer <bero@redhat.com>
- Rebuild to get rid of libkdefakes.so.0 requirement
- Obsolete kbabel (from Powertools)

* Sun Jan 28 2001 Bernhard Rosenkraenzer <bero@redhat.com>
- initial RPM
