Skip to content

Commit

Permalink
Update AppStream metadata (bug #64629).
Browse files Browse the repository at this point in the history
* etc/icons/org.octave.Octave.metainfo.xml: Rename from
org.octave.Octave.metainfo.xml and add more URLs.
* etc/module.mk: Adapt for changed file name. Change some variable, flag, and
Makefile target names to better match the file they are referring to.
* Makefile.am: Adapt for changed Makefile target name.
  • Loading branch information
Alexander Wilms committed Oct 13, 2023
1 parent 58e8cc1 commit 782df37
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ DIST_HOOKS := \
docs-dist-hook \
fix-file-perms-dist-hook \
hg-id-dist-hook \
appdata-dist-hook \
metainfo-dist-hook \
icons-dist-hook \
scripts-dist-hook

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,12 @@ along with Octave; see the file COPYING. If not, see

<url type="homepage">https://www.octave.org/</url>
<url type="bugtracker">https://bugs.octave.org/</url>
<url type="donation">https://www.octave.org/donate.html</url>
<url type="faq">https://wiki.octave.org/FAQ</url>
<url type="help">https://octave.org/support</url>
<url type="donation">https://www.octave.org/donate.html</url>
<url type="contact">https://octave.org/support</url>
<url type="vcs-browser">https://hg.savannah.gnu.org/hgweb/octave</url>
<url type="contribute">https://octave.org/get-involved</url>
<update_contact>[email protected]</update_contact>
<project_group>GNU</project_group>
<developer_name>John W. Eaton and others</developer_name>
Expand Down
24 changes: 12 additions & 12 deletions etc/module.mk
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,12 @@ endif
%canon_reldir%_EXTRA_DIST += \
$(fallback_FONT_FILES)

appdatadir = $(datadir)/metainfo
metainfodir = $(datadir)/metainfo

APPDATA_XML_FILE := \
%reldir%/icons/org.octave.Octave.appdata.xml
METAINFO_XML_FILE := \
%reldir%/icons/org.octave.Octave.metainfo.xml

appdata_DATA = $(APPDATA_XML_FILE)
metainfo_DATA = $(METAINFO_XML_FILE)

desktopdir = $(datadir)/applications

Expand Down Expand Up @@ -84,7 +84,7 @@ BUILT_ICONS = \
$(BUILT_ICONS) \
$(icon_IMAGE_FILES) \
%reldir%/icons/octave_branding_samples.svg \
%reldir%/icons/org.octave.Octave.appdata.xml \
%reldir%/icons/org.octave.Octave.metainfo.xml \
%reldir%/icons/org.octave.Octave.desktop.in

image_DATA += \
Expand Down Expand Up @@ -115,21 +115,21 @@ $(BUILT_PNG_ICONS): %reldir%/icons/octave-logo.svg | %reldir%/icons/$(octave_dir
mv $@-t $@

## Check that the release date and version number are in
## $(APPDATA_XML_FILE), but only for actual releases, which means
## $(METAINFO_XML_FILE), but only for actual releases, which means
## we skip the test if the minor version number is 0 or the patch
## version number is not 0.

appdata-dist-hook:
@test x"$(DIST_IGNORE_APPDATA_VERSION)" != x || \
metainfo-dist-hook:
@test x"$(DIST_IGNORE_METAINFO_VERSION)" != x || \
test $(OCTAVE_MINOR_VERSION) -eq 0 || \
test $(OCTAVE_PATCH_VERSION) -ne 0 || \
grep "<release *date=\"$(OCTAVE_RELEASE_DATE)\" *version=\"$(OCTAVE_VERSION)\"/>" $(srcdir)/$(APPDATA_XML_FILE) > /dev/null || \
grep "<release *date=\"$(OCTAVE_RELEASE_DATE)\" *version=\"$(OCTAVE_VERSION)\"/>" $(srcdir)/$(METAINFO_XML_FILE) > /dev/null || \
{ echo; \
echo "Packaging distribution requires the version number in the $(APPDATA_XML_FILE)."; \
echo "Please update first or pass DIST_IGNORE_APPDATA_VERSION=1."; \
echo "Packaging distribution requires the version number in the $(METAINFO_XML_FILE)."; \
echo "Please update first or pass DIST_IGNORE_METAINFO_VERSION=1."; \
echo "Cannot package distribution!"; \
echo; exit 1; }
.PHONY: appdata-dist-hook
.PHONY: metainfo-dist-hook

install-data-local: install-icons

Expand Down

0 comments on commit 782df37

Please sign in to comment.