Hello community,

here is the log from the commit of package flatpak-builder for openSUSE:Factory 
checked in at 2020-08-25 09:35:28
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/flatpak-builder (Old)
 and      /work/SRC/openSUSE:Factory/.flatpak-builder.new.3399 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "flatpak-builder"

Tue Aug 25 09:35:28 2020 rev:14 rq:828951 version:1.0.11

Changes:
--------
--- /work/SRC/openSUSE:Factory/flatpak-builder/flatpak-builder.changes  
2019-10-28 16:59:55.637726205 +0100
+++ 
/work/SRC/openSUSE:Factory/.flatpak-builder.new.3399/flatpak-builder.changes    
    2020-08-25 09:36:44.396140169 +0200
@@ -1,0 +2,11 @@
+Sat Aug 22 13:16:01 UTC 2020 - Bjørn Lie <[email protected]>
+
+- Update to version 1.0.11:
+  + Use brz instead of bzr fom bzr repos (if available).
+  + Fix run-tests with --sandbox and empty test-args.
+- Changes from version 1.0.10:
+  + Support for 7zip archives.
+  + Allow overriding archive type.
+  + Support --token-type option.
+
+-------------------------------------------------------------------

Old:
----
  flatpak-builder-1.0.9.tar.xz

New:
----
  flatpak-builder-1.0.11.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ flatpak-builder.spec ++++++
--- /var/tmp/diff_new_pack.i4aXlN/_old  2020-08-25 09:36:45.964141084 +0200
+++ /var/tmp/diff_new_pack.i4aXlN/_new  2020-08-25 09:36:45.968141086 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package flatpak-builder
 #
-# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2020 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           flatpak-builder
-Version:        1.0.9
+Version:        1.0.11
 Release:        0
 Summary:        Tool to build flatpaks from source
 License:        LGPL-2.1-or-later

++++++ flatpak-builder-1.0.9.tar.xz -> flatpak-builder-1.0.11.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/NEWS 
new/flatpak-builder-1.0.11/NEWS
--- old/flatpak-builder-1.0.9/NEWS      2019-09-13 15:49:37.000000000 +0200
+++ new/flatpak-builder-1.0.11/NEWS     2020-07-03 16:23:43.000000000 +0200
@@ -1,3 +1,16 @@
+Changes in 1.0.11
+=================
+
+ * Use brz instead of bzr fom bzr repos (if available)
+ * Fix `run-tests` with --sandbox and empty test-args
+
+Changes in 1.0.10
+=================
+
+ * Support for 7zip archives
+ * Allow overriding archive type
+ * Support --token-type option
+
 Changes in 1.0.9
 ================
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/configure 
new/flatpak-builder-1.0.11/configure
--- old/flatpak-builder-1.0.9/configure 2019-09-13 15:50:42.000000000 +0200
+++ new/flatpak-builder-1.0.11/configure        2020-07-03 16:24:04.000000000 
+0200
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for flatpak-builder 1.0.9.
+# Generated by GNU Autoconf 2.69 for flatpak-builder 1.0.11.
 #
 # Report bugs to <https://github.com/flatpak/flatpak-builder/issues>.
 #
@@ -590,8 +590,8 @@
 # Identity of this package.
 PACKAGE_NAME='flatpak-builder'
 PACKAGE_TARNAME='flatpak-builder'
-PACKAGE_VERSION='1.0.9'
-PACKAGE_STRING='flatpak-builder 1.0.9'
+PACKAGE_VERSION='1.0.11'
+PACKAGE_STRING='flatpak-builder 1.0.11'
 PACKAGE_BUGREPORT='https://github.com/flatpak/flatpak-builder/issues'
 PACKAGE_URL='http://flatpak.org/'
 
