Change three SPDY tests to use port 8080 instead of 443.
[chromium-blink-merge.git] / chrome / installer / mini_installer.gyp
blobe6b0ca7cc8de3a0854f4578dcc1733d79df81eba
2   'variables': {
3     'version_py': '<(DEPTH)/build/util/version.py',
4     'version_path': '../../chrome/VERSION',
5     'lastchange_path': '<(DEPTH)/build/util/LASTCHANGE',
6     # 'branding_dir' is set in the 'conditions' section at the bottom.
7     'msvs_use_common_release': 0,
8     'msvs_use_common_linker_extras': 0,
9     'mini_installer_internal_deps%': 0,
10     'mini_installer_official_deps%': 0,
11   },
12   'includes': [
13     '../../build/win_precompile.gypi',
14   ],
15   'conditions': [
16     ['OS=="win"', {
17       'targets': [
18         {
19           'target_name': 'mini_installer',
20           'type': 'executable',
22           'dependencies': [
23             '../chrome.gyp:chrome',
24             '../chrome.gyp:chrome_nacl_win64',
25             '../chrome.gyp:chrome_dll',
26             '../chrome.gyp:default_extensions',
27             '../chrome.gyp:setup',
28           ],
29           'include_dirs': [
30             '../..',
31             '<(INTERMEDIATE_DIR)',
32             '<(SHARED_INTERMEDIATE_DIR)/chrome',
33           ],
34           'sources': [
35             'mini_installer/appid.h',
36             'mini_installer/chrome.release',
37             'mini_installer/chrome_appid.cc',
38             'mini_installer/configuration.cc',
39             'mini_installer/configuration.h',
40             'mini_installer/decompress.cc',
41             'mini_installer/decompress.h',
42             'mini_installer/exit_code.h',
43             'mini_installer/mini_installer.cc',
44             'mini_installer/mini_installer.ico',
45             'mini_installer/mini_installer.rc',
46             'mini_installer/mini_installer_constants.cc',
47             'mini_installer/mini_installer_constants.h',
48             'mini_installer/mini_installer_exe_version.rc.version',
49             'mini_installer/mini_installer_resource.h',
50             'mini_installer/mini_string.cc',
51             'mini_installer/mini_string.h',
52             'mini_installer/pe_resource.cc',
53             'mini_installer/pe_resource.h',
54             '<(INTERMEDIATE_DIR)/packed_files.rc',
55           ],
56           'msvs_settings': {
57             'VCCLCompilerTool': {
58               'EnableIntrinsicFunctions': 'true',
59               'BufferSecurityCheck': 'false',
60               'BasicRuntimeChecks': '0',
61               'ExceptionHandling': '0',
62             },
63             'VCLinkerTool': {
64               'RandomizedBaseAddress': '1',
65               'DataExecutionPrevention': '0',
66               'AdditionalLibraryDirectories': [
67                 '<(PRODUCT_DIR)/lib'
68               ],
69               'DelayLoadDLLs': [],
70               'EntryPointSymbol': 'MainEntryPoint',
71               'IgnoreAllDefaultLibraries': 'true',
72               'OptimizeForWindows98': '1',
73               'SubSystem': '2',     # Set /SUBSYSTEM:WINDOWS
74               'AdditionalDependencies': [
75                 'shlwapi.lib',
76                 'setupapi.lib',
77               ],
78             },
79             'VCManifestTool': {
80               'AdditionalManifestFiles': [
81                 '$(ProjectDir)\\mini_installer\\mini_installer.exe.manifest',
82               ],
83             },
84           },
85           'configurations': {
86             'Debug_Base': {
87               'msvs_settings': {
88                 'VCCLCompilerTool': {
89                   'BasicRuntimeChecks': '0',
90                   'BufferSecurityCheck': 'false',
91                   'ExceptionHandling': '0',
92                 },
93                 'VCLinkerTool': {
94                   'SubSystem': '2',     # Set /SUBSYSTEM:WINDOWS
95                   'AdditionalOptions': [
96                     '/safeseh:no',
97                     '/dynamicbase:no',
98                     '/ignore:4199',
99                     '/ignore:4221',
100                     '/nxcompat',
101                   ],
102                 },
103               },
104             },
105             'Release_Base': {
106               'includes': ['../../build/internal/release_defaults.gypi'],
107               'msvs_settings': {
108                 'VCCLCompilerTool': {
109                   'EnableIntrinsicFunctions': 'true',
110                   'BasicRuntimeChecks': '0',
111                   'BufferSecurityCheck': 'false',
112                   'ExceptionHandling': '0',
113                 },
114                 'VCLinkerTool': {
115                   'SubSystem': '2',     # Set /SUBSYSTEM:WINDOWS
116                   'Profile': 'false',   # Conflicts with /FIXED
117                   'AdditionalOptions': [
118                     '/SAFESEH:NO',
119                     '/NXCOMPAT',
120                     '/DYNAMICBASE:NO',
121                     '/FIXED',
122                   ],
123                 },
124               },
125             },
126           },
128           # Disable precompiled headers for this project, to avoid
129           # linker errors when building with VS 2008.
130           'msvs_precompiled_header': '',
131           'msvs_precompiled_source': '',
133           # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
134           'msvs_disabled_warnings': [ 4267, ],
136           'variables': {
137             # Opt out the common compatibility manifest to work around
138             # crbug.com/272660.
139             # TODO(yukawa): Enable the common compatibility manifest again.
140             'win_exe_compatibility_manifest': '',
141           },
142           'rules': [
143             {
144               'rule_name': 'mini_installer_version',
145               'extension': 'version',
146               'variables': {
147                 'template_input_path': 'mini_installer/mini_installer_exe_version.rc.version',
148               },
149               'inputs': [
150                 '<(template_input_path)',
151                 '<(version_path)',
152                 '<(lastchange_path)',
153                 '<(branding_dir)/BRANDING',
154               ],
155               'outputs': [
156                 '<(PRODUCT_DIR)/mini_installer_exe_version.rc',
157               ],
158               'action': [
159                 'python', '<(version_py)',
160                 '-f', '<(version_path)',
161                 '-f', '<(lastchange_path)',
162                 '-f', '<(branding_dir)/BRANDING',
163                 '<(template_input_path)',
164                 '<@(_outputs)',
165               ],
166               'process_outputs_as_sources': 1,
167               'message': 'Generating version information'
168             },
169             {
170               'rule_name': 'installer_archive',
171               'extension': 'release',
172               'variables': {
173                 'create_installer_archive_py_path':
174                   '../tools/build/win/create_installer_archive.py',
175               },
176               'conditions': [
177                 ['enable_hidpi == 1', {
178                   'variables': {
179                     'enable_hidpi_flag': '--enable_hidpi=1',
180                   },
181                 }, {
182                   'variables': {
183                     'enable_hidpi_flag': '',
184                   },
185                 }],
186                 ['component == "shared_library"', {
187                   'variables': {
188                     'component_build_flag': '--component_build=1',
189                   },
190                 }, {
191                   'variables': {
192                     'component_build_flag': '',
193                   },
194                   'outputs': [
195                     '<(PRODUCT_DIR)/<(RULE_INPUT_NAME).packed.7z',
196                   ],
197                 }],
198                 ['disable_nacl==1', {
199                   'inputs!': [
200                     '<(PRODUCT_DIR)/nacl64.exe',
201                     '<(PRODUCT_DIR)/nacl_irt_x86_32.nexe',
202                     '<(PRODUCT_DIR)/nacl_irt_x86_64.nexe',
203                   ],
204                 }],
205                 ['target_arch=="x64"', {
206                   'inputs!': [
207                     '<(PRODUCT_DIR)/nacl64.exe',
208                     '<(PRODUCT_DIR)/nacl_irt_x86_32.nexe',
209                   ],
210                   'variables': {
211                     'target_arch_flag': '--target_arch=x64',
212                   },
213                 }, {
214                   'variables': {
215                     'target_arch_flag': '--target_arch=x86',
216                   },
217                 }],
218                 ['icu_use_data_file_flag == 0', {
219                   'inputs': [
220                     '<(PRODUCT_DIR)/icudt.dll',
221                   ],
222                 }, { # else icu_use_data_file_flag != 0
223                   'inputs': [
224                     '<(PRODUCT_DIR)/icudtl.dat',
225                   ],
226                 }],
227                 ['v8_use_external_startup_data == 1', {
228                   'inputs': [
229                     '<(PRODUCT_DIR)/natives_blob.bin',
230                     '<(PRODUCT_DIR)/snapshot_blob.bin',
231                   ],
232                 }],
233               ],
234               'inputs': [
235                 '<(create_installer_archive_py_path)',
236                 '<(PRODUCT_DIR)/chrome.exe',
237                 '<(PRODUCT_DIR)/chrome.dll',
238                 '<(PRODUCT_DIR)/nacl64.exe',
239                 '<(PRODUCT_DIR)/nacl_irt_x86_32.nexe',
240                 '<(PRODUCT_DIR)/nacl_irt_x86_64.nexe',
241                 '<(PRODUCT_DIR)/locales/en-US.pak',
242               ],
243               'outputs': [
244                 # Also note that chrome.packed.7z is defined as an output in a
245                 # conditional above.
246                 'xxx2.out',
247                 '<(PRODUCT_DIR)/<(RULE_INPUT_NAME).7z',
248                 '<(PRODUCT_DIR)/setup.ex_',
249                 '<(INTERMEDIATE_DIR)/packed_files.rc',
250               ],
251               'action': [
252                 'python',
253                 '<(create_installer_archive_py_path)',
254                 '--build_dir', '<(PRODUCT_DIR)',
255                 '--staging_dir', '<(INTERMEDIATE_DIR)',
256                 '--input_file', '<(RULE_INPUT_PATH)',
257                 '--resource_file_path', '<(INTERMEDIATE_DIR)/packed_files.rc',
258                 '<(enable_hidpi_flag)',
259                 '<(component_build_flag)',
260                 '<(target_arch_flag)',
261                 # TODO(sgk):  may just use environment variables
262                 #'--distribution=$(CHROMIUM_BUILD)',
263                 '--distribution=_google_chrome',
264                 # Optional arguments to generate diff installer
265                 #'--last_chrome_installer=C:/Temp/base',
266                 #'--setup_exe_format=DIFF',
267                 #'--diff_algorithm=COURGETTE',
268               ],
269               'message': 'Create installer archive',
270             },
271           ],
272           # TODO(mark):  <(branding_dir) should be defined by the
273           # global condition block at the bottom of the file, but
274           # this doesn't work due to the following issue:
275           #
276           #   http://code.google.com/p/gyp/issues/detail?id=22
277           #
278           # Remove this block once the above issue is fixed.
279           'conditions': [
280             [ 'branding == "Chrome"', {
281               'variables': {
282                  'branding_dir': '../app/theme/google_chrome',
283               },
284             }, { # else branding!="Chrome"
285               'variables': {
286                  'branding_dir': '../app/theme/chromium',
287               },
288             }],
289           ],
290         },
291       ],
292       'conditions': [
293         ['test_isolation_mode != "noop"', {
294           'targets': [
295             {
296               'target_name': 'mini_installer_tests_run',
297               'type': 'none',
298               'dependencies': [
299                 'mini_installer',
300               ],
301               'includes': [
302                 '../../build/isolate.gypi',
303               ],
304               'sources': [
305                 'mini_installer_tests.isolate',
306               ],
307             },
308           ],
309         }],
310       ],
311     }],
312     [ 'branding == "Chrome"', {
313       'variables': {
314          'branding_dir': '../app/theme/google_chrome',
315       },
316     }, { # else branding!="Chrome"
317       'variables': {
318          'branding_dir': '../app/theme/chromium',
319       },
320     }],
321   ],