File marco.spec of Package marco

#
# spec file for marco
#
# Copyright (c) 2014 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 http://bugs.opensuse.org/


Name:           marco
%define _libname libmarco-private0
Version:        1.8.2
Release:        0
License:        GPL-2.0+
Summary:        MATE window manager
Url:            http://mate-desktop.org/
Group:          System/GUI/Other
Source:         http://pub.mate-desktop.org/releases/1.8/%{name}-%{version}.tar.xz
%glib2_gsettings_schema_requires

BuildRequires:  fdupes
BuildRequires:  mate-common
BuildRequires:  mate-dialogs
BuildRequires:  pkgconfig(gtk+-2.0)
BuildRequires:  pkgconfig(libcanberra-gtk)
BuildRequires:  pkgconfig(libgtop-2.0)
BuildRequires:  pkgconfig(libstartup-notification-1.0)
BuildRequires:  pkgconfig(sm)
BuildRequires:  update-desktop-files
BuildRequires:  yelp-tools
Provides:       mate-window-manager = %{version}
Obsoletes:      mate-window-manager < %{version}
Obsoletes:      mate-window-manager-lang < %{version}
Recommends:     %{name}-lang

%description
Marco is a small window manager, using GTK+ to do everything. It is
developed mainly for the MATE Desktop.

%package -n %{_libname}
Summary:        MATE window manager shared libraries
Group:          System/GUI/Other

%description -n %{_libname}
Marco is a small window manager, using GTK+ to do everything. It is
developed mainly for the MATE Desktop.

%package themes
Summary:        MATE window manager themes
Group:          System/GUI/Other
Provides:       mate-window-manager-themes = %{version}
Obsoletes:      mate-window-manager-themes < %{version}
BuildArch:      noarch

%description themes
Marco is a small window manager, using GTK+ to do everything. It is
developed mainly for the MATE Desktop.

%package devel
Summary:        MATE window manager development files
Group:          Development/Libraries/Other
Provides:       mate-window-manager-devel = %{version}
Obsoletes:      mate-window-manager-devel < %{version}
Requires:       %{_libname} = %{version}

%description devel
Marco is a small window manager, using GTK+ to do everything. It is
developed mainly for the MATE Desktop.

%lang_package

%prep
%setup -q

%build
%configure \
    --libexecdir=%{_libexecdir}/%{name}             \
    --disable-static                                \
    --disable-scrollkeeper                          \
    --disable-schemas-install
make %{?_smp_mflags}

%install
%makeinstall
%find_lang %{name} %{?no_lang_C}
find %{buildroot}%{_libdir} -type f -name "*.la" -delete -print
%suse_update_desktop_file %{name}
%suse_update_desktop_file %{buildroot}%{_datadir}/mate/wm-properties/%{name}-wm.desktop
%fdupes %{buildroot}%{_datadir}/themes/eOS/
if [ -d %{buildroot}%{_datadir}/MateConf ]; then
   rm -r %{buildroot}%{_datadir}/MateConf/
fi

%post
%desktop_database_post
%glib2_gsettings_schema_post

%post -n %{_libname} -p /sbin/ldconfig

%postun
%desktop_database_postun
%glib2_gsettings_schema_postun

%postun -n %{_libname} -p /sbin/ldconfig

%files
%defattr(-,root,root)
%doc ChangeLog README COPYING
%dir %{_datadir}/%{name}
%dir %{_datadir}/%{name}/icons
%dir %{_datadir}/mate/wm-properties
%{_bindir}/%{name}*
%{_datadir}/applications/%{name}.desktop
%dir %{_datadir}/mate
%{_datadir}/mate/wm-properties/marco-wm.desktop
%{_datadir}/%{name}/icons/marco-window-demo.png
%{_datadir}/mate-control-center/keybindings/50-marco*.xml
%{_datadir}/glib-2.0/schemas/*.xml
%{_datadir}/help/C
%{_mandir}/man1/marco*.1.gz

%files -n %{_libname}
%defattr(-,root,root)
# marco requires libmarco-private0 and mate-control-center requires it too; make libmarco-private0 own
# usr/share/mate-control-center to avoid conflicts between packages
%dir %{_datadir}/mate-control-center
%dir %{_datadir}/mate-control-center/keybindings
%{_libdir}/*.so.*

%files themes
%defattr(-,root,root)
%{_datadir}/themes/ClearlooksRe/
%{_datadir}/themes/Dopple-Left/
%{_datadir}/themes/Dopple/
%{_datadir}/themes/DustBlue/
%{_datadir}/themes/Spidey-Left/
%{_datadir}/themes/Spidey/
%{_datadir}/themes/Splint-Left/
%{_datadir}/themes/Splint/
%{_datadir}/themes/WinMe/
%{_datadir}/themes/eOS/

%files devel
%defattr(-,root,root)
%dir %{_includedir}/marco-1
%dir %{_includedir}/marco-1/marco-private
%{_includedir}/marco-1/marco-private/*.h
%{_libdir}/*.so
%{_libdir}/pkgconfig/libmarco-private.pc

%files lang -f %{name}.lang
%defattr(-,root,root)

%changelog
openSUSE Build Service is sponsored by