mini_installer_constants.cc revision 116680a4aac90f2aa7413d9095a592090648e557
1// Copyright 2014 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "chrome/installer/mini_installer/mini_installer_constants.h"
6
7namespace mini_installer {
8
9// Various filenames and prefixes.
10// The target name of the installer extracted from resources.
11const wchar_t kSetupExe[] = L"setup.exe";
12// The prefix of the chrome archive resource.
13const wchar_t kChromeArchivePrefix[] = L"chrome";
14// The prefix of the installer resource.
15const wchar_t kSetupPrefix[] = L"setup";
16
17// Command line switch names for setup.exe.
18const wchar_t kCmdInstallArchive[] = L"install-archive";
19const wchar_t kCmdUpdateSetupExe[] = L"update-setup-exe";
20const wchar_t kCmdNewSetupExe[] = L"new-setup-exe";
21
22// Temp directory prefix that this process creates.
23const wchar_t kTempPrefix[] = L"CR_";
24// ap value suffix to force subsequent updates to use the full rather than
25// differential updater.
26const wchar_t kFullInstallerSuffix[] = L"-full";
27// ap value tag for a multi-install product.
28const wchar_t kMultiInstallTag[] = L"-multi";
29
30// The resource types that would be unpacked from the mini installer.
31// Uncompressed binary.
32const wchar_t kBinResourceType[] = L"BN";
33// LZ compressed binary.
34const wchar_t kLZCResourceType[] = L"BL";
35// 7zip archive.
36const wchar_t kLZMAResourceType[] = L"B7";
37
38// Registry value names.
39// The name of an app's Client State registry value that holds its tag/channel.
40const wchar_t kApRegistryValue[] = L"ap";
41// The name of the value in kCleanupRegistryKey that tells the installer not to
42// delete extracted files.
43const wchar_t kCleanupRegistryValue[] = L"ChromeInstallerCleanup";
44// The name of an app's Client State registry value that holds the path to its
45// uninstaller.
46const wchar_t kUninstallRegistryValue[] = L"UninstallString";
47
48// Registry key paths.
49#if defined(GOOGLE_CHROME_BUILD)
50// The path to the key containing each app's Client State registry key.
51const wchar_t kClientStateKeyBase[] =
52    L"Software\\Google\\Update\\ClientState\\";
53// The path to the key in which kCleanupRegistryValue is found.
54const wchar_t kCleanupRegistryKey[] =
55    L"Software\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\Google Chrome";
56#else
57// The path to the key containing each app's Client State registry key.
58const wchar_t kClientStateKeyBase[] = L"Software\\Chromium";
59// The path to the key in which kCleanupRegistryValue is found.
60const wchar_t kCleanupRegistryKey[] = L"Software\\Chromium";
61#endif
62
63// One gigabyte is the biggest resource size that it can handle.
64const size_t kMaxResourceSize = 1024*1024*1024;
65
66}  // namespace mini_installer
67