File at-spi.spec of Package at-spi

# spec file for package at-spi (Version 1.32.0)
# 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

# at-spi-registryd

Name:           at-spi
Version:        1.32.0
Release:        3
License:        GPLv2+ ; LGPLv2.1+
Summary:        Assistive Technology Service Provider Interface
Group:          Development/Libraries/GNOME
Source:         %{name}-%{version}.tar.bz2
# PATCH-FIX-OPENSUSE at-spi-64.patch bnc#609176 -- at-spi-registryd will not set GTK_PATH64 if relocated
Patch0:         at-spi-64.patch
# PATCH-FIX-UPSTREAM at-spi-gtk-version.patch bgo#619755 -- Reduce GTK+ requirement to 2.18.0
Patch1:         at-spi-gtk-version.patch
BuildRequires:  fdupes
BuildRequires:  gconf2-devel
BuildRequires:  gtk-doc
BuildRequires:  gtk2-devel
BuildRequires:  intltool
BuildRequires:  libbonobo-devel
BuildRequires:  libidl-devel
BuildRequires:  python
BuildRequires:  translation-update-upstream
BuildRequires:  update-desktop-files
Requires:       %{name}-lang = %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

This library, based on ATK, is a general interface for applications to
make use of the accessibility toolkit.

%package -n python-atspi-corba
License:        GPLv2+ ; LGPLv2.1+
Summary:        Assistive Technology Service Provider Interface - Python bindings
Group:          Development/Libraries/Python
Requires:       %{name} = %{version}
Requires:       python-gnome
Requires:       python-orbit
# Virtual package, so that apps can depend on it, without having to know which
# at-spi stack is used. Only the default at-spi stack should define it.
Provides:       pyatspi
%if %suse_version <= 1110
%define python_sitearch %{py_sitedir}

%description -n python-atspi-corba
AT-SPI is a general interface for applications to make use of the
accessibility toolkit. This version is based on CORBA.

This package contains the python bindings for AT-SPI.

%package devel
License:        GPLv2+ ; LGPLv2.1+
Summary:        Include Files and Libraries mandatory for Development
Group:          Development/Libraries/GNOME
Requires:       %{name} = %{version}
Requires:       atk-devel
Requires:       gtk2-devel
Requires:       libbonobo-devel

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

%package doc
License:        GPLv2+ ; LGPLv2.1+
Summary:        Additional Package Documentation
Group:          Development/Libraries/GNOME
Requires:       %{name} = %{version}

%description doc
This package contains optional documentation provided in addition to
this package's base documentation.

%setup -q
%patch0 -p1
%patch1 -p1

# We pass --enable-relocate when we want another at-spi stack (like at-spi2) by default.
        --disable-static \
        --libexecdir=%{_libexecdir}/at-spi \
        --enable-relocate \
        --disable-relocate \
make %{?jobs:-j%jobs} referencetopdir=%{_docdir}/%{name}/reference

make install referencetopdir=%{_docdir}/%{name}/reference DESTDIR=%{buildroot}
%if 0%{?suse_version} <= 1120
%{__rm} %{buildroot}%{_datadir}/locale/en@shaw/LC_MESSAGES/*
find %{buildroot} -type f -name "*.la" -delete -print
%suse_update_desktop_file at-spi-registryd
%find_lang %{name}
cp AUTHORS COPYING ChangeLog NEWS README %{buildroot}%{_docdir}/%{name}
%fdupes %{buildroot}

rm -rf %{buildroot}

%post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

%pre -f %{name}.schemas_pre

%preun -f %{name}.schemas_preun

%posttrans -f %{name}.schemas_posttrans

%files -f %{name}.schemas_list
%defattr (-, root, root)
%doc %dir %{_docdir}/%{name}
%doc %{_docdir}/%{name}/AUTHORS
%doc %{_docdir}/%{name}/COPYING
%doc %{_docdir}/%{name}/ChangeLog
%doc %{_docdir}/%{name}/NEWS
%doc %{_docdir}/%{name}/README

%files -n python-atspi-corba
%defattr (-, root, root)

%files lang -f %{name}.lang

%files devel
%defattr (-, root, root)

%files doc
%defattr (-, root, root)
%doc %{_docdir}/%{name}/reference