Blob Blame History Raw
%define debug 0
%define final 0

##
## stil need fix to build java -> disable java at the moment
##define support_arch %{ix86} alpha ia64 ppc
%define support_arch none

%define mozilla_archs %{ix86} ppc s390 s390x x86_64

%define mozilla_version 1.6.0
%define qt_version 3.3.3
%define arts_version 1.3.0

%define arts 1

Version: 3.3.0
Release: 3
Name: kdebindings
Summary: KDE bindings to non-C++ languages
URL: http://www.kde.org/
License: GPL
Group: User Interface/Desktops
Prefix: %{_prefix}
BuildRoot: %{_tmppath}/%{name}-root

Source: ftp://ftp.kde.org/pub/kde/stable/%{version}/src/%{name}-%{version}.tar.bz2

Patch4: kdebindings-3.1-ssl-krb5.patch
Patch6: kdebindings-3.1-python2.patch
Patch7: kde-libtool.patch
Patch8: kdebindings-3.3.0-python.patch

BuildRequires: zlib-devel
BuildRequires: kdelibs-devel >= 6:%{version}
BuildRequires: arts-devel >= %{arts_version}
BuildRequires: libjpeg-devel
BuildRequires: libpng-devel
BuildRequires: automake >= 1.6
BuildRequires: ruby
BuildRequires: ruby-devel

Requires: kdelibs >= 6:%{version}
Requires: kdebase >= 6:%{version}

Prereq: /sbin/ldconfig

%description
KDE/DCOP bindings to non-C++ languages

%package devel
Summary: Development files for %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
Requires: kdelibs-devel >= 6:%{version}

%description devel
Development files for the KDE bindings.

Install %{name}-devel if you want to develop non-KDE
applications that talk to KDE.

%ifarch %{mozilla_archs}
%package kmozilla
Summary: KDE bindings to mozilla
Group: User Interface/Desktops
Requires: mozilla
Requires: kdebase >= 6:%{version}

%description kmozilla
KDE bindings to mozilla - embed Mozilla in Konqueror
%endif

%package perl
Summary: Perl bindings to DCOP
Group: Development/Libraries
Requires: kdelibs >= 6:%{version}
Requires: perl >= 5.6.0

%description perl
Perl bindings to the DCOP interprocess communication protocol used by KDE

%package python
Summary: Python bindings to DCOP
Group: Development/Libraries
Requires: kdelibs >= 6:%{version}
Requires: python >= 2.3

%description python
Python bindings to the DCOP interprocess communication protocol used by KDE

%ifarch %{support_arch}
%package qtjava
Summary: Java bindings to Qt
Group: System Environment/Libraries
Requires: qt >= %{qt_version}
Requires: libgcj >= 3.1
Requires: jdkgcj >= 0.2.2
BuildRequires: gcc-java >= 3.1
BuildRequires: libgcj >= 3.1
BuildRequires: jdkgcj >= 0.2.2

%description qtjava
Java bindings to Qt.
%endif

%package qtc
Summary: C bindings to Qt
Group: System Environment/Libraries
Requires: qt >= 1:%{qt_version}

%description qtc
C bindings to Qt.
Install kdebindings-qtc if you wish to develop Qt applications
in C (rather than C++).

%package kdec
Summary: C bindings to KDE
Group: System Environment/Libraries
Requires: qt >= 1:%{qt_version}
Requires: %{name}-qtc >= 3.0.2

%description kdec
C bindings to KDE.
Install kdebindings-kdec if you wish to develop Qt applications
in C (rather than C++).

%ifarch %{support_arch}
%package kdejava
Summary: Java bindings to KDE
Group: Development/Libraries
Requires: kdelibs >= 6:%{version}
Requires: kdebindings-qtjava = %{version}-%{release}
Requires: libgcj

%description kdejava
Java bindings to KDE
%endif

%prep
%setup -q
%patch4 -p1 -b .ssl-krb5
%patch6 -p1 -b .python2
%patch7 -p1 -b .libtool
%patch8 -p1 -b .python

%build
unset QTDIR && . /etc/profile.d/qt.sh

export CFLAGS="$RPM_OPT_FLAGS"
export CXXFLAGS="$RPM_OPT_FLAGS"

# workaround for ia64, need to be fixed later
%ifarch ia64
export CFLAGS="$RPM_OPT_FLAGS -O0"
export CXXFLAGS="$RPM_OPT_FLAGS -O0"
%endif

