OLD | NEW |
---|---|
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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 import("//build/config/features.gni") | 5 import("//build/config/features.gni") |
6 import("//build/config/ui.gni") | 6 import("//build/config/ui.gni") |
7 import("//build/module_args/v8.gni") | 7 import("//build/module_args/v8.gni") |
8 import("//chrome/version.gni") | |
8 import("//third_party/icu/config.gni") | 9 import("//third_party/icu/config.gni") |
9 | 10 |
10 config("mini_installer_compiler_flags") { | 11 config("mini_installer_compiler_flags") { |
11 cflags = [ | 12 cflags = [ |
12 "/bigobj", | 13 "/bigobj", |
13 "/Gy", # Enable function-level linking. | 14 "/Gy", # Enable function-level linking. |
14 "/GS-", # Disable buffer security checking. | 15 "/GS-", # Disable buffer security checking. |
16 "/FS", # Preserve previous PDB behavior. | |
scottmg
2015/09/03 21:22:25
This is duplicated from build/config/compiler so t
brettw
2015/09/04 16:53:15
I have no idea. I just copy the code from the GYP.
| |
15 ] | 17 ] |
16 | 18 |
17 cflags_c = [ "/TC" ] | 19 cflags_c = [ "/TC" ] |
18 cflags_cc = [ "/TP" ] | 20 cflags_cc = [ "/TP" ] |
19 } | 21 } |
20 | 22 |
21 source_set("lib") { | 23 source_set("lib") { |
22 sources = [ | 24 sources = [ |
23 "appid.h", | 25 "appid.h", |
24 "chrome.release", | 26 "chrome.release", |
25 "chrome_appid.cc", | 27 "chrome_appid.cc", |
26 "configuration.cc", | 28 "configuration.cc", |
27 "configuration.h", | 29 "configuration.h", |
28 "decompress.cc", | 30 "decompress.cc", |
29 "decompress.h", | 31 "decompress.h", |
30 "mini_installer.ico", | 32 "mini_installer.ico", |
31 "mini_installer.rc", | 33 "mini_installer.rc", |
32 "mini_installer_constants.cc", | 34 "mini_installer_constants.cc", |
33 "mini_installer_constants.h", | 35 "mini_installer_constants.h", |
34 "mini_installer_resource.h", | 36 "mini_installer_resource.h", |
35 "mini_string.cc", | 37 "mini_string.cc", |
36 "mini_string.h", | 38 "mini_string.h", |
37 "pe_resource.cc", | 39 "pe_resource.cc", |
38 "pe_resource.h", | 40 "pe_resource.h", |
39 "regkey.cc", | 41 "regkey.cc", |
40 "regkey.h", | 42 "regkey.h", |
41 ] | 43 ] |
42 | 44 |
45 configs -= [ "//build/config/compiler:compiler" ] | |
46 configs += [ ":mini_installer_compiler_flags" ] | |
47 | |
43 deps = [ | 48 deps = [ |
44 #"test_installer_sentinel", TODO(GYP) bug 521052. | 49 #"test_installer_sentinel", TODO(GYP) bug 521052. |
45 ] | 50 ] |
46 } | 51 } |
47 | 52 |
53 process_version("version") { | |
54 template_file = "mini_installer_exe_version.rc.version" | |
55 output = "$target_gen_dir/mini_installer_version.rc" | |
56 } | |
57 | |
48 source_set("unit_tests") { | 58 source_set("unit_tests") { |
49 testonly = true | 59 testonly = true |
50 | 60 |
51 sources = [ | 61 sources = [ |
52 "configuration_test.cc", | 62 "configuration_test.cc", |
53 "decompress_test.cc", | 63 "decompress_test.cc", |
54 "mini_string_test.cc", | 64 "mini_string_test.cc", |
55 ] | 65 ] |
56 | 66 |
57 public_deps = [ | 67 public_deps = [ |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
148 | 158 |
149 #"../chrome.gyp:chrome_nacl_win64", TODO(GYP) bug 512869. | 159 #"../chrome.gyp:chrome_nacl_win64", TODO(GYP) bug 512869. |
150 ] | 160 ] |
151 } | 161 } |
152 | 162 |
153 # TODO(GYP) bug 521052: This target needs to be checked to make sure its the | 163 # TODO(GYP) bug 521052: This target needs to be checked to make sure its the |
154 # same size as the GYP build. | 164 # same size as the GYP build. |
155 executable("mini_installer") { | 165 executable("mini_installer") { |
156 sources = [ | 166 sources = [ |
157 "mini_installer.cc", | 167 "mini_installer.cc", |
158 "mini_installer_exe_version.rc.version", | |
159 packed_files_rc_file, | 168 packed_files_rc_file, |
160 ] | 169 ] |
161 | 170 |
162 # This target is special so we manually override most linker flags and | 171 # This target is special so we manually override most linker flags and |
163 # specify our own to keep the size down. | 172 # specify our own to keep the size down. |
164 configs -= [ | 173 configs -= [ |
165 "//build/config/compiler:compiler", | 174 "//build/config/compiler:compiler", |
166 "//build/config/win:common_linker_setup", | 175 "//build/config/win:common_linker_setup", |
167 "//build/config/win:console", | 176 "//build/config/win:console", |
168 ] | 177 ] |
169 configs += [ | 178 configs += [ |
170 ":mini_installer_compiler_flags", | 179 ":mini_installer_compiler_flags", |
171 "//build/config/win:windowed", | 180 "//build/config/win:windowed", |
172 ] | 181 ] |
173 | 182 |
174 ldflags = [ | 183 ldflags = [ |
175 "/ENTRY:MainEntryPoint", | 184 "/ENTRY:MainEntryPoint", |
176 "/FIXED:NO", | 185 "/FIXED:NO", |
177 "/NXCOMPAT", | 186 "/NXCOMPAT", |
178 ] | 187 ] |
179 | 188 |
180 libs = [ "setupapi.lib" ] | 189 libs = [ "setupapi.lib" ] |
181 | 190 |
182 deps = [ | 191 deps = [ |
183 ":archive", | 192 ":archive", |
184 ":lib", | 193 ":lib", |
194 ":version", | |
185 "//build/config/sanitizers:deps", | 195 "//build/config/sanitizers:deps", |
186 "//build/win:default_exe_manifest", | 196 "//build/win:default_exe_manifest", |
187 "//chrome/installer/setup", | |
188 ] | 197 ] |
189 } | 198 } |
OLD | NEW |