%{!?python3_sitelib: %define python3_sitelib %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}

Summary:	A simple GNOME 3 maps application
Summary(ja):	GNOME 3 用マップアプリケーション
Name:		gnome-maps
Version:	3.20.1
Release:	1%{?_dist_release}
License:	GPLv2+
Group:		User Interface/Desktops
URL:		https://wiki.gnome.org/Apps/Maps

Source: http://ftp.gnome.org/pub/GNOME/sources/%{name}/3.20/%{name}-%{version}.tar.xz

BuildRoot: %{_tmppath}/%{name}-%{version}-root

BuildRequires:	gtk3-devel
BuildRequires:	gjs-devel >= 1.43.3
BuildRequires:	gobject-introspection-devel
BuildRequires:	geoclue2-devel
BuildRequires:	libgee-devel
BuildRequires:	folks-devel
BuildRequires:	geocode-glib-devel
BuildRequires:	libchamplain-devel

Requires(postun,posttrans):	desktop-file-utils

Vendor:		Project Vine
Distribution:	Vine Linux
Packager:	Takemikaduchi


%description
Music application designed for GNOME 3 

%description -l ja
gnome-music は GNOME3 向けに作られた音楽アプリケーションです。


%package        devel
Summary:        Development tools for %{name}
Summary(ja):    %{name} の開発環境
Group:          Development/Libraries
Requires:       %{name} = %{version}-%{release}
Requires:       pkgconfig

%description	devel
%{summary}


%prep
%setup -q

%build
%configure --disable-static

make %{?_smp_mflags}

%install
rm -rf $RPM_BUILD_ROOT

%{__make} install DESTDIR=${RPM_BUILD_ROOT}

find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} \;

rm -rf $RPM_BUILD_ROOT%{_docdir}/%{name}

%find_lang %{name} --with-gnome

%clean
rm -rf $RPM_BUILD_ROOT

%post
touch --no-create %{_datadir}/icons/hicolor &> /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
gtk-update-icon-cache %{_datadir}/icons/hicolor &> /dev/null || :
update-desktop-database -q &> /dev/null ||:
glib-compile-schemas %{_datadir}/glib-2.0/schemas ||:


%files -f %{name}.lang
%defattr(-,root,root,-)
%doc COPYING README NEWS
%{_bindir}/%{name}
%{_libdir}/%{name}/girepository-1.0/GnomeMaps-1.0.typelib
%{_libdir}/%{name}/libgnome-maps.so.*
%{_datadir}/appdata/org.gnome.Maps.appdata.xml
%{_datadir}/applications/org.gnome.Maps.desktop
%{_datadir}/dbus-1/services/org.gnome.Maps.service
%{_datadir}/glib-2.0/schemas/org.gnome.Maps.gschema.xml
%{_datadir}/%{name}
%{_datadir}/icons/*/*/*/*
%{_datadir}/gir-1.0/GnomeMaps-1.0.gir
%exclude %{_libdir}/%{name}/libgnome-maps.so


%changelog
* Mon Jul 18 2016 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.20.1-1
- new upstream release

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

* Sun Nov 01 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.18.1-1
- new upstream release

* Sat May 16 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.2-1
- new upstream release

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

* Mon Mar 30 2015 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.16.0-1
- new upstream release
- add BuildRequires: geoclue2-devel, libgee-devel, folks-devel, geocode-glib-devel, libchamplain-devel

* Sat Nov 22 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.14.2-2
- fix typo in Group

* Wed Nov 19 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.14.2-1
- new upstream release

* Wed Oct 29 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.14.1.2-1
- new upstream release

* Sat May 17 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.2-1
- new upstream release

* Sun Apr 20 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 3.12.1-1
- initial build

