From ad8e7b27427825bee730c55735cd2554407205e4 Mon Sep 17 00:00:00 2001 From: Miikka Heikkinen Date: Fri, 12 Nov 2010 11:28:09 +0200 Subject: Add Location as self signable capability in patch_capabilities.pl Location was not originally included in self-signable set, since in S60 3.1 devices it is not so. However, it is a lesser of two evils to make applications with Location capability not install on 3.1 devices than make them not work correctly on any devices, so Location is now included in the self-signable set in patch_capabilities.pl. Task-number: QTBUG-13891 Reviewed-by: Janne Koskinen --- bin/patch_capabilities.pl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bin/patch_capabilities.pl b/bin/patch_capabilities.pl index 5230480..994d493 100755 --- a/bin/patch_capabilities.pl +++ b/bin/patch_capabilities.pl @@ -78,7 +78,7 @@ sub trim($) { my $nullDevice = "/dev/null"; $nullDevice = "NUL" if ($^O =~ /MSWin/); -my @capabilitiesToAllow = ("LocalServices", "NetworkServices", "ReadUserData", "UserEnvironment", "WriteUserData"); +my @capabilitiesToAllow = ("LocalServices", "NetworkServices", "ReadUserData", "UserEnvironment", "WriteUserData", "Location"); my @capabilitiesSpecified = (); # If arguments were given to the script, @@ -301,6 +301,9 @@ if (@ARGV) $_ = trim($_); if ($capabilitiesToAllow =~ /$_/) { push(@capabilitiesToSet, $_); + if (Location =~ /$_/i) { + print ("Patching: Warning - \"Location\" capability detected for binary: \"$binaryBaseName\". This capability is not self-signable for S60 3rd edition feature pack 1 devices, so installing this package on those devices will most likely not work.\n"); + } } else { push(@capabilitiesToDrop, $_); } @@ -319,6 +322,7 @@ if (@ARGV) # While libraries often have capabilities they do not themselves need just to enable them to be loaded by wider variety of processes, # executables are more likely to need every capability they have been assigned or they won't function correctly. print ("Patching: Executable with capabilities incompatible with self-signing detected: \"$binaryBaseName\". (Incompatible capabilities: \"$capsToDropStr\".) Reducing capabilities is only supported for libraries.\n"); + print ("Patching: Please use a proper developer certificate for signing this package.\n"); exit(1); } else { print ("Patching: The following capabilities used in \"$binaryBaseName\" are not compatible with a self-signed package and will be removed: \"$capsToDropStr\".\n"); -- cgit v0.12