Add an AppData file for the software center

This commit is contained in:
Richard Hughes 2015-03-26 16:34:00 +00:00
parent 3b8127f5ca
commit 0dfe500cdd
1 changed files with 48 additions and 1 deletions

View File

@ -1,6 +1,6 @@
Name: gpick
Version: 0.2.5
Release: 7%{?dist}
Release: 8%{?dist}
Summary: Advanced color picker
License: BSD
@ -40,12 +40,56 @@ export LDFLAGS="%{optflags}"
scons install DESTDIR=%{buildroot}/%{_prefix}
desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop
# Register as an application to be visible in the software center
#
# NOTE: It would be *awesome* if this file was maintained by the upstream
# project, translated and installed into the right place during `make install`.
#
# See http://www.freedesktop.org/software/appstream/docs/ for more details.
#
mkdir -p $RPM_BUILD_ROOT%{_datadir}/appdata
cat > $RPM_BUILD_ROOT%{_datadir}/appdata/%{name}.appdata.xml <<EOF
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2014 Ryan Lerch <rlerch@redhat.com> -->
<!--
BugReportURL: https://code.google.com/p/gpick/issues/detail?id=117
SentUpstream: 2014-06-14
-->
<application>
<id type="desktop">gpick.desktop</id>
<metadata_license>CC0-1.0</metadata_license>
<summary>Advanced color picker and color palette creator</summary>
<description>
<p>
Gpick is an application that allows you to sample any color from anywhere
on the desktop, and use it to create palettes (i.e. collections of colors)
for use in graphic design applications.
Gpick also has other features that help in the creation of color palettes,
such as: the ability to create a palette from an imported image, automatic
naming of colors, and a scheme generator.
Color palettes generated in Gpick can be exported many different formats,
including: Inkscape/Gimp Palettes (*.gpl), Adobe Swatch Exchange (*.ase),
and Alias/WaveFront Material (*.mtl).
</p>
</description>
<url type="homepage">https://code.google.com/p/gpick/</url>
<url type="bugtracker">https://code.google.com/p/gpick/issues/list</url>
<screenshots>
<screenshot type="default">http://wiki.gpick.googlecode.com/hg/images/main-page-gpick-screenshot.png</screenshot>
</screenshots>
<!-- FIXME: change this to an upstream email address for spec updates
<updatecontact>someone_who_cares@upstream_project.org</updatecontact>
-->
</application>
EOF
%find_lang %{name}
%files -f %{name}.lang
%doc %{_docdir}/%{name}/copyright
%{_bindir}/%{name}
%{_datadir}/%{name}
%{_datadir}/appdata/%{name}.appdata.xml
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/48x48/apps/%{name}.png
%{_datadir}/icons/hicolor/scalable/apps/%{name}.svg
@ -66,6 +110,9 @@ fi
/usr/bin/gtk-update-icon-cache -f %{_datadir}/icons/hicolor &>/dev/null || :
%changelog
* Thu Mar 26 2015 Richard Hughes <rhughes@redhat.com> - 0.2.5-8
- Add an AppData file for the software center
* Mon Jan 26 2015 Petr Machata <pmachata@redhat.com> - 0.2.5-7
- Rebuild for boost 1.57.0