Summary:	Editor/admin tool for dconf
Summary(ja):	dconf の編集/管理ツール
Name:		dconf-editor
Version:	3.36.4
Release:	1%{?_dist_release}
Group:		desktop-gnome
Vendor:		Project Vine
Distribution:	Vine Linux

License:	LGPL
%global		shortver %(echo %{version} | sed -e 's/\.[0-9]*$//')
Source0:	https://download.gnome.org/sources/%{name}/%{shortver}/%{name}-%{version}.tar.xz
BuildRoot:	%{_tmppath}/%{name}-%{version}-root

Requires:	dconf
Requires(postun,posttrans): glib2
Requires(post,postun):      gtk2
Requires(post,postun):      desktop-file-utils

BuildRequires:	meson
BuildRequires:	vala
BuildRequires:	dconf-devel
BuildRequires:	dconf-vala
BuildRequires:	gtk3-devel

%description
dconf-editor allows you to browse and modify dconf configuration.

%description -l ja
dconf-editor により dconf の設定を参照したり変更したりすることができます。


%prep
%setup -q


%build
%meson
%meson_build


%install
%{__rm} -rf ${RPM_BUILD_ROOT}
%meson_install

%find_lang %{name}


%clean
%{__rm} -rf ${RPM_BUILD_ROOT}


%post
touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
update-desktop-database -q &> /dev/null || :

%postun
if [ $1 -eq 0 ] ; then
    touch --no-create %{_datadir}/icons/hicolor &> /dev/null || :
    gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
    update-desktop-database -q &> /dev/null || :
    glib-compile-schemas %{_datadir}/glib-2.0/schemas ||:
fi

%posttrans
glib-compile-schemas %{_datadir}/glib-2.0/schemas ||:


%files -f %{name}.lang
%defattr(-, root, root, -)
%license COPYING
%doc README.md
%{_bindir}/dconf-editor
%{_datadir}/metainfo/ca.desrt.dconf-editor.appdata.xml
%{_datadir}/applications/ca.desrt.dconf-editor.desktop
%{_datadir}/dbus-1/services/ca.desrt.dconf-editor.service
%{_datadir}/glib-2.0/schemas/*.xml
%{_datadir}/icons/hicolor/*/apps/*
%{_datadir}/icons/hicolor/scalable/actions/*
%{_mandir}/man1/dconf-editor.1.gz
%dir %{_datadir}/bash-completion
%dir %{_datadir}/bash-completion/completions
%{_datadir}/bash-completion/completions/dconf-editor


%changelog
* Fri Aug 07 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.36.4-1
- new upstream release.

* Sun Jul 17 2016 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.20.3-1
- new upstream release

* Fri Nov 13 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.18.2-1
- new upstream release

* Sat Oct 31 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.18.1-1
- new upstream release

* Sun Apr 19 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.1-1
- new upstream release
- fix typo

* Sun Mar 29 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.0-1
- initial build

