solenv/bin/assemble-flatpak.sh | 25 ++++++++++++++++++------- solenv/flatpak-manifest.in | 4 +--- 2 files changed, 19 insertions(+), 10 deletions(-)
New commits: commit 11f6ca61d937e9c93a6f049ded534787544f6483 Author: Stephan Bergmann <[email protected]> AuthorDate: Tue Feb 12 16:07:28 2019 +0100 Commit: Stephan Bergmann <[email protected]> CommitDate: Thu Feb 14 10:54:53 2019 +0100 Merge in Flatpak improvements ...from <https://github.com/flathub/org.libreoffice.LibreOffice/>: commit ab8032d1e660db5e77ec7b64ac1d02e27941dfc5 Merge: d1aa013 42b6543 Author: stbergmann <[email protected]> Date: Wed Feb 13 10:01:33 2019 +0100 Merge pull request #73 from flathub/fix-quoting fix quoting commit 42b6543ee833e5610465118bbea310ab87807d48 Author: Stephan Bergmann <[email protected]> Date: Tue Feb 12 16:34:08 2019 +0100 fix quoting commit d1aa013fb631191174f6eb4d390ad5ea0b68a053 Merge: 35de93f dd48ab6 Author: stbergmann <[email protected]> Date: Tue Feb 12 10:33:21 2019 +0100 Merge pull request #69 from flathub/dotty-app-IDs rename sub-app .desktop files so they are strict sub-IDs commit dd48ab67b00859a36c3f40a08112afb6078deecc Author: Robert McQueen <[email protected]> Date: Fri Jun 1 12:27:05 2018 +0100 rename sub-app .desktop files so they are strict sub-IDs The org.libreoffice.LibreOffice-foo names are not actually sub-IDs of org.libreoffice.LibreOffice which means that Flatpak will not export the additional components in the appstream. Change the - to . so that the sub-apps are correctly within the org.libreoffice.LibreOffice namespace rather than a mere prefix match. Set the X-Flatpak-RenamedFrom list in the .desktop files to include both the original upstream names and the - delimited old IDs that we used previous in the Flatpak. https://github.com/flathub/org.libreoffice.LibreOffice/issues/36 Reviewed-on: https://gerrit.libreoffice.org/67737 Reviewed-by: Stephan Bergmann <[email protected]> Tested-by: Stephan Bergmann <[email protected]> (cherry picked from commit e69843768707146dcd9c294b2cabe721f37e90ac) ...plus follow-up e31c2c03f9ff06df553e577a1d9149ce75e7ff7f "Move desktop-file-edit calls to assemble-flatpak.sh" Change-Id: I27f9971e2b9297c24904c5095c1091d89d2e7800 Reviewed-on: https://gerrit.libreoffice.org/67804 Reviewed-by: Michael Stahl <[email protected]> Tested-by: Jenkins diff --git a/solenv/bin/assemble-flatpak.sh b/solenv/bin/assemble-flatpak.sh index 802c61cd8f86..6c0734178662 100755 --- a/solenv/bin/assemble-flatpak.sh +++ b/solenv/bin/assemble-flatpak.sh @@ -15,20 +15,31 @@ set -e cp -r "${PREFIXDIR?}"/lib/libreoffice /app/ -## libreoffice-*.desktop -> org.libreoffice.LibreOffice-*.desktop: +## libreoffice-*.desktop -> org.libreoffice.LibreOffice.*.desktop: mkdir -p /app/share/applications for i in "${PREFIXDIR?}"/share/applications/libreoffice-*.desktop do sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \ - -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' "$i" \ - >/app/share/applications/org.libreoffice.LibreOffice-"${i#"${PREFIXDIR?}"/share/applications/libreoffice-}" + -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice./' "$i" \ + >/app/share/applications/org.libreoffice.LibreOffice."${i#"${PREFIXDIR?}"/share/applications/libreoffice-}" done -mv /app/share/applications/org.libreoffice.LibreOffice-startcenter.desktop \ +mv /app/share/applications/org.libreoffice.LibreOffice.startcenter.desktop \ /app/share/applications/org.libreoffice.LibreOffice.desktop # Flatpak .desktop exports take precedence over system ones due to # the order of XDG_DATA_DIRS - re-associating text/plain seems a bit much -sed -i "s/text\/plain;//" /app/share/applications/org.libreoffice.LibreOffice-writer.desktop +sed -i "s/text\/plain;//" /app/share/applications/org.libreoffice.LibreOffice.writer.desktop + +desktop-file-edit --set-key=X-Endless-Alias --set-value=libreoffice-startcenter \ + --set-key=X-Flatpak-RenamedFrom --set-value='libreoffice-startcenter.desktop;' \ + /app/share/applications/org.libreoffice.LibreOffice.desktop +for i in base calc draw impress math writer xsltfilter +do + desktop-file-edit --set-key=X-Endless-Alias --set-value=libreoffice-"$i" \ + --set-key=X-Flatpak-RenamedFrom \ + --set-value="libreoffice-$i.desktop;org.libreoffice.LibreOffice-$i.desktop;" \ + /app/share/applications/org.libreoffice.LibreOffice."$i".desktop +done ## icons/hicolor/*/apps/libreoffice-* -> ## icons/hicolor/*/apps/org.libreoffice.LibreOffice-*: @@ -40,7 +51,7 @@ do cp -a "$i" \ "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")"/"$(basename "$i")" cp -a "$i" \ - "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-"${i##*/apps/libreoffice-}" + "$(dirname /app/share/icons/hicolor/"${i#"${PREFIXDIR?}"/share/icons/hicolor/}")"/org.libreoffice.LibreOffice."${i##*/apps/libreoffice-}" done mkdir -p /app/share/runtime/locale @@ -142,7 +153,7 @@ EOF # append the appdata for the different components for i in "${PREFIXDIR?}"/share/appdata/libreoffice-*.appdata.xml do - sed "1 d; s/<id>libreoffice/<id>org.libreoffice.LibreOffice/" "$i" \ + sed "1 d; s/<id>libreoffice-/<id>org.libreoffice.LibreOffice./" "$i" \ >>/app/share/appdata/org.libreoffice.LibreOffice.appdata.xml done diff --git a/solenv/flatpak-manifest.in b/solenv/flatpak-manifest.in index 47c1ee5119c2..0ebf18155326 100644 --- a/solenv/flatpak-manifest.in +++ b/solenv/flatpak-manifest.in @@ -563,9 +563,7 @@ "./autogen.sh --prefix=/run/build/libreoffice/inst --with-distro=LibreOfficeFlatpak", "make $(if test \"$FLATPAK_ARCH\" = i386; then printf build-nocheck; fi)", "make distro-pack-install", - "make cmd cmd='$(SRCDIR)/solenv/bin/assemble-flatpak.sh'", - "desktop-file-edit --set-key=X-Endless-Alias --set-value=libreoffice-startcenter /app/share/applications/org.libreoffice.LibreOffice.desktop", - "for i in base calc draw impress math writer xsltfilter; do desktop-file-edit --set-key=X-Endless-Alias --set-value=libreoffice-$i /app/share/applications/org.libreoffice.LibreOffice-$i.desktop; done" + "make cmd cmd='$(SRCDIR)/solenv/bin/assemble-flatpak.sh'" ] } ], _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
