Mercurial > octave
changeset 24890:d664734ce8eb stable
Use reverse DNS naming scheme for freedesktop application identifier
* etc/icons/org.octave.Octave.appdata.xml: Rename from octave.appdata.xml.in.
Hardcode the name of the corresponding desktop file.
* etc/icons/org.octave.Octave.desktop.in: Rename from octave.desktop.in.
* etc/module.mk (appdatadir, appdata_DATA, desktopdir, desktop_DATA): New
variables. (VENDOR): Delete no longer needed variable.
(%canon_reldir%_CLEANFILES): Adjust to renamed files.
(%canon_reldir%_EXTRA_DIST): Likewise.
(%reldir%/icons/octave.appdata.xml): Delete rule.
(%reldir%/icons/org.octave.Octave.desktop): Rename rule target.
(install-icons): Delete custom rules to install appdata and desktop files.
(uninstall-icons): Likewise.
* configure.ac: Remove call to OCTAVE_PROG_DESKTOP_FILE_INSTALL.
* acinclude.m4 (OCTAVE_PROG_DESKTOP_FILE_INSTALL): Delete macro.
author | Mike Miller <mtmiller@octave.org> |
---|---|
date | Wed, 14 Mar 2018 18:12:18 -0700 |
parents | 92aaa85c06b8 |
children | 120e75853dab 2e94172bc1c1 |
files | configure.ac etc/icons/octave.appdata.xml.in etc/icons/octave.desktop.in etc/icons/org.octave.Octave.appdata.xml etc/icons/org.octave.Octave.desktop.in etc/module.mk m4/acinclude.m4 |
diffstat | 7 files changed, 95 insertions(+), 113 deletions(-) [+] |
line wrap: on
line diff
--- a/configure.ac Wed Mar 14 17:58:27 2018 -0700 +++ b/configure.ac Wed Mar 14 18:12:18 2018 -0700 @@ -214,8 +214,6 @@ INSTALL_SCRIPT="${INSTALL}" AC_SUBST(INSTALL_SCRIPT) -OCTAVE_PROG_DESKTOP_FILE_INSTALL - ## Programs used when running Octave. OCTAVE_PROG_GHOSTSCRIPT OCTAVE_PROG_GNUPLOT
--- a/etc/icons/octave.appdata.xml.in Wed Mar 14 17:58:27 2018 -0700 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,65 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - Copyright (C) 2013-2017 Carnë Draug - - This file is part of Octave. - - Octave is free software: you can redistribute it and/or modify it - under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - Octave is distributed in the hope that it will be useful, but - WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with Octave; see the file COPYING. If not, see - <https://www.gnu.org/licenses/>. ---> -<component type="desktop"> - <id>%OCTAVE_DESKTOP_FILE%</id> - <metadata_license>FSFAP</metadata_license> - <project_license>GPL-3.0+</project_license> - <name>GNU Octave</name> - <summary>Interactive programming environment for numerical computations</summary> - - <description> - <p> - GNU Octave is a high-level interpreted language, primarily intended for - numerical computations. It provides capabilities for the numerical - solution of linear and nonlinear problems, and for performing other - numerical experiments. It also provides extensive graphics capabilities - for data visualization and manipulation. Octave is normally used through - its interactive command line interface, but it can also be used to write - non-interactive programs. The Octave language is quite similar to - Matlab so that most programs are easily portable. - </p> - <p> - Octave has extensive tools for solving common numerical linear algebra - problems, finding the roots of nonlinear equations, integrating ordinary - functions, manipulating polynomials, and integrating ordinary - differential and differential-algebraic equations. It is easily - extensible and customizable via user-defined functions written in - Octave's own language, or using dynamically loaded modules written in - C++, C, Fortran, or other languages. - </p> - </description> - - <screenshots> - <!-- - From: https://www.freedesktop.org/software/appstream/docs/ - All screenshots should have a 16:9 aspect ratio, and should have - a width that is no smaller than 620px. Screenshots should be in PNG - or JPEG format. PNG is the preferred format. - --> - <screenshot type="default"> - <image>https://www.gnu.org/software/octave/img/screenshot.png</image> - </screenshot> - </screenshots> - - <url type="homepage">http://www.octave.org</url> - <update_contact>maintainers@octave.org</update_contact> - <project_group>GNU</project_group> -</component>
--- a/etc/icons/octave.desktop.in Wed Mar 14 17:58:27 2018 -0700 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,14 +0,0 @@ -[Desktop Entry] -Name=GNU Octave -Comment=Scientific Computing -Comment[de]=Wissenschaftliches Rechnen -TryExec=%OCTAVE_PREFIX%/bin/octave -Exec=%OCTAVE_PREFIX%/bin/octave --gui %f -Icon=octave -Terminal=false -Type=Application -Categories=Education;Science;Math; -StartupNotify=false -StartupWMClass=octave-gui -MimeType=text/x-octave;text/x-matlab; -Keywords=science;math;matrix;numerical computation;plotting;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/etc/icons/org.octave.Octave.appdata.xml Wed Mar 14 18:12:18 2018 -0700 @@ -0,0 +1,65 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + Copyright (C) 2013-2017 Carnë Draug + + This file is part of Octave. + + Octave is free software: you can redistribute it and/or modify it + under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + Octave is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with Octave; see the file COPYING. If not, see + <https://www.gnu.org/licenses/>. +--> +<component type="desktop"> + <id>org.octave.Octave.desktop</id> + <metadata_license>FSFAP</metadata_license> + <project_license>GPL-3.0+</project_license> + <name>GNU Octave</name> + <summary>Interactive programming environment for numerical computations</summary> + + <description> + <p> + GNU Octave is a high-level interpreted language, primarily intended for + numerical computations. It provides capabilities for the numerical + solution of linear and nonlinear problems, and for performing other + numerical experiments. It also provides extensive graphics capabilities + for data visualization and manipulation. Octave is normally used through + its interactive command line interface, but it can also be used to write + non-interactive programs. The Octave language is quite similar to + Matlab so that most programs are easily portable. + </p> + <p> + Octave has extensive tools for solving common numerical linear algebra + problems, finding the roots of nonlinear equations, integrating ordinary + functions, manipulating polynomials, and integrating ordinary + differential and differential-algebraic equations. It is easily + extensible and customizable via user-defined functions written in + Octave's own language, or using dynamically loaded modules written in + C++, C, Fortran, or other languages. + </p> + </description> + + <screenshots> + <!-- + From: https://www.freedesktop.org/software/appstream/docs/ + All screenshots should have a 16:9 aspect ratio, and should have + a width that is no smaller than 620px. Screenshots should be in PNG + or JPEG format. PNG is the preferred format. + --> + <screenshot type="default"> + <image>https://www.gnu.org/software/octave/img/screenshot.png</image> + </screenshot> + </screenshots> + + <url type="homepage">http://www.octave.org</url> + <update_contact>maintainers@octave.org</update_contact> + <project_group>GNU</project_group> +</component>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/etc/icons/org.octave.Octave.desktop.in Wed Mar 14 18:12:18 2018 -0700 @@ -0,0 +1,14 @@ +[Desktop Entry] +Name=GNU Octave +Comment=Scientific Computing +Comment[de]=Wissenschaftliches Rechnen +TryExec=%OCTAVE_PREFIX%/bin/octave +Exec=%OCTAVE_PREFIX%/bin/octave --gui %f +Icon=octave +Terminal=false +Type=Application +Categories=Education;Science;Math; +StartupNotify=false +StartupWMClass=octave-gui +MimeType=text/x-octave;text/x-matlab; +Keywords=science;math;matrix;numerical computation;plotting;
--- a/etc/module.mk Wed Mar 14 17:58:27 2018 -0700 +++ b/etc/module.mk Wed Mar 14 18:12:18 2018 -0700 @@ -32,6 +32,16 @@ %canon_reldir%_EXTRA_DIST += \ $(etc_fonts_DATA) +appdatadir = $(datadir)/metainfo + +appdata_DATA = \ + %reldir%/icons/org.octave.Octave.appdata.xml + +desktopdir = $(datadir)/applications + +desktop_DATA = \ + %reldir%/icons/org.octave.Octave.desktop + icon_IMAGE_FILES = \ %reldir%/icons/octave-logo.svg \ %reldir%/icons/octave-sombrero.png @@ -58,30 +68,22 @@ %canon_reldir%_EXTRA_DIST += \ $(BUILT_ICONS) \ $(icon_IMAGE_FILES) \ - %reldir%/icons/octave.appdata.xml.in \ - %reldir%/icons/octave.desktop.in \ - %reldir%/icons/octave_branding_samples.svg + %reldir%/icons/octave_branding_samples.svg \ + %reldir%/icons/org.octave.Octave.appdata.xml \ + %reldir%/icons/org.octave.Octave.desktop.in image_DATA += \ $(icon_IMAGE_FILES) \ %reldir%/icons/octave-logo.ico -VENDOR = www.octave.org - DIRSTAMP_FILES += \ %reldir%/icons/$(octave_dirstamp) all-local: all-icons -all-icons: %reldir%/icons/octave.appdata.xml %reldir%/icons/octave.desktop $(BUILT_ICONS) +all-icons: %reldir%/icons/org.octave.Octave.desktop $(BUILT_ICONS) -%reldir%/icons/octave.appdata.xml: %reldir%/icons/octave.appdata.xml.in | %reldir%/icons/$(octave_dirstamp) - $(AM_V_GEN)rm -f $@-t $@ && \ - $(SED) < $< > $@-t \ - -e "s|%OCTAVE_DESKTOP_FILE%|${VENDOR}-octave.desktop|" && \ - mv $@-t $@ - -%reldir%/icons/octave.desktop: %reldir%/icons/octave.desktop.in | %reldir%/icons/$(octave_dirstamp) +%reldir%/icons/org.octave.Octave.desktop: %reldir%/icons/org.octave.Octave.desktop.in | %reldir%/icons/$(octave_dirstamp) $(AM_V_GEN)rm -f $@-t $@ && \ $(SED) < $< > $@-t \ -e "s|%OCTAVE_PREFIX%|${prefix}|" && \ @@ -102,10 +104,6 @@ uninstall-local: uninstall-icons install-icons: - -if test -n "$(DESKTOP_FILE_INSTALL)"; then \ - $(DESKTOP_FILE_INSTALL) --dir=$(DESTDIR)$(datadir)/applications \ - --vendor $(VENDOR) %reldir%/icons/octave.desktop; \ - fi for f in $(BUILT_PNG_ICONS); do \ size=`echo $$f | $(SED) -n -e "s/.*-\([0-9]\+\)\.png/\1/p"`; \ if test -f $$f; then d=; else d="$(srcdir)/"; fi; \ @@ -114,25 +112,18 @@ done $(MKDIR_P) $(DESTDIR)$(datadir)/icons/hicolor/scalable/apps $(INSTALL_DATA) $(srcdir)/%reldir%/icons/octave-logo.svg $(DESTDIR)$(datadir)/icons/hicolor/scalable/apps/octave.svg - $(MKDIR_P) $(DESTDIR)$(datadir)/appdata - $(INSTALL_DATA) %reldir%/icons/octave.appdata.xml $(DESTDIR)$(datadir)/appdata/$(VENDOR)-octave.appdata.xml uninstall-icons: - if test -n "$(DESKTOP_FILE_INSTALL)"; then \ - rm -f $(DESTDIR)$(datadir)/applications/$(VENDOR)-octave.desktop; \ - fi for f in $(BUILT_PNG_ICONS); do \ size=`echo $$f | $(SED) -n -e "s/.*-\([0-9]\+\)\.png/\1/p"`; \ rm -f $(DESTDIR)$(datadir)/icons/hicolor/$${size}x$${size}/apps/octave.png; \ done rm -f $(DESTDIR)$(datadir)/icons/hicolor/scalable/apps/octave.svg - rm -f $(DESTDIR)$(datadir)/appdata/$(VENDOR)-octave.appdata.xml EXTRA_DIST += $(%canon_reldir%_EXTRA_DIST) %canon_reldir%_CLEANFILES += \ - %reldir%/icons/octave.appdata.xml \ - %reldir%/icons/octave.desktop + %reldir%/icons/org.octave.Octave.desktop %canon_reldir%_MAINTAINERCLEANFILES += \ $(BUILT_ICONS)
--- a/m4/acinclude.m4 Wed Mar 14 17:58:27 2018 -0700 +++ b/m4/acinclude.m4 Wed Mar 14 18:12:18 2018 -0700 @@ -2841,13 +2841,6 @@ fi ]) dnl -dnl Find desktop-file-install program. -dnl -AC_DEFUN([OCTAVE_PROG_DESKTOP_FILE_INSTALL], [ - AC_CHECK_PROG(DESKTOP_FILE_INSTALL, desktop-file-install, desktop-file-install, []) - AC_SUBST(DESKTOP_FILE_INSTALL) -]) -dnl dnl Find find program. dnl ## Prefer GNU find if found.