@@ -1394,7 +1394,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures flatpak-builder 1.0.9 to adapt to many kinds of 
systems.
+\`configure' configures flatpak-builder 1.0.11 to adapt to many kinds of 
systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1464,7 +1464,7 @@
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of flatpak-builder 1.0.9:";;
+     short | recursive ) echo "Configuration of flatpak-builder 1.0.11:";;
    esac
   cat <<\_ACEOF
 
@@ -1615,7 +1615,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-flatpak-builder configure 1.0.9
+flatpak-builder configure 1.0.11
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2030,7 +2030,7 @@
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by flatpak-builder $as_me 1.0.9, which was
+It was created by flatpak-builder $as_me 1.0.11, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -13249,7 +13249,7 @@
 
 # Define the identity of the package.
  PACKAGE='flatpak-builder'
- VERSION='1.0.9'
+ VERSION='1.0.11'
 
 
 # Some tools Automake needs.
@@ -16935,7 +16935,7 @@
   fi
 
 
-FLATPAK_BUILDER_VERSION=1.0.9
+FLATPAK_BUILDER_VERSION=1.0.11
 
 
 ac_config_files="$ac_config_files Makefile doc/Makefile 
doc/flatpak-builder-docs.xml"
@@ -17494,7 +17494,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by flatpak-builder $as_me 1.0.9, which was
+This file was extended by flatpak-builder $as_me 1.0.11, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -17561,7 +17561,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; 
s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-flatpak-builder config.status 1.0.9
+flatpak-builder config.status 1.0.11
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/configure.ac 
new/flatpak-builder-1.0.11/configure.ac
--- old/flatpak-builder-1.0.9/configure.ac      2019-09-13 15:46:44.000000000 
+0200
+++ new/flatpak-builder-1.0.11/configure.ac     2020-07-03 16:21:58.000000000 
+0200
@@ -15,7 +15,7 @@
 
 m4_define([flatpak_builder_major_version], [1])
 m4_define([flatpak_builder_minor_version], [0])
-m4_define([flatpak_builder_micro_version], [9])
+m4_define([flatpak_builder_micro_version], [11])
 m4_define([flatpak_builder_version],
           
[flatpak_builder_major_version.flatpak_builder_minor_version.flatpak_builder_micro_version])
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/doc/flatpak-builder.xml 
new/flatpak-builder-1.0.11/doc/flatpak-builder.xml
--- old/flatpak-builder-1.0.9/doc/flatpak-builder.xml   2019-09-13 
15:08:05.000000000 +0200
+++ new/flatpak-builder-1.0.11/doc/flatpak-builder.xml  2020-03-19 
16:30:19.000000000 +0100
@@ -388,7 +388,10 @@
                 <term><option>--repo=DIR</option></term>
 
                 <listitem><para>
-                    When build is done, run export the result to this 
repository.
+                    After the build finishes, run <command>flatpak 
build-export</command> to
+                    export the result to the repository <arg 
choice="plain">DIR</arg>. If
+                    <arg choice="plain">DIR</arg> exists, it must be an OSTree 
repository;
+                    otherwise a new one will be created.
                 </para></listitem>
             </varlistentry>
 
@@ -425,6 +428,19 @@
                 </para></listitem>
             </varlistentry>
 
+            <varlistentry>
+                <term><option>--token-type=VAL</option></term>
+
+                <listitem><para>
+                    Set type of token needed to install this commit.
+                    Setting this to a value greater than 0 implies that
+                    authentication will be needed to install the
+                    flatpak. A <option>token-type</option> property set
+                    in the manifest takes precedence over this option.
+                    Used when exporting the build results.
+                </para></listitem>
+            </varlistentry>
+
             <varlistentry>
                 <term><option>--gpg-sign=KEYID</option></term>
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/doc/flatpak-manifest.xml 
new/flatpak-builder-1.0.11/doc/flatpak-manifest.xml
--- old/flatpak-builder-1.0.9/doc/flatpak-manifest.xml  2019-09-13 
15:08:05.000000000 +0200
+++ new/flatpak-builder-1.0.11/doc/flatpak-manifest.xml 2020-06-17 
15:47:06.000000000 +0200
@@ -73,7 +73,7 @@
                     <term><option>default-branch</option> (string)</term>
                     <listitem><para>The default branch to use when
                     exporting the application. Defaults to master. </para>
-                    <para>This key can be overriden by the
+                    <para>This key can be overridden by the
                     --default-branch commandline
                     option.</para></listitem>
                 </varlistentry>
@@ -102,6 +102,13 @@
                     then an error will occur.</para></listitem>
                 </varlistentry>
                 <varlistentry>
+                    <term><option>token-type</option> (integer)</term>
+                    <listitem><para>The type of token needed to install
+                    this commit. Setting this to a value greater than 0
+                    implies that authentication will be needed to
+                    install the flatpak.</para></listitem>
+                </varlistentry>
+                <varlistentry>
                     <term><option>runtime</option> (string)</term>
                     <listitem><para>The name of the runtime that the 
application uses.</para></listitem>
                 </varlistentry>
@@ -441,7 +448,7 @@
                 </varlistentry>
             </variablelist>
             <para>
-              Additionally the standard flatpak extension properies
+              Additionally the standard flatpak extension properties
               are supported, and put directly into the metadata file:
               autodelete, no-autodownload, subdirectories,
               add-ld-path, download-if, enable-if, merge-dirs,
@@ -645,6 +652,13 @@
                         <listitem><para>Whether to initialise the repository 
as a git repository.</para></listitem>
                     </varlistentry>
                     <varlistentry>
+                        <term><option>archive-type</option> (string)</term>
+                        <listitem><para>
+                            The type of archive if it cannot be guessed from 
the path. Possible values are "rpm", "tar",
+                            "tar-gzip", "tar-compress", "tar-bzip2", 
"tar-lzip", "tar-lzma", "tar-lzop", "tar-xz", "zip" and "7z".
+                        </para></listitem>
+                    </varlistentry>
+                    <varlistentry>
                         <term><option>md5</option> (string)</term>
                         <listitem><para>The md5 checksum of the file, verified 
after download</para>
                         <para>Note that md5 is no longer considered a safe 
checksum, we recommend you use at least sha256.</para>
@@ -902,7 +916,7 @@
                     </varlistentry>
                     <varlistentry>
                         <term><option>size</option> (number)</term>
-                        <listitem><para>The size of the extra 
data.</para></listitem>
+                        <listitem><para>The size of the extra data in 
bytes.</para></listitem>
                     </varlistentry>
                     <varlistentry>
                         <term><option>installed-size</option> (string)</term>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-cache.c 
new/flatpak-builder-1.0.11/src/builder-cache.c
--- old/flatpak-builder-1.0.9/src/builder-cache.c       2019-01-25 
15:13:40.000000000 +0100
+++ new/flatpak-builder-1.0.11/src/builder-cache.c      2020-07-03 
16:21:39.000000000 +0200
@@ -418,7 +418,7 @@
       g_variant_get (variant, "(a{sv}aya(say)&s&stayay)", NULL, NULL, NULL,
                      &subject, NULL, NULL, NULL, NULL);
 
-      if (strcmp (subject, self->current_checksum) == 0)
+      if (g_strcmp0 (subject, self->current_checksum) == 0)
         {
           g_free (self->last_parent);
           self->last_parent = g_steal_pointer (&commit);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-main.c 
new/flatpak-builder-1.0.11/src/builder-main.c
--- old/flatpak-builder-1.0.9/src/builder-main.c        2019-09-13 
15:08:05.000000000 +0200
+++ new/flatpak-builder-1.0.11/src/builder-main.c       2020-03-19 
16:30:19.000000000 +0100
@@ -71,6 +71,7 @@
 static char *opt_subject;
 static char *opt_body;
 static char *opt_collection_id = NULL;
+static int opt_token_type = -1;
 static char *opt_gpg_homedir;
 static char **opt_key_ids;
 static char **opt_sources_dirs;
@@ -118,6 +119,7 @@
   { "subject", 's', 0, G_OPTION_ARG_STRING, &opt_subject, "One line subject 
(passed to build-export)", "SUBJECT" },
   { "body", 'b', 0, G_OPTION_ARG_STRING, &opt_body, "Full description (passed 
to build-export)", "BODY" },
   { "collection-id", 0, 0, G_OPTION_ARG_STRING, &opt_collection_id, 
"Collection ID (passed to build-export)", "COLLECTION-ID" },
+  { "token-type", 0, 0, G_OPTION_ARG_INT, &opt_token_type, "Set type of token 
needed to install this commit (passed to build-export)", "VAL" },
   { "gpg-sign", 0, 0, G_OPTION_ARG_STRING_ARRAY, &opt_key_ids, "GPG Key ID to 
sign the commit with", "KEY-ID"},
   { "gpg-homedir", 0, 0, G_OPTION_ARG_STRING, &opt_gpg_homedir, "GPG Homedir 
to use when looking for keyrings", "HOMEDIR"},
   { "force-clean", 0, 0, G_OPTION_ARG_NONE, &opt_force_clean, "Erase previous 
contents of DIRECTORY", NULL },
@@ -199,6 +201,7 @@
            char          **exclude_dirs,
            const gchar    *branch,
            const gchar    *collection_id,
+           gint32          token_type,
            ...)
 {
   va_list ap;
@@ -231,8 +234,11 @@
   if (collection_id)
     g_ptr_array_add (args, g_strdup_printf ("--collection-id=%s", 
collection_id));
 
+  if (token_type >= 0)
+    g_ptr_array_add (args, g_strdup_printf ("--token-type=%d", token_type));
+
   /* Additional flags. */
-  va_start (ap, collection_id);
+  va_start (ap, token_type);
   while ((arg = va_arg (ap, const gchar *)))
     if (arg != skip_arg)
       g_ptr_array_add (args, g_strdup ((gchar *) arg));
@@ -501,6 +507,16 @@
       return 1;
     }
 
+  if (opt_token_type < -1
+#if G_MAXINT > 0x7fffffff
+      || opt_token_type > G_MAXINT32
+#endif
+      )
+    {
+      g_printerr ("--token-type value must be a 32 bit integer >= 0\n");
+      return 1;
+    }
+
   if (app_dir_path)
     app_dir = g_file_new_for_path (app_dir_path);
   cwd = g_get_current_dir ();
@@ -669,6 +685,9 @@
   if (opt_collection_id)
     builder_manifest_set_default_collection_id (manifest, opt_collection_id);
 
+  if (opt_token_type >= 0)
+    builder_manifest_set_default_token_type (manifest, (gint32)opt_token_type);
+
   if (is_run && argc == 3)
     return usage (context, "Program to run must be specified");
 
@@ -993,6 +1012,7 @@
                       flatpak_file_get_path_cached (export_repo),
                       app_dir_path, exclude_dirs, builder_manifest_get_branch 
(manifest, build_context),
                       builder_manifest_get_collection_id (manifest),
+                      builder_manifest_get_token_type (manifest),
                       "--exclude=/lib/debug/*",
                       "--include=/lib/debug/app",
                       builder_context_get_separate_locales (build_context) ? 
"--exclude=/share/runtime/locale/*/*" : skip_arg,
@@ -1027,6 +1047,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           metadata_arg,
                           files_arg,
                           NULL))
@@ -1047,6 +1068,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           "--metadata=metadata.debuginfo",
                           builder_context_get_build_runtime (build_context) ? 
"--files=usr/lib/debug" : "--files=files/lib/debug",
                           NULL))
@@ -1078,6 +1100,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           metadata_arg, files_arg,
                           NULL))
             {
@@ -1097,6 +1120,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           "--metadata=metadata.sources",
                           "--files=sources",
                           NULL))
@@ -1117,6 +1141,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           "--metadata=metadata.platform",
                           "--files=platform",
                           builder_context_get_separate_locales (build_context) 
? "--exclude=/share/runtime/locale/*/*" : skip_arg,
@@ -1151,6 +1176,7 @@
                           flatpak_file_get_path_cached (export_repo),
                           app_dir_path, NULL, builder_manifest_get_branch 
(manifest, build_context),
                           builder_manifest_get_collection_id (manifest),
+                          builder_manifest_get_token_type (manifest),
                           metadata_arg,
                           files_arg,
                           NULL))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-manifest.c 
new/flatpak-builder-1.0.11/src/builder-manifest.c
--- old/flatpak-builder-1.0.9/src/builder-manifest.c    2019-09-13 
15:46:32.000000000 +0200
+++ new/flatpak-builder-1.0.11/src/builder-manifest.c   2020-07-03 
16:21:39.000000000 +0200
@@ -63,6 +63,7 @@
   char           *branch;
   char           *default_branch;
   char           *collection_id;
+  gint32          token_type;
   char           *extension_tag;
   char           *type;
   char           *runtime;
@@ -167,6 +168,7 @@
   PROP_ADD_EXTENSIONS,
   PROP_ADD_BUILD_EXTENSIONS,
   PROP_EXTENSION_TAG,
+  PROP_TOKEN_TYPE,
   LAST_PROP
 };
 
@@ -470,6 +472,10 @@
       g_value_set_string (value, self->extension_tag);
       break;
 
+    case PROP_TOKEN_TYPE:
+      g_value_set_int (value, (int)self->token_type);
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
     }
@@ -729,6 +735,10 @@
       self->extension_tag = g_value_dup_string (value);
       break;
 
+    case PROP_TOKEN_TYPE:
+      self->token_type = (gint32)g_value_get_int (value);
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
     }
@@ -1070,11 +1080,22 @@
                                                         "",
                                                         NULL,
                                                         G_PARAM_READWRITE));
+
+  g_object_class_install_property (object_class,
+                                   PROP_TOKEN_TYPE,
+                                   g_param_spec_int ("token-type",
+                                                     "",
+                                                     "",
+                                                     -1,
+                                                     G_MAXINT32,
+                                                     -1,
+                                                     G_PARAM_READWRITE));
 }
 
 static void
 builder_manifest_init (BuilderManifest *self)
 {
+  self->token_type = -1;
   self->appstream_compose = TRUE;
   self->separate_locales = TRUE;
 }
@@ -1426,6 +1447,20 @@
     self->collection_id = g_strdup (default_collection_id);
 }
 
+gint32
+builder_manifest_get_token_type (BuilderManifest *self)
+{
+  return self->token_type;
+}
+
+void
+builder_manifest_set_default_token_type (BuilderManifest *self,
+                                         gint32           default_token_type)
+{
+  if (self->token_type == -1)
+    self->token_type = default_token_type;
+}
+
 void
 builder_manifest_add_tags (BuilderManifest *self,
                           const char      **add_tags)
@@ -3747,12 +3782,12 @@
   add_installation_args (args, opt_user, opt_installation);
 
   g_ptr_array_add (args, g_strdup ("install"));
-  g_ptr_array_add (args, g_strdup (remote));
-  
+
   g_ptr_array_add (args, g_strdup ("-y"));
   if (flatpak_version_check (1, 2, 0))
     g_ptr_array_add (args, g_strdup ("--noninteractive"));
 
+  g_ptr_array_add (args, g_strdup (remote));
   g_ptr_array_add (args, g_strdup (ref));
   g_ptr_array_add (args, NULL);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-manifest.h 
new/flatpak-builder-1.0.11/src/builder-manifest.h
--- old/flatpak-builder-1.0.9/src/builder-manifest.h    2019-09-13 
15:08:05.000000000 +0200
+++ new/flatpak-builder-1.0.11/src/builder-manifest.h   2020-03-19 
16:30:19.000000000 +0100
@@ -62,9 +62,12 @@
 const char *    builder_manifest_get_branch (BuilderManifest *self,
                                              BuilderContext  *context);
 const char *    builder_manifest_get_collection_id (BuilderManifest *self);
+gint32          builder_manifest_get_token_type (BuilderManifest *self);
 const char *    builder_manifest_get_extension_tag (BuilderManifest *self);
 void            builder_manifest_set_default_collection_id (BuilderManifest 
*self,
                                                             const char      
*default_collection_id);
+void            builder_manifest_set_default_token_type (BuilderManifest *self,
+                                                         gint32           
default_token_type);
 
 void            builder_manifest_add_tags (BuilderManifest *self,
                                            const char      **add_tags);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-options.c 
new/flatpak-builder-1.0.11/src/builder-options.c
--- old/flatpak-builder-1.0.9/src/builder-options.c     2019-01-15 
16:14:23.000000000 +0100
+++ new/flatpak-builder-1.0.11/src/builder-options.c    2020-07-03 
16:21:39.000000000 +0200
@@ -1203,9 +1203,6 @@
   /* Last argument wins, so reverse the list for per-module to win */
   options = g_list_reverse (options);
 
-  /* Always run tests readonly */
-  g_ptr_array_add (array, g_strdup ("--readonly"));
-
   for (l = options; l != NULL; l = l->next)
     {
       BuilderOptions *o = l->data;
@@ -1223,6 +1220,9 @@
       return NULL;
     }
 
+  /* Always run tests readonly */
+  g_ptr_array_add (array, g_strdup ("--readonly"));
+
   g_ptr_array_add (array, NULL);
 
   return (char **) g_ptr_array_free (g_steal_pointer (&array), FALSE);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-source-archive.c 
new/flatpak-builder-1.0.11/src/builder-source-archive.c
--- old/flatpak-builder-1.0.9/src/builder-source-archive.c      2019-01-11 
16:15:29.000000000 +0100
+++ new/flatpak-builder-1.0.11/src/builder-source-archive.c     2020-03-19 
16:30:19.000000000 +0100
@@ -46,6 +46,7 @@
   guint         strip_components;
   char         *dest_filename;
   gboolean      git_init;
+  char         *archive_type;
 };
 
 typedef struct
@@ -67,6 +68,7 @@
   PROP_DEST_FILENAME,
   PROP_MIRROR_URLS,
   PROP_GIT_INIT,
+  PROP_ARCHIVE_TYPE,
   LAST_PROP
 };
 
@@ -81,7 +83,8 @@
   TAR_LZMA,
   TAR_LZOP,
   TAR_XZ,
-  ZIP
+  ZIP,
+  SEVENZ,
 } BuilderArchiveType;
 
 static gboolean
@@ -135,6 +138,7 @@
   g_free (self->sha512);
   g_free (self->dest_filename);
   g_strfreev (self->mirror_urls);
+  g_free (self->archive_type);
 
   G_OBJECT_CLASS (builder_source_archive_parent_class)->finalize (object);
 }
@@ -189,6 +193,10 @@
       g_value_set_boolean (value, self->git_init);
       break;
 
+    case PROP_ARCHIVE_TYPE:
+      g_value_set_string (value, self->archive_type);
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
     }
@@ -254,6 +262,11 @@
       self->git_init = g_value_get_boolean (value);
       break;
 
+    case PROP_ARCHIVE_TYPE:
+      g_free (self->archive_type);
+      self->archive_type = g_value_dup_string (value);
+      break;
+
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
     }
@@ -452,6 +465,19 @@
 }
 
 static gboolean
+un7z (GFile       *dir,
+      const char  *sevenz_path,
+      GError     **error)
+{
+  gboolean res;
+  const gchar *argv[] = { "7z",  "x", sevenz_path, NULL };
+
+  res = flatpak_spawnv (dir, NULL, 0, error, argv);
+
+  return res;
+}
+
+static gboolean
 unrpm (GFile   *dir,
        const char *rpm_path,
        GError **error)
@@ -629,6 +655,40 @@
   return TRUE;
 }
 
+static BuilderArchiveType
+get_type_from_prop (BuilderSourceArchive *self)
+{
+  struct {
+    const char *id;
+    BuilderArchiveType type;
+  } str_to_types[] = {
+      { "rpm", RPM },
+      { "tar", TAR },
+      { "tar-gzip", TAR_GZIP },
+      { "tar-compress", TAR_COMPRESS },
+      { "tar-bzip2", TAR_BZIP2 },
+      { "tar-lzip", TAR_LZIP },
+      { "tar-lzma", TAR_LZMA },
+      { "tar-xz", TAR_XZ },
+      { "zip", ZIP },
+      { "7z", SEVENZ },
+  };
+  guint i;
+
+  if (self->archive_type == NULL)
+    return UNKNOWN;
+
+  for (i = 0; i < G_N_ELEMENTS(str_to_types); i++)
+    {
+      if (g_strcmp0 (self->archive_type, str_to_types[i].id) == 0)
+        return str_to_types[i].type;
+    }
+
+  g_warning ("Unknown archive-type \"%s\"", self->archive_type);
+
+  return UNKNOWN;
+}
+
 static gboolean
 builder_source_archive_extract (BuilderSource  *source,
                                 GFile          *dest,
@@ -647,7 +707,9 @@
   if (archivefile == NULL)
     return FALSE;
 
-  type = get_type (archivefile);
+  type = get_type_from_prop (self);
+  if (type == UNKNOWN)
+    type = get_type (archivefile);
 
   archive_path = g_file_get_path (archivefile);
 
@@ -675,6 +737,23 @@
             return FALSE;
         }
     }
+  else if (type == SEVENZ)
+    {
+      g_autoptr(GFile) sevenz_dest = NULL;
+
+      sevenz_dest = create_uncompress_directory (self, dest, error);
+      if (sevenz_dest == NULL)
+        return FALSE;
+
+      if (!un7z (sevenz_dest, archive_path, error))
+        return FALSE;
+
+      if (self->strip_components > 0)
+        {
+          if (!strip_components_into (dest, sevenz_dest, 
self->strip_components, error))
+            return FALSE;
+        }
+    }
   else if (type == RPM)
     {
       g_autoptr(GFile) rpm_dest = NULL;
@@ -866,6 +945,13 @@
                                                          "",
                                                          FALSE,
                                                          G_PARAM_READWRITE));
+  g_object_class_install_property (object_class,
+                                   PROP_ARCHIVE_TYPE,
+                                   g_param_spec_string ("archive-type",
+                                                        "",
+                                                        "",
+                                                        NULL,
+                                                        G_PARAM_READWRITE));
 }
 
 static void
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-source-bzr.c 
new/flatpak-builder-1.0.11/src/builder-source-bzr.c
--- old/flatpak-builder-1.0.9/src/builder-source-bzr.c  2018-10-04 
14:48:07.000000000 +0200
+++ new/flatpak-builder-1.0.11/src/builder-source-bzr.c 2020-06-17 
15:47:06.000000000 +0200
@@ -120,11 +120,14 @@
      GError **error,
      ...)
 {
+  g_autofree char *brz = NULL;
   gboolean res;
   va_list ap;
 
+  brz = g_find_program_in_path ("brz");
+
   va_start (ap, error);
-  res = flatpak_spawn (dir, output, 0, error, "bzr", ap);
+  res = flatpak_spawn (dir, output, 0, error, brz ? brz : "bzr", ap);
   va_end (ap);
 
   return res;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/src/builder-utils.c 
new/flatpak-builder-1.0.11/src/builder-utils.c
--- old/flatpak-builder-1.0.9/src/builder-utils.c       2019-09-13 
15:08:05.000000000 +0200
+++ new/flatpak-builder-1.0.11/src/builder-utils.c      2020-03-11 
14:38:39.000000000 +0100
@@ -1914,7 +1914,7 @@
   if (strcmp (expected_checksum, measured_checksum) != 0)
     {
       g_set_error (error, G_IO_ERROR, G_IO_ERROR_FAILED,
-                   "Wrong %s checksum for %s, expected %s, was %s", type_name, 
name,
+                   "Wrong %s checksum for %s, expected \"%s\", was \"%s\"", 
type_name, name,
                    expected_checksum, measured_checksum);
       return FALSE;
     }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/tests/test.json 
new/flatpak-builder-1.0.11/tests/test.json
--- old/flatpak-builder-1.0.9/tests/test.json   2017-08-24 15:19:14.000000000 
+0200
+++ new/flatpak-builder-1.0.11/tests/test.json  2020-03-19 16:30:19.000000000 
+0100
@@ -4,6 +4,7 @@
     "sdk": "org.test.Sdk",
     "command": "hello2.sh",
     "tags": ["test"],
+    "token-type": 0,
     "finish-args": [
         "--share=network"
     ],
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flatpak-builder-1.0.9/tests/test.yaml 
new/flatpak-builder-1.0.11/tests/test.yaml
--- old/flatpak-builder-1.0.9/tests/test.yaml   2018-04-19 15:43:08.000000000 
+0200
+++ new/flatpak-builder-1.0.11/tests/test.yaml  2020-03-19 16:30:19.000000000 
+0100
@@ -3,6 +3,7 @@
 sdk: org.test.Sdk
 command: hello2.sh
 tags: [test]
+token-type: 0
 finish-args:
   - --share=network
 build-options:


Reply via email to