summaryrefslogtreecommitdiffstats
path: root/bin/createpackage.pl
diff options
context:
space:
mode:
authorMiikka Heikkinen <miikka.heikkinen@digia.com>2010-12-03 09:06:29 (GMT)
committerMiikka Heikkinen <miikka.heikkinen@digia.com>2010-12-03 09:43:29 (GMT)
commita3967216f29b3ec8303c7aa71959dd30ae18ecc3 (patch)
treeaf6a364b578dfd2f12327840012f904892c11756 /bin/createpackage.pl
parent46c4baa0915a9b9599b249833d1b2dd94eab3ca0 (diff)
downloadQt-a3967216f29b3ec8303c7aa71959dd30ae18ecc3.zip
Qt-a3967216f29b3ec8303c7aa71959dd30ae18ecc3.tar.gz
Qt-a3967216f29b3ec8303c7aa71959dd30ae18ecc3.tar.bz2
Unify epocroot usage in createpackage and patch_capabilities scripts
Some tools calls required epoc32/tools to be in path and some didn't. Now all tools calls will use tools from under %EPOCROOT%epoc32/tools if EPOCROOT env variable is defined. Reviewed-by: Janne Koskinen
Diffstat (limited to 'bin/createpackage.pl')
-rwxr-xr-xbin/createpackage.pl15
1 files changed, 7 insertions, 8 deletions
diff --git a/bin/createpackage.pl b/bin/createpackage.pl
index 6b83585..87ed29e 100755
--- a/bin/createpackage.pl
+++ b/bin/createpackage.pl
@@ -144,11 +144,13 @@ unless (GetOptions('i|install' => \$install,
}
my $epocroot = $ENV{EPOCROOT};
+my $epocToolsDir = "";
if ($epocroot ne "") {
$epocroot =~ s,\\,/,g;
if ($epocroot =~ m,[^/]$,) {
$epocroot = $epocroot."/";
}
+ $epocToolsDir = "${epocroot}epoc32/tools/";
}
my $certfilepath = abs_path(dirname($certfile));
@@ -341,7 +343,7 @@ if($stub) {
mkpath($systeminstall);
my $stub_sis_name = $systeminstall."/".$stub_sis_name;
# Create stub SIS.
- system ("${epocroot}epoc32/tools/makesis -s $pkgoutput $stub_sis_name");
+ system ("${epocToolsDir}makesis -s $pkgoutput $stub_sis_name");
} else {
if ($certtext eq "Self Signed"
&& !@certificates
@@ -358,11 +360,8 @@ if($stub) {
# Create SIS.
# The 'and' is because system uses 0 to indicate success.
- if($epocroot) {
- system ("${epocroot}epoc32/tools/makesis $pkgoutput $unsigned_sis_name") and die ("ERROR: makesis failed");
- } else {
- system ("makesis $pkgoutput $unsigned_sis_name") and die ("ERROR: makesis failed");
- }
+ system ("${epocToolsDir}makesis $pkgoutput $unsigned_sis_name") and die ("ERROR: makesis failed");
+
print("\n");
my $targetInsert = "";
@@ -389,7 +388,7 @@ if($stub) {
my $relcert = File::Spec->abs2rel($certificate);
my $relkey = File::Spec->abs2rel($key);
# The 'and' is because system uses 0 to indicate success.
- system ("signsis $unsigned_sis_name $signed_sis_name $relcert $relkey $passphrase") and die ("ERROR: signsis failed");
+ system ("${epocToolsDir}signsis $unsigned_sis_name $signed_sis_name $relcert $relkey $passphrase") and die ("ERROR: signsis failed");
# Check if creating signed SIS Succeeded
stat($signed_sis_name);
@@ -402,7 +401,7 @@ if($stub) {
my $relcert = File::Spec->abs2rel(File::Spec->rel2abs( $row->[0], $certfilepath));
my $relkey = File::Spec->abs2rel(File::Spec->rel2abs( $row->[1], $certfilepath));
- system ("signsis $signed_sis_name $signed_sis_name $relcert $relkey $row->[2]");
+ system ("${epocToolsDir}signsis $signed_sis_name $signed_sis_name $relcert $relkey $row->[2]");
print ("\tAdditionally signed the SIS with certificate: $row->[0]!\n");
}