%ifarch %{support_arch}
export CFLAGS="$CFLAGS `mozilla-config --cflags`"
export CXXFLAGS="$CXXFLAGS `mozilla-config --cflags`"
export CPPFLAGS="$CPPFLAGS `mozilla-config --cflags`"
export LDFLAGS="$LDFLAGS `mozilla-config --libs`"
%endif

# don't build sip/pyqt, we have separates packages
rm -rf python

make -f admin/Makefile.common cvs

suffix=""
if [ "%{_lib}" == "lib64" ] ; then
   suffix="64"
fi

%configure \
   --disable-rpath \
   --enable-libsuffix="$suffix" \
   --includedir=%{_includedir}/kde \
   --with-qt-libraries=$QTDIR/lib \
%if %{arts} == 0
   --without-arts \
%endif
%if %{final}
   --enable-final \
%endif
%ifarch %{support_arch}
   --with-java=%{prefix}
%else
   --without-java
%endif

make %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT

make install DESTDIR=$RPM_BUILD_ROOT

if [ -d "$RPM_BUILD_ROOT%{_prefix}/doc" ]; then
   mkdir -p $RPM_BUILD_ROOT%{_docdir}
   mv -f $RPM_BUILD_ROOT%{_prefix}/doc/* $RPM_BUILD_ROOT%{_docdir}
   rm -rf $RPM_BUILD_ROOT%{_prefix}/doc
fi

find $RPM_BUILD_ROOT -size 0 | xargs rm -f

%clean
rm -rf $RPM_BUILD_ROOT

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%files
%defattr(-,root,root)
%{_libdir}/*.so.*
%{_libdir}/*.la
%{_libdir}/kde3/*
%{_datadir}/applications/kde/*
%{_datadir}/apps/kjsembed
%{_datadir}/services/*
%{_datadir}/servicetypes/*
%{_bindir}/*
%{_libdir}/site_ruby
%{_libdir}/python*
%{_libdir}/perl5
%ifarch %{support_arch}
%{_libdir}/java
%doc %{_docdir}/javalib
%endif

%files devel
%defattr(-,root,root)
%{_includedir}/kde/*
%{_libdir}/*.so
%{_mandir}/man*/*

%changelog
* Fri Oct 08 2004 Than Ngo <than@redhat.com> 3.3.0-3
- add buildrequires on ruby and ruby-devel #135053

* Thu Sep 02 2004 Than Ngo <than@redhat.com> 3.3.0-2
- get rid of pyqt/sip, separates packages

* Mon Aug 23 2004 Than Ngo <than@redhat.com> 3.3.0-1
- update to 3.3.0 release

* Tue Aug 10 2004 Than Ngo <than@redhat.com> 3.3.0-0.1.rc2
- update to 3.3.0 rc2

* Mon Jun 21 2004 Than Ngo <than@redhat.com> 3.2.3-2
- build with -O0 on ia64, temporary gcc3.4 workaround 

* Sat Jun 19 2004 Than Ngo <than@redhat.com> 3.2.3-1
- update to 3.2.3

* Wed Jun 02 2004 Than Ngo <than@redhat.com> 3.2.2-2
- remove -O0 on ia64

* Tue Apr 13 2004 Than Ngo <than@redhat.com> 3.2.2-1
- 3.2.2 release

* Sun Mar 07 2004 Than Ngo <than@redhat.com> 3.2.1-1
- 3.2.1 release

* Tue Mar 02 2004 Elliot Lee <sopwith@redhat.com>
- rebuilt

* Tue Feb 17 2004 Than Ngo <than@redhat.com> 3.2.0-1.4
- fix typo bug, _smp_mflags instead smp_mflags

* Fri Feb 13 2004 Elliot Lee <sopwith@redhat.com>
- rebuilt

* Thu Feb 05 2004 Than Ngo <than@redhat.com> 3.2.0-0.3
- 3.2.0 release
- built against qt 3.3.0

* Mon Jan 19 2004 Than Ngo <than@redhat.com> 3.1.95-0.1
- KDE 3.2 RC1

* Mon Dec 01 2003 Than Ngo <than@redhat.com> 3.1.94-0.1
- KDE 3.2 Beta2

* Wed Nov 12 2003 Than Ngo <than@redhat.com> 3.1.93-0.1
- KDE 3.2 Beta1
- remove some unneeded patch files
- cleanup

* Tue Sep 30 2003 Than Ngo <than@redhat.com> 3.1.4-1
- 3.1.4

