File glade3.spec of Package glade3

#
# spec file for package glade3
#
# Copyright (c) 2016 SUSE LINUX 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/
#


Name:           glade3
Version:        3.8.5
Release:        0
Summary:        User Interface Builder for GTK+ 2
License:        GPL-2.0+
Group:          Development/Tools/GUI Builders
Url:            http://glade.gnome.org/
Source:         http://download.gnome.org/sources/glade3/3.8/%{name}-%{version}.tar.xz
BuildRequires:  fdupes
BuildRequires:  gnome-doc-utils-devel
BuildRequires:  intltool
BuildRequires:  libgnomeui-devel
BuildRequires:  pkg-config
BuildRequires:  python-gtk-devel
BuildRequires:  translation-update-upstream
BuildRequires:  update-desktop-files
Recommends:     %{name}-lang
# The old glade (version 2 -- last version was 2.12.2) is completely replaced by this version
Provides:       glade = 2.12.2
Obsoletes:      glade < 2.12.2
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
Glade is a RAD tool to enable quick & easy development of user
interfaces for the Gtk+ toolkit and the GNOME desktop environment.

%package -n libgladeui-1-11
Summary:        User Interface Builder for GTK+ 2
Group:          Development/Tools/GUI Builders
Recommends:     %{name}-lang

%description -n libgladeui-1-11
Glade is a RAD tool to enable quick & easy development of user
interfaces for the Gtk+ toolkit and the GNOME desktop environment.

%package -n libgladeui-1-devel
Summary:        User Interface Builder for GTK+ 2 -- Development Files
Group:          Development/Libraries/C and C++
Requires:       libgladeui-1-11 = %{version}
Provides:       libgladeui-1_0-devel = %{version}
Obsoletes:      libgladeui-1_0-devel < %{version}
Provides:       libgladeui-1_0-doc = %{version}
Obsoletes:      libgladeui-1_0-doc < %{version}

%description -n libgladeui-1-devel
Glade is a RAD tool to enable quick & easy development of user
interfaces for the Gtk+ toolkit and the GNOME desktop environment.

%lang_package
%prep
%setup -q
translation-update-upstream

%build
%configure --disable-static --with-pic\
	--disable-scrollkeeper
make %{?jobs:-j%jobs}

%install
%makeinstall
%if 0%{?suse_version} <= 1120
%{__rm} %{buildroot}%{_datadir}/locale/en@shaw/LC_MESSAGES/*
%endif
%suse_update_desktop_file -N Glade glade-3
%find_lang %{name} %{?no_lang_C}
find %{buildroot}%{_libdir} -name '*.la' -type f -delete -print
%fdupes %{buildroot}%{_datadir}

%clean
rm -rf %{buildroot}

%post
%desktop_database_post
%icon_theme_cache_post

%postun
%desktop_database_postun
%icon_theme_cache_postun

%post -n libgladeui-1-11 -p /sbin/ldconfig

%postun -n libgladeui-1-11 -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc AUTHORS COPYING COPYING.GPL COPYING.LGPL ChangeLog NEWS README TODO
%defattr (-, root, root)
%dir %{_datadir}/gnome/
%dir %{_datadir}/gnome/help/
%dir %{_datadir}/gnome/help/glade3/
%doc %{_datadir}/gnome/help/glade3/C/
%dir %{_datadir}/omf/
%dir %{_datadir}/omf/glade3/
%doc %{_datadir}/omf/glade3/glade3-C.omf
%{_bindir}/glade-3
%{_datadir}/applications/glade-3.desktop
%{_datadir}/glade3/
%{_datadir}/icons/hicolor/*/apps/glade-3.*
%{_libdir}/glade3/modules/libgladegnome.so
%{_libdir}/glade3/modules/libgladegtk.so
%{_libdir}/glade3/modules/libgladepython.so

%files -n libgladeui-1-11
%defattr (-, root, root)
%{_libdir}/libgladeui*.so.*
# These directories are needed by third-party catalogs, and are explicitly
# referenced in the pkg-config file, so it makes sense to own them here
%dir %{_datadir}/glade3
%dir %{_datadir}/glade3/catalogs
%dir %{_datadir}/glade3/pixmaps
%dir %{_datadir}/glade3/pixmaps/hicolor
%dir %{_datadir}/glade3/pixmaps/hicolor/*
%dir %{_datadir}/glade3/pixmaps/hicolor/*/actions
%dir %{_libdir}/glade3
%dir %{_libdir}/glade3/modules

%files -n libgladeui-1-devel
%defattr (-, root, root)
%{_includedir}/libgladeui-1.0/
%{_libdir}/pkgconfig/gladeui-1.0.pc
%{_libdir}/libgladeui*.so
%doc %{_datadir}/gtk-doc/html/gladeui/

%files lang -f %{name}.lang

%changelog