aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKatja Marttila <katja.marttila@qt.io>2019-05-17 13:46:06 +0300
committerKatja Marttila <katja.marttila@qt.io>2019-05-29 06:24:05 +0000
commitfd1f2eceacb4c2a083913eda7e561574de85975a (patch)
tree0adfc47cf77e10c63efd8cce5be03c09377ef3a1
parentb14109af3a3c5d818c87fe64a92f1ca1fd7f2b83 (diff)
Delete IFW example executables we have generated for Squish
If not deleted, those will end up in released IFW version Change-Id: I730c7c7742ce420a1e2278f507e4827a637a9945 Reviewed-by: Antti Kokko <antti.kokko@qt.io>
-rw-r--r--packaging-tools/bld_ifw_tools.py13
1 files changed, 11 insertions, 2 deletions
diff --git a/packaging-tools/bld_ifw_tools.py b/packaging-tools/bld_ifw_tools.py
index 92be5369c..8b985401d 100644
--- a/packaging-tools/bld_ifw_tools.py
+++ b/packaging-tools/bld_ifw_tools.py
@@ -513,6 +513,7 @@ def build_installer_framework_examples(options):
sys.exit(-1)
ifw_examples = os.path.join(options.installer_framework_source_dir, 'examples')
+ ifw_example_binaries = []
for root, dirs, files in os.walk(ifw_examples):
if 'doc' in dirs:
@@ -523,8 +524,11 @@ def build_installer_framework_examples(options):
print("********** building example " + directory)
config_file = os.path.join(root, directory, 'config', 'config.xml')
package_dir = os.path.join(root, directory, 'packages')
- target_dir = os.path.join(root, directory, 'installer')
- bldinstallercommon.do_execute_sub_process(args=(file_binarycreator, '--offline-only', '-c', config_file, '-p', package_dir, target_dir), execution_path=package_dir)
+ target_filename = os.path.join(root, directory, 'installer')
+ bldinstallercommon.do_execute_sub_process(args=(file_binarycreator, '--offline-only', '-c', config_file, '-p', package_dir, target_filename), execution_path=package_dir)
+ if bldinstallercommon.is_win_platform:
+ target_filename += '.exe'
+ ifw_example_binaries.append(target_filename)
#Breaking here as we don't want to go through sub directories
break
file_squishDir = options.squish_dir
@@ -543,6 +547,11 @@ def build_installer_framework_examples(options):
bldinstallercommon.do_execute_sub_process(args=shlex.split(os.path.join(file_squishDir, "bin", "squishrunner") + ' --testsuite ' +os.path.join(os.getcwd(), "squish_suites", "suite_IFW_examples")), execution_path=os.path.join(file_squishDir, "bin"))
squishserver_handle.kill() #kills squish server
+ # Delete the example executables we have created for Squish
+ for example in ifw_example_binaries:
+ print("Removing " + example)
+ os.remove(example)
+
###############################
# function
###############################