diff options
-rw-r--r-- | chrome/browser/cocoa/keystone_glue.mm | 12 | ||||
-rw-r--r-- | chrome/browser/platform_util_mac.mm | 6 | ||||
-rw-r--r-- | chrome/chrome.gyp | 7 | ||||
-rw-r--r-- | chrome/chrome_dll.gypi | 11 | ||||
-rw-r--r-- | chrome/chrome_exe.gypi | 8 |
5 files changed, 23 insertions, 21 deletions
diff --git a/chrome/browser/cocoa/keystone_glue.mm b/chrome/browser/cocoa/keystone_glue.mm index cff6817..bcd78f4 100644 --- a/chrome/browser/cocoa/keystone_glue.mm +++ b/chrome/browser/cocoa/keystone_glue.mm @@ -247,19 +247,17 @@ const NSString* const kBrandKey = @"KSBrandID"; } - (NSDictionary*)infoDictionary { - // Use mac_util::MainAppBundle() to get the app framework's dictionary. - return [mac_util::MainAppBundle() infoDictionary]; -} - -- (void)loadParameters { - NSDictionary* infoDictionary = [self infoDictionary]; - // Use [NSBundle mainBundle] to get the application's own bundle identifier // and path, not the framework's. For auto-update, the application is // what's significant here: it's used to locate the outermost part of the // application for the existence checker and other operations that need to // see the entire application bundle. + return [[NSBundle mainBundle] infoDictionary]; +} + +- (void)loadParameters { NSBundle* appBundle = [NSBundle mainBundle]; + NSDictionary* infoDictionary = [self infoDictionary]; NSString* productID = [infoDictionary objectForKey:@"KSProductID"]; if (productID == nil) { diff --git a/chrome/browser/platform_util_mac.mm b/chrome/browser/platform_util_mac.mm index 79dca7c..d7a932b 100644 --- a/chrome/browser/platform_util_mac.mm +++ b/chrome/browser/platform_util_mac.mm @@ -73,14 +73,16 @@ void SimpleErrorBox(gfx::NativeWindow parent, string16 GetVersionStringModifier() { #if defined(GOOGLE_CHROME_BUILD) - NSBundle* bundle = mac_util::MainAppBundle(); + // Use the main application bundle and not the framework bundle. Keystone + // keys don't live in the framework. + NSBundle* bundle = [NSBundle mainBundle]; NSString* channel = [bundle objectForInfoDictionaryKey:@"KSChannelID"]; // Only ever return "", "unknown", "beta" or "dev" in a branded build. if (![bundle objectForInfoDictionaryKey:@"KSProductID"]) { // This build is not Keystone-enabled, it can't have a channel. channel = @"unknown"; - } else if (!channel || [channel isEqual:@"stable"]) { + } else if (!channel) { // For the stable channel, KSChannelID is not set. channel = @""; } else if ([channel isEqual:@"beta"] || [channel isEqual:@"dev"]) { diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp index 013e8ea..119aec9 100644 --- a/chrome/chrome.gyp +++ b/chrome/chrome.gyp @@ -1150,10 +1150,9 @@ { # Modify the Info.plist as needed. The script explains why this # is needed. This is also done in the chrome and chrome_dll - # targets. In this case, -b0 and -k0 are used because Breakpad - # and Keystone keys are never placed into the helper, only into - # the framework. -s0 is used because Subversion keys are only - # placed into the main app. + # targets. In this case, -b0, -k0, and -s0 are used because + # Breakpad, Keystone, and Subersion keys are never placed into + # the helper. 'postbuild_name': 'Tweak Info.plist', 'action': ['<(tweak_info_plist_path)', '-b0', diff --git a/chrome/chrome_dll.gypi b/chrome/chrome_dll.gypi index 70a415d..faede25 100644 --- a/chrome/chrome_dll.gypi +++ b/chrome/chrome_dll.gypi @@ -391,14 +391,15 @@ { # Modify the Info.plist as needed. The script explains why # this is needed. This is also done in the chrome target. - # The framework needs the Breakpad and Keystone keys if - # those features are enabled. It doesn't currently use the - # Subversion keys for anything, but this seems like a really - # good place to store them. + # The framework needs the Breakpad keys if this feature is + # enabled. It does not need the Keystone keys; these always + # come from the outer application bundle. The framework + # doesn't currently use the Subversion keys for anything, + # but this seems like a really good place to store them. 'postbuild_name': 'Tweak Info.plist', 'action': ['<(tweak_info_plist_path)', '-b<(mac_breakpad)', - '-k<(mac_keystone)', + '-k0', '-s1', '<(branding)', '<(mac_bundle_id)'], diff --git a/chrome/chrome_exe.gypi b/chrome/chrome_exe.gypi index 953b7fe..bf4c6c5 100644 --- a/chrome/chrome_exe.gypi +++ b/chrome/chrome_exe.gypi @@ -357,9 +357,11 @@ # is needed. This is also done in the helper_app and chrome_dll # targets. Use -b0 to not include any Breakpad information; that # all goes into the framework's Info.plist. Keystone information - # is included if Keystone is enabled because the ticket will - # reference this Info.plist to determine the tag of the installed - # product. Use -s1 to include Subversion information. + # is included if Keystone is enabled. The application reads + # Keystone keys from this plist and not the framework's, and + # the ticket will reference this Info.plist to determine the tag + # of the installed product. Use -s1 to include Subversion + # information. 'postbuild_name': 'Tweak Info.plist', 'action': ['<(tweak_info_plist_path)', '-b0', |