[jhbuild] Only run triggers if we actually install
- From: Giovanni Campagna <gcampagna src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [jhbuild] Only run triggers if we actually install
- Date: Sat, 17 Mar 2012 19:12:51 +0000 (UTC)
commit 64ce2974c7c2902e53ffb216d7a84f0ae0efcb22
Author: Giovanni Campagna <gcampagna src gnome org>
Date: Fri Mar 16 23:25:47 2012 +0100
Only run triggers if we actually install
If we skip phase install for any reason, for example because the
module is not updated, we don't need to run triggers again.
https://bugzilla.gnome.org/show_bug.cgi?id=672266
jhbuild/frontends/buildscript.py | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/jhbuild/frontends/buildscript.py b/jhbuild/frontends/buildscript.py
index d4e9845..c94afd3 100644
--- a/jhbuild/frontends/buildscript.py
+++ b/jhbuild/frontends/buildscript.py
@@ -169,7 +169,7 @@ class BuildScript:
except SkipToEnd:
break
finally:
- self.end_phase(module.name, phase, error)
+ self._end_phase_internal(module.name, phase, error)
if error:
try:
@@ -212,9 +212,6 @@ class BuildScript:
force_phase = False
num_phase += 1
- if not failed:
- self.run_triggers(module.name)
-
self.end_module(module.name, failed)
self.end_build(failures)
@@ -313,6 +310,10 @@ class BuildScript:
The argument is a string containing the error text if something
went wrong.'''
pass
+ def _end_phase_internal(self, module, phase, error):
+ if error is None and phase == 'install':
+ self.run_triggers(module)
+ self.end_phase(module, phase, error)
def message(self, msg, module_num=-1):
'''Display a message to the user'''
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]