| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // The file contains the implementation of the mini_installer re-versioner. | 5 // The file contains the implementation of the mini_installer re-versioner. |
| 6 // The main function (GenerateNextVersion) does the following in a temp dir: | 6 // The main function (GenerateNextVersion) does the following in a temp dir: |
| 7 // - Extracts and unpacks setup.exe and the Chrome-bin folder from | 7 // - Extracts and unpacks setup.exe and the Chrome-bin folder from |
| 8 // mini_installer.exe. | 8 // mini_installer.exe. |
| 9 // - Inspects setup.exe to determine the current version. | 9 // - Inspects setup.exe to determine the current version. |
| 10 // - Runs through all .dll and .exe files: | 10 // - Runs through all .dll and .exe files: |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 #include "chrome/installer/test/resource_loader.h" | 50 #include "chrome/installer/test/resource_loader.h" |
| 51 #include "chrome/installer/test/resource_updater.h" | 51 #include "chrome/installer/test/resource_updater.h" |
| 52 #include "chrome/installer/util/lzma_util.h" | 52 #include "chrome/installer/util/lzma_util.h" |
| 53 | 53 |
| 54 namespace { | 54 namespace { |
| 55 | 55 |
| 56 const wchar_t k7zaExe[] = L"7za.exe"; | 56 const wchar_t k7zaExe[] = L"7za.exe"; |
| 57 const wchar_t k7zaPathRelative[] = L"..\\..\\third_party\\lzma_sdk\\Executable"; | 57 const wchar_t k7zaPathRelative[] = L"..\\..\\third_party\\lzma_sdk\\Executable"; |
| 58 const wchar_t kB7[] = L"B7"; | 58 const wchar_t kB7[] = L"B7"; |
| 59 const wchar_t kBl[] = L"BL"; | 59 const wchar_t kBl[] = L"BL"; |
| 60 const wchar_t kChrome7z[] = L"chrome.7z"; | |
| 61 const wchar_t kChromeBin[] = L"Chrome-bin"; | 60 const wchar_t kChromeBin[] = L"Chrome-bin"; |
| 62 const wchar_t kChromePacked7z[] = L"chrome.packed.7z"; | 61 const wchar_t kChromePacked7z[] = L"chrome.packed.7z"; |
| 63 const wchar_t kExe[] = L"exe"; | 62 const wchar_t kExe[] = L"exe"; |
| 64 const wchar_t kExpandExe[] = L"expand.exe"; | 63 const wchar_t kExpandExe[] = L"expand.exe"; |
| 65 const wchar_t kExtDll[] = L".dll"; | 64 const wchar_t kExtDll[] = L".dll"; |
| 66 const wchar_t kExtExe[] = L".exe"; | 65 const wchar_t kExtExe[] = L".exe"; |
| 67 const wchar_t kMakeCab[] = L"makecab.exe"; | 66 const wchar_t kMakeCab[] = L"makecab.exe"; |
| 68 const wchar_t kSetupEx_[] = L"setup.ex_"; | 67 const wchar_t kSetupEx_[] = L"setup.ex_"; |
| 69 const wchar_t kSetupExe[] = L"setup.exe"; | 68 const wchar_t kSetupExe[] = L"setup.exe"; |
| 70 const char kSwitch7zaPath[] = "7za_path"; | 69 const char kSwitch7zaPath[] = "7za_path"; |
| (...skipping 622 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 693 return false; | 692 return false; |
| 694 } | 693 } |
| 695 ctx.current_version_str = ctx.current_version.ToString(); | 694 ctx.current_version_str = ctx.current_version.ToString(); |
| 696 ctx.new_version = ChromeVersion::FromString(version.GetString()); | 695 ctx.new_version = ChromeVersion::FromString(version.GetString()); |
| 697 ctx.new_version_str = ctx.new_version.ToString(); | 696 ctx.new_version_str = ctx.new_version.ToString(); |
| 698 | 697 |
| 699 return UpdateVersionIfMatch(target_file, &ctx); | 698 return UpdateVersionIfMatch(target_file, &ctx); |
| 700 } | 699 } |
| 701 | 700 |
| 702 } // namespace upgrade_test | 701 } // namespace upgrade_test |
| OLD | NEW |