* Fri Aug 22 2003 Than Ngo <than@redhat.com> 3.1.3-2
- fix build problem with gcc 3.3

* Wed Aug 13 2003 Than Ngo <than@redhat.com> 3.1.3-1
- 3.1.3

* Wed Jun 25 2003 Than Ngo <than@redhat.com> 3.1.2-4
- rebuilt

* Wed Jun 04 2003 Elliot Lee <sopwith@redhat.com>
- rebuilt

* Mon May 19 2003 Than Ngo <than@redhat.com> 3.1.2-2
- 3.1.2

* Fri May  2 2003 Than Ngo <than@redhat.com> 3.1.1-3
- remove unneeded patch file

* Wed Apr 30 2003 Elliot Lee <sopwith@redhat.com> 3.1.1-2
- headusage patch for ppc64

* Wed Mar 19 2003 Than Ngo <than@redhat.com> 3.1.1-1
- 3.1.1

* Fri Feb 21 2003 Than Ngo <than@redhat.com> 3.1-4
- get rid of gcc path from dependency_libs

* Wed Feb 19 2003 Elliot Lee <sopwith@redhat.com> 3.1-3
- Fix mozilla building/notbuilding to consistently use mozilla_archs macro
- Remove -O0 cflags from November

* Thu Jan 30 2003 Than Ngo <than@redhat.com> 3.1-2
- lib64'ize
- add fix to build kmozilla binding
- add correct python version

* Tue Jan 28 2003 Than Ngo <than@redhat.com> 3.1-1
- 3.1 release
- cleanup specfile

* Thu Jan 23 2003 Tim Powers <timp@redhat.com> 3.1-0.6
- rebuild

* Mon Jan 13 2003 Thomas Woerner <twoerner@redhat.com> 3.1-0.4
- rc6
- ssl uses krb5

* Tue Dec  3 2002 Tim Powers <timp@redhat.com> 3.1-0.3
- lib64'ize

* Sat Nov 30 2002 Than Ngo <than@redhat.com> 3.1-0.2
- build with -O0 on ia64 x86_64 temporary
- get rid of sub packages

* Thu Nov 28 2002 Than Ngo <than@redhat.com> 3.1-0.1
- update to 3.1 rc4

* Sun Nov 10 2002 Than Ngo <than@redhat.com> 3.0.5-1
- update to 3.0.5

* Thu Nov  7 2002 Than Ngo <than@redhat.com> 3.0.4-2
- cleaned up specfile

* Tue Oct 15 2002 Than Ngo <than@redhat.com> 3.0.4-1
- 3.0.4

* Thu Sep 19 2002 Than Ngo <than@redhat.com> 3.0.3-1.1
- Added missing requires kdelibs-devel in kdebindings-devel (bug #73992)
- Fixed typo bug (bug #51669)
- Added Buildprereq arts-devel instead kdelibs-sound
- Fixed to build on s390/s390x/x86_64

* Mon Aug 12 2002 Than Ngo <than@redhat.com> 3.0.3-1
- 3.0.3
- build using gcc-3.2-0.3

* Mon Jul 22 2002 Tim Powers <timp@redhat.com> 3.0.2-3
- rebuild using gcc-3.2-0.1

* Fri Jul 12 2002 Than Ngo <than@redhat.com> 3.0.2-2
- 3.0.2

* Fri Jun 14 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.2-0.cvs20020614
- Update to current stable branch to make it work with Qt 3.0.4
- Enable building Java bindings (with jdkgcj)

* Thu May 23 2002 Tim Powers <timp@redhat.com>
- automated rebuild

* Wed Mar 27 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-1
- 3.0.0 final
- Disable building C, Java and Objective-C bindings for now, they require
  a real C++ compiler rather than a something-between-C-and-C++-compiler

* Mon Feb 18 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-0.cvs20020218.1
- Update
- Another try at getting the Qt Java bindings to build and actually work with
  gcj.

* Thu Jan 31 2002 Tim Powers <timp@redhat.com>
- rebuilt to solve deps on kdelibs
- don't build kmozilla package for ia64

* Wed Jan 30 2002 Bernhard Rosenkraenzer <bero@redhat.com> 3.0.0-0.cvs20020130.1
- Update
- Get the qt java bindings to build with gcj
- Temporarily disable building KDE-C, KDE-Java, DCOP-perl and DCOP-python
  bindings; they don't compile.

* 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