[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2021-11-10 Thread Michael Stahl (via logerrit)
 flatpak/build.sh |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit cd86424a47e358335e108f3aa26565e3a2e3143c
Author: Michael Stahl 
AuthorDate: Fri Nov 5 21:38:05 2021 +0100
Commit: Stephan Bergmann 
CommitDate: Wed Nov 10 15:55:31 2021 +0100

flatpak: document that build.sh is obsolete

Change-Id: Ic60bef3cea601ee963100137245ba1041b959d2d
Reviewed-on: https://gerrit.libreoffice.org/c/dev-tools/+/124781
Tested-by: Stephan Bergmann 
Reviewed-by: Stephan Bergmann 

diff --git a/flatpak/build.sh b/flatpak/build.sh
index da677e7..7beafb9 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -4,6 +4,13 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at https://mozilla.org/MPL/2.0/.
 
+###
+#   WARNING   #
+###
+# this script is obsolete - flatpak is built with #
+# https://github.com/flathub/org.libreoffice.LibreOffice/ #
+###
+
 # This shell script creates a LibreOffice.flatpak bundle from a given git
 # branch/tag.
 #


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-10-20 Thread Stephan Bergmann
 flatpak/build.sh |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 9d0e66082481e227b935b6d02d905708f3fc9046
Author: Stephan Bergmann 
Date:   Fri Oct 20 15:56:24 2017 +0200

Still need to fetch updates for the lo repo if it's already there

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 3e8fffa..3447836 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -49,6 +49,8 @@ mkdir -p "${my_dir?}"
 
 if [ ! -e "${my_dir?}"/lo ]; then
  git clone --mirror git://gerrit.libreoffice.org/core "${my_dir?}"/lo
+else
+ git -C "${my_dir?}"/lo fetch
 fi
 
 rm -f "${my_dir?}"/manifest.in
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-09-18 Thread Stephan Bergmann
 flatpak/build.sh |   15 +++
 1 file changed, 7 insertions(+), 8 deletions(-)

New commits:
commit ae839720577de1c717cbad20c305ba592183096d
Author: Stephan Bergmann 
Date:   Mon Sep 18 13:15:34 2017 +0200

Reliably accept both tags and branches

The original code would not have fast-forwarded branches.  The new code 
avoids
that by not doing a local checkout anyway.  Additionally, --mirror ensures 
that
branch names don't need to be prefixed with "origin/" in the 'git show' 
command.

diff --git a/flatpak/build.sh b/flatpak/build.sh
index fab02d7..3e8fffa 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -47,17 +47,16 @@ my_gpgkeyid="${5?}"
 
 mkdir -p "${my_dir?}"
 
-if [ -e "${my_dir?}"/lo ]; then
- git -C "${my_dir?}"/lo fetch --tags
- git -C "${my_dir?}"/lo checkout "${my_gitbranch?}"
-else
- git clone --branch "${my_gitbranch?}" git://gerrit.libreoffice.org/core \
-  "${my_dir?}"/lo
+if [ ! -e "${my_dir?}"/lo ]; then
+ git clone --mirror git://gerrit.libreoffice.org/core "${my_dir?}"/lo
 fi
 
+rm -f "${my_dir?}"/manifest.in
+git -C "${my_dir?}"/lo show "${my_gitbranch?}":solenv/flatpak-manifest.in \
+ > "${my_dir?}"/manifest.in
+
 rm -f "${my_dir?}"/manifest.json
-sed "s/@BRANCH@/${my_gitbranch?}/" \
- < "${my_dir?}"/lo/solenv/flatpak-manifest.in > "${my_dir?}"/manifest.json
+sed "s!@BRANCH@!${my_gitbranch?}!" < manifest.in > "${my_dir?}"/manifest.json
 
 flatpak-builder --default-branch="${my_flatpakbranch?}" \
  --repo="${my_dir?}"/repository --gpg-homedir="${my_gpghomedir?}" \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-09-06 Thread Stephan Bergmann
 flatpak/build.sh |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 952da85614cfc59b378f1d13dfee60188cb5fb27
Author: Stephan Bergmann 
Date:   Wed Sep 6 10:19:18 2017 +0200

Adpat flatpak/build.sh to core change @SOURCE@ -> @BRANCH@

2a74f9d8055cadd3da00a45486a8fcdab3e94715 "Move git source details to
solenv/flatpak-manifest.in"

diff --git a/flatpak/build.sh b/flatpak/build.sh
index f1e7a4a..fab02d7 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -56,8 +56,7 @@ else
 fi
 
 rm -f "${my_dir?}"/manifest.json
-sed \
- "s!@SOURCE@!{ \"type\": \"git\", \"url\": 
\"git://gerrit.libreoffice.org/core\", \"branch\": \"${my_gitbranch?}\", 
\"disable-fsckobjects\": true }!" \
+sed "s/@BRANCH@/${my_gitbranch?}/" \
  < "${my_dir?}"/lo/solenv/flatpak-manifest.in > "${my_dir?}"/manifest.json
 
 flatpak-builder --default-branch="${my_flatpakbranch?}" \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-08-22 Thread Stephan Bergmann
 flatpak/build.sh |  422 +--
 1 file changed, 13 insertions(+), 409 deletions(-)

New commits:
commit d330520a5a3fa12dc8c9ef611ff9a0303abfa06d
Author: Stephan Bergmann 
Date:   Tue Aug 22 13:58:08 2017 +0200

Use manifest file from core repo

...which is placed there since core commit
68fda058972a6fbb38b797f50575b84f4cb3fab1 "Put flatpak-builder manifest file 
into
core repo"

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 6815bc5..f1e7a4a 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -34,7 +34,8 @@
 # TODO:
 #
 # * Explicitly specify the --arch to build?
-# * Properly encode my_{flatpak,git}branch in manifest.json
+# * Properly encode my_gitbranch into manifest.json (valid json syntax, then
+#   wrapped in valid sed syntax).
 
 set -e
 
@@ -46,415 +47,18 @@ my_gpgkeyid="${5?}"
 
 mkdir -p "${my_dir?}"
 
+if [ -e "${my_dir?}"/lo ]; then
+ git -C "${my_dir?}"/lo fetch --tags
+ git -C "${my_dir?}"/lo checkout "${my_gitbranch?}"
+else
+ git clone --branch "${my_gitbranch?}" git://gerrit.libreoffice.org/core \
+  "${my_dir?}"/lo
+fi
+
 rm -f "${my_dir?}"/manifest.json
-cat > "${my_dir?}"/manifest.json 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-08-21 Thread Stephan Bergmann
 flatpak/build.sh |  371 ++-
 1 file changed, 366 insertions(+), 5 deletions(-)

New commits:
commit b696672f49b7bebff4c2a57116537bf93c320fd5
Author: Stephan Bergmann 
Date:   Mon Aug 21 18:44:03 2017 +0200

Explicitly list 3rd-party dependencies in the manifest file

...instead of relying on 'make fetch' during the build (which allows to drop
the --share=network build-options override).  The list is based on the work
done at ramcq/libreoffice-flatpak on github.com, but adapted to current LO
master.  The plan is to ultimately move the manifest into the core LO git 
repo
and share it between this flatpak/build.sh and Flathub builds (for which not
downloading stuff during the build itself is a prerequisite).

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 6ddfc7f..6815bc5 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -64,14 +64,375 @@ cat > "${my_dir?}"/manifest.json 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-08-21 Thread Stephan Bergmann
 flatpak/build.sh |8 
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 8ea47acc0ee524c1142db46c21db5556ad815dc8
Author: Stephan Bergmann 
Date:   Mon Aug 21 16:00:49 2017 +0200

Move branch specification out of the manifest file

...in order to harmonize this manifest file with the one in
ramcq/libreoffice-flatpak on github.com

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 62b9ce0..6ddfc7f 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -50,7 +50,6 @@ rm -f "${my_dir?}"/manifest.json
 cat > "${my_dir?}"/manifest.json < "${my_dir?}"/manifest.json 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh flatpak/manifest.json

2017-08-07 Thread Stephan Bergmann
 flatpak/build.sh  |   74 +++---
 flatpak/manifest.json |   43 -
 2 files changed, 64 insertions(+), 53 deletions(-)

New commits:
commit af59595cc805f33ea4619d44862b1173d20fe057
Author: Stephan Bergmann 
Date:   Mon Aug 7 15:05:00 2017 +0200

Generate manifest.json during flatpak/build.sh

...filling in my_{git,flatpak}branch values.  Also, set disable-fsckobjects 
as
needed when cloning the LO repo.

diff --git a/flatpak/build.sh b/flatpak/build.sh
index ba9d33b..62b9ce0 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -4,22 +4,20 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-# This shell script creates a LibreOffice.flatpak bundle from a given
-# flatpak-builder manifest.json.
+# This shell script creates a LibreOffice.flatpak bundle from a given git
+# branch/tag.
 #
 # It expects five command line arguments, in the following order:
 # * An absolute pathname for a directory where the script does all its work.
-# * The absolute pathname of the manifest.json file.
-# * The flatpak branch name (which must match the "branch" value in the
-#   manifest.json file).
+# * The requested git branch/tag (i.e., the --branch argument to "git clone").
+# * The flatpak branch name.
 # * The absolute pathname of the GPG home directory (i.e., the --homedir=
 #   argument to gpg)
 # * The GPG key ID for signing.
 #
 # The script expects an installation of flatpak and availability of the
-# org.gnome.Platform 3.24 runtime (and SDK) from 
-# (or whatever is specified in the manifest.json file).  To obtain the latter,
-# do something like:
+# org.gnome.Platform 3.24 runtime (and SDK) from .
+# To obtain the latter, do something like:
 #
 #  $ flatpak remote-add --user --from gnome-sdk \
 # https://sdk.gnome.org/gnome.flatpakrepo
@@ -28,23 +26,79 @@
 #  ...
 #  $ flatpak update --user
 #
+# Setting disable-fsckobjects is needed to avoid "error: object
+# 8dbc86aa82fb73668816f228779b2094de546aa0: missingSpaceBeforeEmail: invalid
+# author/committer line - missing space before email", which has "Author: Andre
+# Fischer ".
+#
 # TODO:
 #
 # * Explicitly specify the --arch to build?
+# * Properly encode my_{flatpak,git}branch in manifest.json
 
 set -e
 
 my_dir="${1?}"
-my_manifest="${2?}"
+my_gitbranch="${2?}"
 my_flatpakbranch="${3?}"
 my_gpghomedir="${4?}"
 my_gpgkeyid="${5?}"
 
 mkdir -p "${my_dir?}"
 
+rm -f "${my_dir?}"/manifest.json
+cat > "${my_dir?}"/manifest.json 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh flatpak/manifest.json

2017-07-05 Thread Stephan Bergmann
 flatpak/build.sh  |   69 +++---
 flatpak/manifest.json |   43 +++
 2 files changed, 59 insertions(+), 53 deletions(-)

New commits:
commit 5801dc28ae9562107b8d0497fcca8081d296b35f
Author: Stephan Bergmann 
Date:   Wed Jul 5 13:14:50 2017 +0200

Switch flatpak/build.sh to using flatpak-builder

(the committed manifest.json is for LO branch master; building other 
branches
would need a modification of that file, adding a "branch" line to the
"libreoffice" module's sources)

diff --git a/flatpak/build.sh b/flatpak/build.sh
index dc1fd8f..ba9d33b 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -4,20 +4,22 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-# This shell script creates a LibreOffice.flatpak bundle from a given git
-# branch/tag.
+# This shell script creates a LibreOffice.flatpak bundle from a given
+# flatpak-builder manifest.json.
 #
 # It expects five command line arguments, in the following order:
 # * An absolute pathname for a directory where the script does all its work.
-# * The requested git branch/tag (i.e., the --branch argument to "git clone").
-# * The flatpak branch name.
+# * The absolute pathname of the manifest.json file.
+# * The flatpak branch name (which must match the "branch" value in the
+#   manifest.json file).
 # * The absolute pathname of the GPG home directory (i.e., the --homedir=
 #   argument to gpg)
 # * The GPG key ID for signing.
 #
 # The script expects an installation of flatpak and availability of the
-# org.gnome.Platform 3.24 runtime (and SDK) from .
-# To obtain the latter, do something like:
+# org.gnome.Platform 3.24 runtime (and SDK) from 
+# (or whatever is specified in the manifest.json file).  To obtain the latter,
+# do something like:
 #
 #  $ flatpak remote-add --user --from gnome-sdk \
 # https://sdk.gnome.org/gnome.flatpakrepo
@@ -30,63 +32,20 @@
 #
 # * Explicitly specify the --arch to build?
 
-
 set -e
 
 my_dir="${1?}"
-my_gitbranch="${2?}"
+my_manifest="${2?}"
 my_flatpakbranch="${3?}"
 my_gpghomedir="${4?}"
 my_gpgkeyid="${5?}"
 
 mkdir -p "${my_dir?}"
 
+flatpak-builder --repo="${my_dir?}"/repository \
+ --gpg-homedir="${my_gpghomedir?}" --gpg-sign="${my_gpgkeyid?}" --force-clean \
+ "${my_dir?}"/app "${my_manifest?}"
 
-# 1  Clone the LibreOffice git repo:
-
-if [ -e "${my_dir?}"/lo ]; then
- git -C "${my_dir?}"/lo fetch --tags
- git -C "${my_dir?}"/lo submodule foreach git fetch --tags
- git -C "${my_dir?}"/lo checkout "${my_gitbranch?}"
-else
- git clone --branch "${my_gitbranch?}" --recursive \
-  git://gerrit.libreoffice.org/core "${my_dir?}"/lo
-fi
-
-
-# 2  Build LibreOffice:
-
-rm -fr "${my_dir?}"/app "${my_dir?}"/build "${my_dir?}"/inst
-flatpak build-init "${my_dir?}"/app org.libreoffice.LibreOffice org.gnome.Sdk \
- org.gnome.Platform 3.24
-mkdir "${my_dir?}"/build
-flatpak build --build-dir="${my_dir?}"/build --share=network "${my_dir?}"/app \
- bash -c \
- '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
-  && make && make distro-pack-install-strip \
-  && make cmd cmd='\''$(SRCDIR)/solenv/bin/assemble-flatpak.sh'\' \
- bash "${my_dir?}"
-
-
-# 3  Assemble the app files and metadata:
-
-## see
-## 
-## for the appstream-compose command line:
-flatpak build --nofilesystem=host "${my_dir?}"/app appstream-compose \
- --prefix=/app --origin=flatpak --basename=org.libreoffice.LibreOffice \
- org.libreoffice.LibreOffice
-
-
-# 4  Generate repository, .flatpak bundle, and .flatpakref file
-
-flatpak build-finish --command=/app/libreoffice/program/soffice \
- --share=network --share=ipc --socket=x11 --socket=wayland --socket=pulseaudio 
\
- --socket=system-bus --socket=session-bus --filesystem=host \
- --env=LIBO_FLATPAK=1 "${my_dir?}"/app
-flatpak build-export --gpg-homedir="${my_gpghomedir?}" \
- --gpg-sign="${my_gpgkeyid?}" "${my_dir?}"/repository "${my_dir?}"/app \
- "${my_flatpakbranch?}"
 ## --prune-depth=1 leaves the one most recent older revision available; that
 ## keeps the repo from growing without bounds, but for one allows users to roll
 ## back at least one rev (if there's decent support for that; there's currently
@@ -97,17 +56,21 @@ flatpak build-update-repo --title='The Document Foundation 
LibreOffice' \
  --generate-static-deltas --prune --prune-depth=1 \
  --gpg-homedir="${my_gpghomedir?}" --gpg-sign="${my_gpgkeyid?}" \
  "${my_dir?}"/repository
+
 tar --create --file "${my_dir?}"/repository.tgz --gzip \
  --directory="${my_dir?}" repository
+
 rm -f "${my_dir?}"/key
 gpg2 --homedir="${my_gpghomedir?}" --output="${my_dir?}"/key --export \
  "${my_gpgkeyid?}"
+
 flatpak build-bundle \
  

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-07-04 Thread Stephan Bergmann
 flatpak/build.sh |   96 +--
 1 file changed, 2 insertions(+), 94 deletions(-)

New commits:
commit 777b01d4d7ea0ca2a855e36e87d366b458b8bd56
Author: Stephan Bergmann 
Date:   Tue Jul 4 17:13:40 2017 +0200

Break core solenv/bin/assemble-flatpak.sh out of flatpak/build.sh

,,,in preparation of moving to a flatpak-builder manifest.json approach

(corresponding core commit is 19c13650c81ae7e0ad6cf0d7b8661f8440ee7892 
"Break
solenv/bin/assemble-flatpak.sh out of dev-tools flatpak/build.sh")

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 5ff7b44..dc1fd8f 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -63,105 +63,13 @@ mkdir "${my_dir?}"/build
 flatpak build --build-dir="${my_dir?}"/build --share=network "${my_dir?}"/app \
  bash -c \
  '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
-  && make && make distro-pack-install-strip' \
+  && make && make distro-pack-install-strip \
+  && make cmd cmd='\''$(SRCDIR)/solenv/bin/assemble-flatpak.sh'\' \
  bash "${my_dir?}"
 
 
 # 3  Assemble the app files and metadata:
 
-cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
-## libreoffice-startcenter.desktop -> org.libreoffice.LibreOffice.desktop,
-## combining all libreoffice-*.desktop MimeType= lines:
-mkdir "${my_dir?}"/app/files/share
-mkdir "${my_dir?}"/app/files/share/applications
-my_mimetypes=$(awk -d 'BEGIN { FS="="; ORS=""; semi=0 }; \
- /^MimeType=/ && length($2) \
-  { if (semi) print ";"; print $2; semi = match($2, ";$") == 0 }' \
- "${my_dir?}"/inst/share/applications/libreoffice-*.desktop)
-sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \
- -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' \
- -e 's|^MimeType=.*$|MimeType='"$my_mimetypes"'|' \
- "${my_dir?}"/inst/share/applications/libreoffice-startcenter.desktop \
- > 
"${my_dir?}"/app/files/share/applications/org.libreoffice.LibreOffice.desktop
-## icons/hicolor/*/apps/libreoffice-startcenter.* ->
-## icons/hicolor/*/apps/org.libreoffice.LibreOffice-startcenter.*:
-mkdir "${my_dir?}"/app/files/share/icons
-for i in "${my_dir?}"/inst/share/icons/hicolor/*/apps/libreoffice-startcenter.*
-do
- mkdir -p \
-  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"
- cp -a "$i" \
-  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-startcenter."${i##*/apps/libreoffice-startcenter.}"
-done
-## org.libreoffice.LibreOffice.appdata.xml is manually derived from the various
-## inst/share/appdata/libreoffice-*.appdata.xml (at least recent GNOME Software
-## doesn't show more than five screenshots anyway, so restrict to one each from
-## the five libreoffice-*.appdata.xml: Writer, Calc, Impress, Draw, Base):
-mkdir "${my_dir?}"/app/files/share/appdata
-cat <<\EOF > \
- "${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice.appdata.xml
-
-
- org.libreoffice.LibreOffice.desktop
- CC0-1.0
- MPL-2.0
- LibreOffice
- The LibreOffice productivity suite
- 
-  LibreOffice is a powerful office suite.  Its clean interface and
-  feature-rich tools help you unleash your creativity and enhance your
-  productivity.  LibreOffice includes several applications that make it the 
most
-  powerful Free and Open Source office suite on the market: Writer (word
-  processing), Calc (spreadsheets), Impress (presentations), Draw (vector
-  graphics and flowcharts), Base (databases), and Math (formula editing).
-  LibreOffice supports opening and saving into a wide variety of formats, so
-  you can easily share documents with users of other popular office suites
-  without worrying about compatibility.
- 
- http://www.libreoffice.org/discover/libreoffice/
- https://bugs.documentfoundation.org/
- https://donate.libreoffice.org/
- https://wiki.documentfoundation.org/Faq
- http://www.libreoffice.org/get-help/documentation/
- https://wiki.documentfoundation.org/Translating_LibreOffice
- 
-  
-   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Writer-02-Table-of-Contents-Getting-Started-Guide-4-2.png
-   
-  
-  
-   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Calc-02-exemple-ods.png
-   
-  
-  
-   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Impress-01-Blank.png
-   
-  
-  
-   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Draw-02-Tiger-fdo82219.png
-   
-  
-  
-   
http://www.libreoffice.org/assets/Uploads/Screenshots/Base/Screenshot-78.png
-   
-  
- 
- The Document Foundation
- libreoffice_at_lists.freedesktop.org
- 
-  HiDpiIcon
-  HighContrast
-  ModernToolkit
-  UserDocs
- 
-
-EOF
-## see 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-07-03 Thread Stephan Bergmann
 flatpak/build.sh |   23 ---
 1 file changed, 23 deletions(-)

New commits:
commit f2a84891650b250871b3dcde25b76d5f0e233ada
Author: Stephan Bergmann 
Date:   Mon Jul 3 18:20:07 2017 +0200

No more need for /app/bin/xdg-open

See core commit da5356b099c2504b3e9238f1afce410233847f9d "Revert 
'Workaround to
call /app/bin/xdg-open when run under flatpak'".

diff --git a/flatpak/build.sh b/flatpak/build.sh
index f1687d2..5ff7b44 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -70,29 +70,6 @@ flatpak build --build-dir="${my_dir?}"/build --share=network 
"${my_dir?}"/app \
 # 3  Assemble the app files and metadata:
 
 cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
-## Per "man gdbus" and  (cf.
-## , comment 1 to "'man
-## gdbus': unclear what 'serialized GVariant' means for args to 'gdbus call'"),
-## the argument to the below xdg-open must be UTF-8 encoded, must not have 
"..."
-## or '...' as its outermost characters (as those should be interpreted by 
gdbus
-## as---unnecessary---quoting), and must not contain backslashes (as those 
would
-## need to be quoted as "\\"); for the first requirement, LO's
-## ShellExec::execute (shell/source/unix/exec/shellexec.cxx) encodes the
-## argument with osl_getThreadTextEncoding(), which these days hopefully is
-## always UTF-8 on Linux (and, hoping that the argument is a valid URI, it
-## should not contain any non-ASCII characters); for the latter two
-## requirements, hope that the argument is a valid absolute URI, and so should
-## not contain any double quotes or backslashes, nor should it contain single
-## quotes as its first and last character (where the first character needs to 
be
-## part of the URI scheme):
-mkdir "${my_dir?}"/app/files/bin
-cat <<\EOF > "${my_dir?}"/app/files/bin/xdg-open
-gdbus call --session --dest org.freedesktop.portal.Desktop \
- --object-path /org/freedesktop/portal/desktop \
- --method org.freedesktop.portal.OpenURI.OpenURI -- '' "$1" {}
-EOF
-chmod +x "${my_dir?}"/app/files/bin/xdg-open
 ## libreoffice-startcenter.desktop -> org.libreoffice.LibreOffice.desktop,
 ## combining all libreoffice-*.desktop MimeType= lines:
 mkdir "${my_dir?}"/app/files/share
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-07-03 Thread Stephan Bergmann
 flatpak/build.sh |   25 ++---
 1 file changed, 6 insertions(+), 19 deletions(-)

New commits:
commit 11bae62cc0cbd31c2e824ed24e465dc742574ef7
Author: Stephan Bergmann 
Date:   Mon Jul 3 15:36:52 2017 +0200

Use --share=network to fetch deps directly during 'flatpak build'

diff --git a/flatpak/build.sh b/flatpak/build.sh
index ffdc62b..f1687d2 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -54,33 +54,20 @@ else
 fi
 
 
-# 2  Fetch external dependencies of LibreOffice:
-
-rm -fr "${my_dir?}"/fetch
-mkdir "${my_dir?}"/fetch
-## Running autogen.sh in the host environment with the set of 
--without-system-*
-## from LibreOfficeFlatpak means that some implicit --with-system-* may happen
-## to not be satitisfied by the host environment, and necessary devel packages
-## need to be installed there at least temporarily:
-(cd "${my_dir?}"/fetch \
- && "${my_dir?}"/lo/autogen.sh --prefix="${my_dir?}"/inst \
-  --with-distro=LibreOfficeFlatpak --with-external-tar="${my_dir?}"/tar \
- && make fetch)
-
-
-# 3  Build LibreOffice:
+# 2  Build LibreOffice:
 
 rm -fr "${my_dir?}"/app "${my_dir?}"/build "${my_dir?}"/inst
 flatpak build-init "${my_dir?}"/app org.libreoffice.LibreOffice org.gnome.Sdk \
  org.gnome.Platform 3.24
 mkdir "${my_dir?}"/build
-flatpak build --build-dir="${my_dir?}"/build "${my_dir?}"/app bash -c \
+flatpak build --build-dir="${my_dir?}"/build --share=network "${my_dir?}"/app \
+ bash -c \
  '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
-  --with-external-tar="${1?}"/tar && make && make distro-pack-install-strip' \
+  && make && make distro-pack-install-strip' \
  bash "${my_dir?}"
 
 
-# 4  Assemble the app files and metadata:
+# 3  Assemble the app files and metadata:
 
 cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
 ## Per "man gdbus" and 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-05-10 Thread Stephan Bergmann
 flatpak/build.sh |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 22bb7bc2875d8b9816faf17f4068149f2b2f1a83
Author: Stephan Bergmann 
Date:   Wed May 10 16:59:19 2017 +0200

Strip flatpak builds

requires core commit 58891d589bd8da700f135b098dd50833277c65dc "Add
distro-pack-install-strip target"

diff --git a/flatpak/build.sh b/flatpak/build.sh
index b1d1b2d..ffdc62b 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -76,7 +76,7 @@ flatpak build-init "${my_dir?}"/app 
org.libreoffice.LibreOffice org.gnome.Sdk \
 mkdir "${my_dir?}"/build
 flatpak build --build-dir="${my_dir?}"/build "${my_dir?}"/app bash -c \
  '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
-  --with-external-tar="${1?}"/tar && make && make distro-pack-install' \
+  --with-external-tar="${1?}"/tar && make && make distro-pack-install-strip' \
  bash "${my_dir?}"
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-05-10 Thread Stephan Bergmann
 flatpak/build.sh |8 
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 80c169d3686c51c2f2322d7f60af7fb2e5785bc0
Author: Stephan Bergmann 
Date:   Wed May 10 16:55:35 2017 +0200

Bump GNOME platform to 3.24

...which bumps the underlying freedesktop platform from 1.4 to 1.6, and thus
off an underlying yocto platfrom that reportedly is only "community 
supported"
any longer.

diff --git a/flatpak/build.sh b/flatpak/build.sh
index efb056a..b1d1b2d 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -16,13 +16,13 @@
 # * The GPG key ID for signing.
 #
 # The script expects an installation of flatpak and availability of the
-# org.gnome.Platform 3.20 runtime (and SDK) from .
+# org.gnome.Platform 3.24 runtime (and SDK) from .
 # To obtain the latter, do something like:
 #
 #  $ flatpak remote-add --user --from gnome-sdk \
 # https://sdk.gnome.org/gnome.flatpakrepo
-#  $ flatpak install --user gnome-sdk org.gnome.Platform 3.20
-#  $ flatpak install --user gnome-sdk org.gnome.Sdk 3.20
+#  $ flatpak install --user gnome-sdk org.gnome.Platform 3.24
+#  $ flatpak install --user gnome-sdk org.gnome.Sdk 3.24
 #  ...
 #  $ flatpak update --user
 #
@@ -72,7 +72,7 @@ mkdir "${my_dir?}"/fetch
 
 rm -fr "${my_dir?}"/app "${my_dir?}"/build "${my_dir?}"/inst
 flatpak build-init "${my_dir?}"/app org.libreoffice.LibreOffice org.gnome.Sdk \
- org.gnome.Platform 3.20
+ org.gnome.Platform 3.24
 mkdir "${my_dir?}"/build
 flatpak build --build-dir="${my_dir?}"/build "${my_dir?}"/app bash -c \
  '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-04-10 Thread Stephan Bergmann
 flatpak/build.sh |   24 ++--
 1 file changed, 6 insertions(+), 18 deletions(-)

New commits:
commit 477b097bf59759744cd30c9404c02b1085243094
Author: Stephan Bergmann 
Date:   Mon Apr 10 15:11:37 2017 +0200

LO 5.3 and beyond no longer needs Perl:Archive-Zip

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 4d7c43f..efb056a 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -42,18 +42,7 @@ my_gpgkeyid="${5?}"
 mkdir -p "${my_dir?}"
 
 
-# 1  Install Perl:Archive-Zip not available in org.gnome.Sdk:
-
-if [ ! -e "${my_dir?}"/perl ]; then
- wget \
-  http://search.cpan.org/CPAN/authors/id/P/PH/PHRED/Archive-Zip-1.56.tar.gz \
-  -O "${my_dir?}"/Archive-Zip-1.56.tar.gz
- mkdir "${my_dir?}"/perl
- (cd "${my_dir?}"/perl && tar xf "${my_dir?}"/Archive-Zip-1.56.tar.gz)
-fi
-
-
-# 2  Clone the LibreOffice git repo:
+# 1  Clone the LibreOffice git repo:
 
 if [ -e "${my_dir?}"/lo ]; then
  git -C "${my_dir?}"/lo fetch --tags
@@ -65,7 +54,7 @@ else
 fi
 
 
-# 3  Fetch external dependencies of LibreOffice:
+# 2  Fetch external dependencies of LibreOffice:
 
 rm -fr "${my_dir?}"/fetch
 mkdir "${my_dir?}"/fetch
@@ -79,20 +68,19 @@ mkdir "${my_dir?}"/fetch
  && make fetch)
 
 
-# 4  Build LibreOffice:
+# 3  Build LibreOffice:
 
 rm -fr "${my_dir?}"/app "${my_dir?}"/build "${my_dir?}"/inst
 flatpak build-init "${my_dir?}"/app org.libreoffice.LibreOffice org.gnome.Sdk \
  org.gnome.Platform 3.20
 mkdir "${my_dir?}"/build
-flatpak build --build-dir="${my_dir?}"/build \
- --env=PERLLIB="${my_dir?}"/perl/Archive-Zip-1.56/lib "${my_dir?}"/app bash -c 
\
+flatpak build --build-dir="${my_dir?}"/build "${my_dir?}"/app bash -c \
  '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
   --with-external-tar="${1?}"/tar && make && make distro-pack-install' \
  bash "${my_dir?}"
 
 
-# 5  Assemble the app files and metadata:
+# 4  Assemble the app files and metadata:
 
 cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
 ## Per "man gdbus" and 

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-01-27 Thread Stephan Bergmann
 flatpak/build.sh |4 
 1 file changed, 4 insertions(+)

New commits:
commit 5bc19c0ed16ffcbfba1f1de54b6ebc81761483bb
Author: Stephan Bergmann 
Date:   Fri Jan 27 10:05:40 2017 +0100

Add cautionary comment

diff --git a/flatpak/build.sh b/flatpak/build.sh
index aeda2f3..4d7c43f 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -69,6 +69,10 @@ fi
 
 rm -fr "${my_dir?}"/fetch
 mkdir "${my_dir?}"/fetch
+## Running autogen.sh in the host environment with the set of 
--without-system-*
+## from LibreOfficeFlatpak means that some implicit --with-system-* may happen
+## to not be satitisfied by the host environment, and necessary devel packages
+## need to be installed there at least temporarily:
 (cd "${my_dir?}"/fetch \
  && "${my_dir?}"/lo/autogen.sh --prefix="${my_dir?}"/inst \
   --with-distro=LibreOfficeFlatpak --with-external-tar="${my_dir?}"/tar \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2017-01-27 Thread Stephan Bergmann
 flatpak/build.sh |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit c560168a11f06a471e1dcb513905411d53f82145
Author: Stephan Bergmann 
Date:   Fri Jan 27 10:04:09 2017 +0100

Update documented way to obtain GNOME SDK

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 5839afd..aeda2f3 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -19,7 +19,8 @@
 # org.gnome.Platform 3.20 runtime (and SDK) from .
 # To obtain the latter, do something like:
 #
-#  $ flatpak remote-add --user gnome-sdk http://sdk.gnome.org/repo/
+#  $ flatpak remote-add --user --from gnome-sdk \
+# https://sdk.gnome.org/gnome.flatpakrepo
 #  $ flatpak install --user gnome-sdk org.gnome.Platform 3.20
 #  $ flatpak install --user gnome-sdk org.gnome.Sdk 3.20
 #  ...
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-12-21 Thread Stephan Bergmann
 flatpak/build.sh |1 +
 1 file changed, 1 insertion(+)

New commits:
commit 908ccd7c681cafeca1460a26607f60b10e48a4b4
Author: Stephan Bergmann 
Date:   Wed Dec 21 14:14:39 2016 +0100

Add --runtime-repo to 'flatpak build-bundle' (new feature of Flatpak 0.8.0)

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 4215d0b..5839afd 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -239,6 +239,7 @@ gpg2 --homedir="${my_gpghomedir?}" 
--output="${my_dir?}"/key --export \
  "${my_gpgkeyid?}"
 flatpak build-bundle \
  
--repo-url=http://download.documentfoundation.org/libreoffice/flatpak/repository
 \
+ --runtime-repo=https://sdk.gnome.org/gnome.flatpakrepo \
  --gpg-keys="${my_dir?}"/key "${my_dir?}"/repository \
  "${my_dir?}"/LibreOffice.flatpak org.libreoffice.LibreOffice \
  "${my_flatpakbranch?}"
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-12-14 Thread Stephan Bergmann
 flatpak/build.sh |9 -
 1 file changed, 4 insertions(+), 5 deletions(-)

New commits:
commit 301a3d04d57eb5111908aecb603fcdd2dfc64ec1
Author: Stephan Bergmann 
Date:   Wed Dec 14 16:15:46 2016 +0100

Fix generation of LibreOffice.flatpakref

...and add RuntimeRepo= line in anticipation of future flatpak versions
supporting that.

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 84bcdd3..4215d0b 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -243,8 +243,7 @@ flatpak build-bundle \
  "${my_dir?}"/LibreOffice.flatpak org.libreoffice.LibreOffice \
  "${my_flatpakbranch?}"
 rm -f "${my_dir?}"/LibreOffice.flatpakref
-printf '[Flatpak Ref]\nTitle=The Document Foundation LibreOffice\n' \
- 'Name=org.libreoffice.LibreOffice\nBranch=%s\n' \
- 'Url=http://download.documentfoundation.org/libreoffice/flatpak/repository\n' 
\
- 'IsRuntime=False\nGPGKey=%s\n' "${my_flatpakbranch?}" \
- $(base64 --wrap=0 < "${my_dir?}"/key) > "${my_dir?}"/LibreOffice.flatpakref
+printf \
+ '[Flatpak Ref]\nTitle=The Document Foundation 
LibreOffice\nName=org.libreoffice.LibreOffice\nBranch=%s\nUrl=http://download.documentfoundation.org/libreoffice/flatpak/repository\nIsRuntime=False\nGPGKey=%s\nRuntimeRepo=https://sdk.gnome.org/gnome.flatpakrepo\n'
 \
+ "${my_flatpakbranch?}" "$(base64 --wrap=0 < "${my_dir?}"/key)" \
+ > "${my_dir?}"/LibreOffice.flatpakref
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-11-01 Thread Stephan Bergmann
 flatpak/build.sh |   28 ++--
 1 file changed, 22 insertions(+), 6 deletions(-)

New commits:
commit f96d7afbf282e5621697aca84177e42fe2cc2255
Author: Stephan Bergmann 
Date:   Tue Nov 1 16:50:21 2016 +0100

Adapt org.libreoffice.LibreOffice.appdata.xml

...to changes in core 6b5cbdf8330bc1516c775757e489716337868a9f "sysui: add
'translate' urls to AppData files"

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 2a663b2..84bcdd3 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -166,15 +166,31 @@ cat <<\EOF > \
  https://donate.libreoffice.org/
  https://wiki.documentfoundation.org/Faq
  http://www.libreoffice.org/get-help/documentation/
+ https://wiki.documentfoundation.org/Translating_LibreOffice
  
-  http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Writer-02-Table-of-Contents-Getting-Started-Guide-4-2.png
-  http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Calc-02-exemple-ods.png
-  http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Impress-01-Blank.png
-  http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Draw-02-Tiger-fdo82219.png
-  http://www.libreoffice.org/assets/Uploads/Screenshots/Base/Screenshot-78.png
+  
+   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Writer-02-Table-of-Contents-Getting-Started-Guide-4-2.png
+   
+  
+  
+   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Calc-02-exemple-ods.png
+   
+  
+  
+   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Impress-01-Blank.png
+   
+  
+  
+   
http://www.libreoffice.org/assets/Uploads/Discover/Screenshots/_resampled/ResizedImage400300-Draw-02-Tiger-fdo82219.png
+   
+  
+  
+   
http://www.libreoffice.org/assets/Uploads/Screenshots/Base/Screenshot-78.png
+   
+  
  
  The Document Foundation
- libreoffice_at_lists.freedesktop.org
+ libreoffice_at_lists.freedesktop.org
  
   HiDpiIcon
   HighContrast
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-11-01 Thread Stephan Bergmann
 flatpak/build.sh |   81 +++
 1 file changed, 64 insertions(+), 17 deletions(-)

New commits:
commit cb6ca493be62b59aa16c7ec6a051e594a1d92f18
Author: Stephan Bergmann 
Date:   Tue Nov 1 16:38:53 2016 +0100

Create a single-app LibreOffice.flatpak

...at least gnome-software in Fedora 25 doesn't handle .flatpak files 
containing
multiple .appdata.xml and/or .desktop files, so just provide one each, for 
the
"generic" LibreOffice application.

The included org.libreoffice.LibreOffice.desktop is a mechincally generated 
copy
of inst/share/applications/libreoffice-startcenter.desktop, with the 
MimeType=
lines from all libreoffice-*.desktop files merged into one.

The included org.libreoffice.LibreOffice.appdata.xml is manually derived 
from
the various source inst/share/appdata/libreoffice-*.appdata.xml files.

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 2b82313..2a663b2 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -90,7 +90,6 @@ flatpak build --build-dir="${my_dir?}"/build \
 # 5  Assemble the app files and metadata:
 
 cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
-mkdir "${my_dir?}"/app/files/bin
 ## Per "man gdbus" and  (cf.
 ## , comment 1 to "'man
@@ -107,35 +106,83 @@ mkdir "${my_dir?}"/app/files/bin
 ## not contain any double quotes or backslashes, nor should it contain single
 ## quotes as its first and last character (where the first character needs to 
be
 ## part of the URI scheme):
+mkdir "${my_dir?}"/app/files/bin
 cat <<\EOF > "${my_dir?}"/app/files/bin/xdg-open
 gdbus call --session --dest org.freedesktop.portal.Desktop \
  --object-path /org/freedesktop/portal/desktop \
  --method org.freedesktop.portal.OpenURI.OpenURI -- '' "$1" {}
 EOF
 chmod +x "${my_dir?}"/app/files/bin/xdg-open
+## libreoffice-startcenter.desktop -> org.libreoffice.LibreOffice.desktop,
+## combining all libreoffice-*.desktop MimeType= lines:
 mkdir "${my_dir?}"/app/files/share
 mkdir "${my_dir?}"/app/files/share/applications
-## libreoffice-*.desktop -> org.libreoffice.LibreOffice-*.desktop:
-for i in "${my_dir?}"/inst/share/applications/libreoffice-*.desktop; do
- sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \
-  -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' "$i" \
-  > 
"${my_dir?}"/app/files/share/applications/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
-done
+my_mimetypes=$(awk -d 'BEGIN { FS="="; ORS=""; semi=0 }; \
+ /^MimeType=/ && length($2) \
+  { if (semi) print ";"; print $2; semi = match($2, ";$") == 0 }' \
+ "${my_dir?}"/inst/share/applications/libreoffice-*.desktop)
+sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \
+ -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' \
+ -e 's|^MimeType=.*$|MimeType='"$my_mimetypes"'|' \
+ "${my_dir?}"/inst/share/applications/libreoffice-startcenter.desktop \
+ > 
"${my_dir?}"/app/files/share/applications/org.libreoffice.LibreOffice.desktop
+## icons/hicolor/*/apps/libreoffice-startcenter.* ->
+## icons/hicolor/*/apps/org.libreoffice.LibreOffice-startcenter.*:
 mkdir "${my_dir?}"/app/files/share/icons
-## icons/hicolor/*/apps/libreoffice-* ->
-## icons/hicolor/*/apps/org.libreoffice.LibreOffice-*:
-for i in "${my_dir?}"/inst/share/icons/hicolor/*/apps/libreoffice-*; do
+for i in "${my_dir?}"/inst/share/icons/hicolor/*/apps/libreoffice-startcenter.*
+do
  mkdir -p \
   "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"
  cp -a "$i" \
-  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-"${i##*/apps/libreoffice-}"
+  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-startcenter."${i##*/apps/libreoffice-startcenter.}"
 done
-## libreoffice-*.appdata.xml -> org.libreoffice.LibreOffice-*.appdata.xml:
+## org.libreoffice.LibreOffice.appdata.xml is manually derived from the various
+## inst/share/appdata/libreoffice-*.appdata.xml (at least recent GNOME Software
+## doesn't show more than five screenshots anyway, so restrict to one each from
+## the five libreoffice-*.appdata.xml: Writer, Calc, Impress, Draw, Base):
 mkdir "${my_dir?}"/app/files/share/appdata
-for i in "${my_dir?}"/inst/share/appdata/libreoffice-*.appdata.xml; do
- sed -e 's/libreoffice-/org.libreoffice.LibreOffice-/' "$i" \
-  > 
"${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
-done
+cat <<\EOF > \
+ "${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice.appdata.xml
+
+
+ org.libreoffice.LibreOffice.desktop
+ CC0-1.0
+ MPL-2.0
+ LibreOffice
+ The LibreOffice productivity suite
+ 
+  

[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-10-31 Thread Stephan Bergmann
 flatpak/build.sh |   11 ++-
 1 file changed, 6 insertions(+), 5 deletions(-)

New commits:
commit af2a45c9cc2f64544d926cb94f064ee463f9674a
Author: Stephan Bergmann 
Date:   Mon Oct 31 16:07:26 2016 +0100

Fix commenting on what is done step-by-step

diff --git a/flatpak/build.sh b/flatpak/build.sh
index c1cd891..2b82313 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -130,6 +130,12 @@ for i in 
"${my_dir?}"/inst/share/icons/hicolor/*/apps/libreoffice-*; do
  cp -a "$i" \
   "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-"${i##*/apps/libreoffice-}"
 done
+## libreoffice-*.appdata.xml -> org.libreoffice.LibreOffice-*.appdata.xml:
+mkdir "${my_dir?}"/app/files/share/appdata
+for i in "${my_dir?}"/inst/share/appdata/libreoffice-*.appdata.xml; do
+ sed -e 's/libreoffice-/org.libreoffice.LibreOffice-/' "$i" \
+  > 
"${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
+done
 ## see  for further places where build-finish would
 ## look for data:
@@ -139,11 +145,6 @@ done
 ## see
 ## 
 ## for the appstream-compose command line:
-mkdir "${my_dir?}"/app/files/share/appdata
-for i in "${my_dir?}"/inst/share/appdata/libreoffice-*.appdata.xml; do
- sed -e 's/libreoffice-/org.libreoffice.LibreOffice-/' "$i" \
-  > 
"${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
-done
 flatpak build --nofilesystem=host "${my_dir?}"/app appstream-compose \
  --prefix=/app --origin=flatpak --basename=org.libreoffice.LibreOffice \
  org.libreoffice.LibreOffice-{base,calc,draw,impress,writer}
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-10-18 Thread Stephan Bergmann
 flatpak/build.sh |8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

New commits:
commit 14471950f1c5b99ceb86491ac6006a30178f3467
Author: Stephan Bergmann 
Date:   Tue Oct 18 09:56:31 2016 +0200

Also generate a LibreOffice.flatpakref file

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 8b381c2..c1cd891 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -149,7 +149,7 @@ flatpak build --nofilesystem=host "${my_dir?}"/app 
appstream-compose \
  org.libreoffice.LibreOffice-{base,calc,draw,impress,writer}
 
 
-# 6  Generate bundle
+# 6  Generate repository, .flatpak bundle, and .flatpakref file
 
 flatpak build-finish --command=/app/libreoffice/program/soffice \
  --share=network --share=ipc --socket=x11 --socket=wayland --socket=pulseaudio 
\
@@ -178,3 +178,9 @@ flatpak build-bundle \
  --gpg-keys="${my_dir?}"/key "${my_dir?}"/repository \
  "${my_dir?}"/LibreOffice.flatpak org.libreoffice.LibreOffice \
  "${my_flatpakbranch?}"
+rm -f "${my_dir?}"/LibreOffice.flatpakref
+printf '[Flatpak Ref]\nTitle=The Document Foundation LibreOffice\n' \
+ 'Name=org.libreoffice.LibreOffice\nBranch=%s\n' \
+ 'Url=http://download.documentfoundation.org/libreoffice/flatpak/repository\n' 
\
+ 'IsRuntime=False\nGPGKey=%s\n' "${my_flatpakbranch?}" \
+ $(base64 --wrap=0 < "${my_dir?}"/key) > "${my_dir?}"/LibreOffice.flatpakref
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-07-14 Thread Stephan Bergmann
 flatpak/build.sh |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit bb5ef7f62939e68969a3bc36215f6faa1013ade2
Author: Stephan Bergmann 
Date:   Thu Jul 14 08:56:12 2016 +0200

Set off gdbus call args with --

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 1d4216a..8b381c2 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -110,7 +110,7 @@ mkdir "${my_dir?}"/app/files/bin
 cat <<\EOF > "${my_dir?}"/app/files/bin/xdg-open
 gdbus call --session --dest org.freedesktop.portal.Desktop \
  --object-path /org/freedesktop/portal/desktop \
- --method org.freedesktop.portal.OpenURI.OpenURI '' "$1" {}
+ --method org.freedesktop.portal.OpenURI.OpenURI -- '' "$1" {}
 EOF
 chmod +x "${my_dir?}"/app/files/bin/xdg-open
 mkdir "${my_dir?}"/app/files/share
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-06-09 Thread Stephan Bergmann
 flatpak/build.sh |   13 ++---
 1 file changed, 10 insertions(+), 3 deletions(-)

New commits:
commit 9cfedef96dc5421cf72c563632bcf0030ee3c653
Author: Stephan Bergmann 
Date:   Thu Jun 9 15:10:56 2016 +0200

flatpak/build.sh: Prune everything but current and prev version from repo

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 03bfc2d..4cf537f 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -126,7 +126,7 @@ flatpak build --nofilesystem=host "${my_dir?}"/app 
appstream-compose \
  org.libreoffice.LibreOffice-{base,calc,draw,impress,writer}
 
 
-# 6  Generate bundle:
+# 6  Generate bundle
 
 flatpak build-finish --command=/app/libreoffice/program/soffice \
  --share=network --share=ipc --socket=x11 --socket=wayland --socket=pulseaudio 
\
@@ -135,9 +135,16 @@ flatpak build-finish 
--command=/app/libreoffice/program/soffice \
 flatpak build-export --gpg-homedir="${my_gpghomedir?}" \
  --gpg-sign="${my_gpgkeyid?}" "${my_dir?}"/repository "${my_dir?}"/app \
  "${my_flatpakbranch?}"
+## --prune-depth=1 leaves the one most recent older revision available; that
+## keeps the repo from growing without bounds, but for one allows users to roll
+## back at least one rev (if there's decent support for that; there's currently
+## "flatpak update --commit="), and for another makes --generate-static-deltas
+## provide fast deltas at least from that prev rev (in addition to fast deltas
+## "from nothing"):
 flatpak build-update-repo --title='The Document Foundation LibreOffice' \
- --generate-static-deltas --prune --gpg-homedir="${my_gpghomedir?}" \
- --gpg-sign="${my_gpgkeyid?}" "${my_dir?}"/repository
+ --generate-static-deltas --prune --prune-depth=1 \
+ --gpg-homedir="${my_gpghomedir?}" --gpg-sign="${my_gpgkeyid?}" \
+ "${my_dir?}"/repository
 tar --create --file "${my_dir?}"/repository.tgz --gzip \
  --directory="${my_dir?}" repository
 rm -f "${my_dir?}"/key
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-05-31 Thread Stephan Bergmann
 flatpak/build.sh |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 2491df87fada3b8accb022ae65ffee187bfca9fe
Author: Stephan Bergmann 
Date:   Tue May 31 17:54:13 2016 +0200

flatpak/build.sh: Remove "Fresh" from repo title

(repo can potentially host more branches than just the "fresh" one)

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 96f4578..03bfc2d 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -135,7 +135,7 @@ flatpak build-finish 
--command=/app/libreoffice/program/soffice \
 flatpak build-export --gpg-homedir="${my_gpghomedir?}" \
  --gpg-sign="${my_gpgkeyid?}" "${my_dir?}"/repository "${my_dir?}"/app \
  "${my_flatpakbranch?}"
-flatpak build-update-repo --title='The Document Foundation LibreOffice Fresh' \
+flatpak build-update-repo --title='The Document Foundation LibreOffice' \
  --generate-static-deltas --prune --gpg-homedir="${my_gpghomedir?}" \
  --gpg-sign="${my_gpgkeyid?}" "${my_dir?}"/repository
 tar --create --file "${my_dir?}"/repository.tgz --gzip \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-05-27 Thread Stephan Bergmann
 flatpak/build.sh |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 0d8364935b91e58761ae0ed4274e0e71c86e40ef
Author: Stephan Bergmann 
Date:   Fri May 27 13:19:02 2016 +0200

typo

diff --git a/flatpak/build.sh b/flatpak/build.sh
index 8ceb5c6..1ce36f4 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -138,6 +138,6 @@ tar --create --file "${my_dir?}"/repository.tgz --gzip \
 gpg2 --homedir="${my_gpghomedir?}" --output="${my_dir?}"/key --export \
  "${my_gpgkeyid?}"
 flatpak build-bundle \
- 
--repo-url=http://download.documentfoundation.org/libreoffice/flatpack/repository
 \
+ 
--repo-url=http://download.documentfoundation.org/libreoffice/flatpak/repository
 \
  --gpg-keys="${my_dir?}"/key "${my_dir?}"/repository \
  "${my_dir?}"/LibreOffice.flatpak org.libreoffice.LibreOffice
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-05-26 Thread Stephan Bergmann
 flatpak/build.sh |4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 64e7fa43691478905812dec06516be8e3aa515ed
Author: Stephan Bergmann 
Date:   Thu May 26 09:45:08 2016 +0200

flatpak/build.sh: git fetch --tags

diff --git a/flatpak/build.sh b/flatpak/build.sh
index c8fb676..9cef544 100755
--- a/flatpak/build.sh
+++ b/flatpak/build.sh
@@ -54,8 +54,8 @@ fi
 # 2  Clone the LibreOffice git repo:
 
 if [ -e "${my_dir?}"/lo ]; then
- git -C "${my_dir?}"/lo pull
- git -C "${my_dir?}"/lo submodule update
+ git -C "${my_dir?}"/lo fetch --tags
+ git -C "${my_dir?}"/lo submodule foreach git fetch --tags
  git -C "${my_dir?}"/lo checkout "${my_branch?}"
 else
  git clone --branch "${my_branch?}" --recursive \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] dev-tools.git: flatpak/build.sh

2016-05-13 Thread Stephan Bergmann
 flatpak/build.sh |  124 +++
 1 file changed, 124 insertions(+)

New commits:
commit 2b7f4451ed4aa6b23a2054fd62af9fbdb0d6e151
Author: Stephan Bergmann 
Date:   Fri May 13 13:09:40 2016 +0200

Flatpak build script

diff --git a/flatpak/build.sh b/flatpak/build.sh
new file mode 100755
index 000..1e583fc
--- /dev/null
+++ b/flatpak/build.sh
@@ -0,0 +1,124 @@
+# This file is part of the LibreOffice project.
+#
+# This Source Code Form is subject to the terms of the Mozilla Public
+# License, v. 2.0. If a copy of the MPL was not distributed with this
+# file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+# This shell script creates a LibreOffice.flatpak bundle from a given git
+# branch/tag.
+#
+# It expects two command line arguments, an absolute pathname for a directory
+# where the script does all its work (which must not yet exist), followed by 
the
+# requested git branch/tag (i.e., the --branch argument to "git clone").
+#
+# The script expects an installation of flatpak (nee xdg-app). and availability
+# of the org.gnome.Platform 3.20 runtime (and SDK) from
+# .  To obtain the latter, do something like:
+#
+#  $ xdg-app --user remote-add gnome-sdk http://sdk.gnome.org/repo/
+#  $ xdg-app --user install gnome-sdk org.gnome.Platform 3.20
+#  $ xdg-app --user install gnome-sdk org.gnome.Sdk 3.20
+#
+# TODO:
+#
+# * Fix the --repo-url=http://libreoffice.org/TODO URL in the build-bundle
+# step.
+#
+# * GPG signing.
+#
+# * Explicitly specify the --arch to build?
+#
+# * The script still calls the old "xdg-app" tool throughout.  All these calls
+# shall be rewritten to "flatpak" in environments that use the new name.
+
+
+set -e
+
+my_dir="${1?}"
+my_branch="${2?}"
+
+mkdir "${my_dir?}"
+
+
+# 1  Install Perl:Archive-Zip not available in org.gnome.Sdk:
+
+wget http://search.cpan.org/CPAN/authors/id/P/PH/PHRED/Archive-Zip-1.56.tar.gz 
\
+ -O "${my_dir?}"/Archive-Zip-1.56.tar.gz
+mkdir "${my_dir?}"/perl
+(cd "${my_dir?}"/perl && tar xf "${my_dir?}"/Archive-Zip-1.56.tar.gz)
+
+
+# 2  Clone the LibreOffice git repo:
+
+git clone --branch "${my_branch?}" --recursive \
+ git://gerrit.libreoffice.org/core "${my_dir?}"/lo
+
+
+# 3  Fetch external dependencies of LibreOffice:
+
+mkdir "${my_dir?}"/fetch
+(cd "${my_dir?}"/fetch \
+ && "${my_dir?}"/lo/autogen.sh --prefix="${my_dir?}"/inst \
+  --with-distro=LibreOfficeFlatpak --with-external-tar="${my_dir?}"/tar \
+ && make fetch)
+
+
+# 4  Build LibreOffice:
+
+xdg-app build-init "${my_dir?}"/app org.libreoffice.LibreOffice org.gnome.Sdk \
+ org.gnome.Platform 3.20
+mkdir "${my_dir?}"/build
+xdg-app build --build-dir="${my_dir?}"/build \
+ --env=PERLLIB="${my_dir?}"/perl/Archive-Zip-1.56/lib "${my_dir?}"/app bash -c 
\
+ '"${1?}"/lo/autogen.sh --prefix="${1?}"/inst --with-distro=LibreOfficeFlatpak 
\
+  --with-external-tar="${1?}"/tar && make && make distro-pack-install' \
+ bash "${my_dir?}"
+
+
+# 5  Assemble the app files and metadata:
+
+cp -r "${my_dir?}"/inst/lib/libreoffice "${my_dir?}"/app/files/
+mkdir "${my_dir?}"/app/files/share
+mkdir "${my_dir?}"/app/files/share/applications
+## libreoffice-*.desktop -> org.libreoffice.LibreOffice-*.desktop:
+for i in "${my_dir?}"/inst/share/applications/libreoffice-*.desktop; do
+ sed -e 's,^Exec=libreoffice,Exec=/app/libreoffice/program/soffice,' \
+  -e 's/^Icon=libreoffice-/Icon=org.libreoffice.LibreOffice-/' "$i" \
+  > 
"${my_dir?}"/app/files/share/applications/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
+done
+mkdir "${my_dir?}"/app/files/share/icons
+## icons/hicolor/*/apps/libreoffice-* ->
+## icons/hicolor/*/apps/org.libreoffice.LibreOffice-*:
+for i in "${my_dir?}"/inst/share/icons/hicolor/*/apps/libreoffice-*; do
+ mkdir -p \
+  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"
+ cp -a "$i" \
+  "$(dirname 
"${my_dir?}"/app/files/share/icons/hicolor/"${i#"${my_dir?}"/inst/share/icons/hicolor/}")"/org.libreoffice.LibreOffice-"${i##*/apps/libreoffice-}"
+done
+## see git://anongit.freedesktop.org/xdg-app/xdg-app
+## app/flatpak-builtins-build-finish.c for further places where build-finish
+## would look for data:
+## cp ... "${my_dir?}"/app/files/share/dbus-1/services/
+## cp ... "${my_dir?}"/app/files/share/gnome-shell/search-providers/
+##
+## see git://anongit.freedesktop.org/xdg-app/xdg-app builder/builder-manifest.c
+## for the appstream-compose command line:
+mkdir "${my_dir?}"/app/files/share/appdata
+for i in "${my_dir?}"/inst/share/appdata/libreoffice-*.appdata.xml; do
+ sed -e 's/libreoffice-/org.libreoffice.LibreOffice-/' "$i" \
+  > 
"${my_dir?}"/app/files/share/appdata/org.libreoffice.LibreOffice-"${i##*/libreoffice-}"
+done
+xdg-app build --nofilesystem=host "${my_dir?}"/app appstream-compose \
+ --prefix=/app --origin=flatpak --basename=org.libreoffice.LibreOffice \
+