%define _qt4_version %(pkg-config --modversion --silence-errors Qt 2>/dev/null || echo 4.8.6)

Name:    smokeqt
Version: 4.14.3
Release: 2%{?_dist_release}
Summary: Bindings for Qt libraries

License: LGPLv2+
Group:   System Environment/Libraries
URL:     https://projects.kde.org/projects/kde/kdebindings/smoke

Source0: http://download.kde.org/stable/%{version}/src/%{name}-%{version}.tar.xz

BuildRequires: cmake
BuildRequires: phonon-devel
BuildRequires: qimageblitz-devel
BuildRequires: qt4-devel
BuildRequires: qwt-qt4-devel
BuildRequires: qscintilla-devel >= 2.4
BuildRequires: smokegen-devel >= %{version}

Conflicts: kdebindings < 4.7.0 

Requires: qt4 >= %{_qt4_version}
Requires: smokegen >= %{version}

%description
This package includes Bindings for Qt libraries.

%package devel
Summary: Development files for %{name} 
Summary(ja): %{name} の開発用ファイル 
Group:   Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: smokegen-devel 
Conflicts: kdebindings-devel < 4.7.0 

%description devel
%{summary}.

%prep
%setup -q


%build
mkdir -p %{_target_platform}
pushd %{_target_platform}
%cmake ..
popd

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


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


%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig

%clean
rm -rf $RPM_BUILD_ROOT


%files
%doc AUTHORS COPYING.LIB
%{_libdir}/libsmokephonon.so.3*
%{_libdir}/libsmokeqimageblitz.so.3*
%{_libdir}/libsmokeqsci.so.3*
%{_libdir}/libsmokeqt3support.so.3*
%{_libdir}/libsmokeqtcore.so.3*
%{_libdir}/libsmokeqtdbus.so.3*
%{_libdir}/libsmokeqtdeclarative.so.3*
%{_libdir}/libsmokeqtgui.so.3*
%{_libdir}/libsmokeqthelp.so.3*
%{_libdir}/libsmokeqtmultimedia.so.3*
%{_libdir}/libsmokeqtnetwork.so.3*
%{_libdir}/libsmokeqtopengl.so.3*
%{_libdir}/libsmokeqtscript.so.3*
%{_libdir}/libsmokeqtsql.so.3*
%{_libdir}/libsmokeqtsvg.so.3*
%{_libdir}/libsmokeqttest.so.3*
%{_libdir}/libsmokeqtuitools.so.3*
%{_libdir}/libsmokeqtwebkit.so.3*
%{_libdir}/libsmokeqtxml.so.3*
%{_libdir}/libsmokeqtxmlpatterns.so.3*
%{_libdir}/libsmokeqwt.so.3*

%files devel
%{_libdir}/libsmoke*.so
%{_includedir}/smoke/*
%{_datadir}/smokegen/*
%{_datadir}/smoke/*


%changelog
* Sun Jul 03 2016 Yoji TOYODA <bsyamato@sea.plala.or.jp> 4.14.3-2
- rebuild with gcc-5.4.0

* Sun Jan  4 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 4.14.3-1
- new upstream release

* Sun Nov  9 2014 Ryoichi INAGAKI <ryo1@toki.waseda.jp> 4.14.2-1
- splitted from kdebindings

* Thu Jun 16 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.6.4-1
- new upstream release

* Thu Apr 14 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.6.1-1
- updated to 4.6.1
- added BR: kdesdk-devel
- disabled attica plugins temporaly
- rebuilt with mono-2.10.1

* Sun Sep 26 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.5.1-2
- rebuilt with rpm-4.8.1 for pkg-config

* Sat Sep 18 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.5.1-1
- new upstream release
- added Patch50
- added more japanese summaries

* Tue Aug 17 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.5.0-1
- new upstream release

* Sun Jul  4 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.4.5-1
- new upstream release

* Fri May  7 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.4.3-1
- new upstream release

* Thu Apr 15 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.4.2-1
- new upstream release

* Tue Mar  9 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.4.1-1
- new upstream release
- added -DCMAKE_SKIP_RPATH:BOOL=OFF option to cmake
  (see https://bugs.kde.org/show_bug.cgi?id=214824)
- built with new toolchain

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

* Thu Oct 29 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.2-4
- merged 4.3.1-2 %changelog 
- re-define %%{mono_dir} to %{_prefix}/lib/mono (again)

* Tue Oct 27 2009 Shu KONNO <owa@bg.wakwak.com> 4.3.2-3
- use %%{_prefix}/lib for mono-dll (for x86_64)

* Tue Oct 27 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.2-2
- new upstream release
- built with PyQt4-4.6

* Sun Sep 06 2009 NAKAMURA Kenta <kenta@vinelinux.org> 4.3.1-2
- define %%{mono_dir} to specify mono library install path

* Sun Sep  6 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.1-1
- new upstream release
- fixed ruby modules installation path

* Thu Aug 20 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.3.0-1
- new upstream release
- spilt sub package based on Fedora

* Mon May 11 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 3.5.8-1
- applied new versioning policy
- added Patch1 
  (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=484191)

* Fri Nov 23 2007 NAKAMURA Kenta <kenta@vinelinux.org> 3.5.8-0vl3
- added --with-qt-libraries option

* 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

* Mon Jun 25 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.7-0vl2
- rebuild for VineSeed

* Thu May 31 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.7-0vl1
- new upstream release
- update Patch0
- drop Patch1

* Mon Jan 29 2007 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.6-0vl1
- new upstream release
- add Patch1
- add --enable-libsuffix option

* 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

* Thu Jun  1 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.3-0vl2
- rebuild for VineSeed

* Thu Jun  1 2006 AKIYAMA Kazuhito <akiyama@yb3.so-net.ne.jp> 3.5.3-0vl1
- new upstream release

* 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
- renew BuildPrereq and build section
- renew %%files
- enable python
- change spec to make main and devel package
- add BuildPrereq: ruby ruby-devel
- add Patch0 to install ruby-bindings under /usr/lib/ruby

* Sun Mar 17 2002 AKIYAMA Kazuhito <akiyama@karen.servepics.com> 2.2.2-1vl1
- build for VineSeed
- disable python and mozilla
- objprelink (i386 only)

* Wed Nov 21 2001 Than Ngo <than@redhat.com> <bero@redhat.com> 2.2.2-1
- 2.2.2
- build kmozilla binding only on x86/alpha

* Thu Aug  9 2001 Bernhard Rosenkraenzer <bero@redhat.com> 2.2-2
- Make sure %%{name}-kmozilla isn't built on ia64

* Mon Jul 23 2001 Bernhard Rosenkraenzer <bero@redhat.com> 2.2-0.cvs20010723.2
- Move python bindings to separate package
- Add perl bindings
- Shut up rpmlint

* Wed Feb 21 2001 Bernhard Rosenkraenzer <bero@redhat.com>
- 2.1

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