[pitivi] flatpak: Use the --force-clean option instead of cleaning ourself



commit 8b5dca9e0ac8a39055ab71c33c13eb1060fcca2c
Author: Thibault Saunier <tsaunier gnome org>
Date:   Sun Apr 30 14:02:11 2017 -0300

    flatpak: Use the --force-clean option instead of cleaning ourself
    
    It seems that the cace wasn't taken into account with latest flatpak without that

 build/flatpak/pitivi-flatpak |   10 +++-------
 1 files changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/build/flatpak/pitivi-flatpak b/build/flatpak/pitivi-flatpak
index 3918c4d..8ef869d 100755
--- a/build/flatpak/pitivi-flatpak
+++ b/build/flatpak/pitivi-flatpak
@@ -505,11 +505,7 @@ class PitiviFlatpak:  # pylint: disable=too-many-instance-attributes
     def setup_dev_env(self):
         self.install_all()
 
-        if os.path.exists(self.prefix) and self.update:
-            Console.message("Removing prefix %s", self.prefix)
-            shutil.rmtree(self.prefix)
-
-        if not os.path.exists(self.prefix):
+        if not os.path.exists(self.prefix) or self.update:
             Console.message("Building Pitivi %s and dependencies in %s",
                             self.branch, self.prefix)
 
@@ -519,7 +515,7 @@ class PitiviFlatpak:  # pylint: disable=too-many-instance-attributes
                              self.local_repos_path, self.gst_version,
                              self.branch)
 
-            builder_args = ["flatpak-builder",
+            builder_args = ["flatpak-builder", "--force-clean",
                             "--ccache", self.prefix, self.json]
             if not self.bundle:
                 builder_args.append("--build-only")
@@ -530,7 +526,7 @@ class PitiviFlatpak:  # pylint: disable=too-many-instance-attributes
                 Console.message("\n%sYou need to install flatpak-builder%s\n",
                                 Colors.FAIL, Colors.ENDC)
                 self.exit(1)
-            subprocess.check_call(builder_args)
+            subprocess.check_call(builder_args, cwd=self.scriptdir)
 
             configure_args = ["./configure", "--prefix=/app", "--libdir=lib"]
             self.run_in_sandbox(*configure_args, exit_on_failure=True,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]