1 # Copyright (c) 2012 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.
6 ['OS=="mac" or OS=="win"', {
9 'target_name': 'chrome_dll',
15 ['incremental_chrome_dll==1', {
16 # Linking to a different directory and then hardlinking back
17 # to OutDir is a workaround to avoid having the .ilk for
18 # chrome.exe and chrome.dll conflicting. See crbug.com/92528
19 # for more information. Done on the dll instead of the exe so
20 # that people launching from VS don't need to modify
21 # $(TargetPath) for the exe.
24 'action_name': 'hardlink_to_output',
26 '$(OutDir)\\initial\\chrome.dll',
29 '$(OutDir)\\chrome.dll',
31 'action': ['tools\\build\\win\\hardlink_failsafe.bat',
32 '$(OutDir)\\initial\\chrome.dll',
33 '$(OutDir)\\chrome.dll'],
34 'msvs_cygwin_shell': 0,
41 'target_name': 'chrome_main_dll',
42 'type': 'shared_library',
44 'enable_wexit_time_destructors': 1,
47 '<@(chromium_dependencies)',
48 'app/policy/cloud_policy_codegen.gyp:policy',
53 '../ui/gfx/compositor/compositor.gyp:compositor',
57 'product_name': 'chrome',
59 # On Windows, link the dependencies (libraries) that make
60 # up actual Chromium functionality into this .dll.
61 'chrome_resources.gyp:chrome_resources',
62 'chrome_version_resources',
63 'installer_util_strings',
64 '../content/content.gyp:content_worker',
65 '../crypto/crypto.gyp:crypto',
66 '../printing/printing.gyp:printing',
67 '../net/net.gyp:net_resources',
68 '../third_party/cld/cld.gyp:cld',
69 '../ui/views/views.gyp:views',
70 '../webkit/support/webkit_support.gyp:webkit_resources',
73 'app/chrome_command_ids.h',
75 'app/chrome_dll_resource.h',
77 'app/chrome_main_delegate.cc',
78 'app/chrome_main_delegate.h',
80 '<(SHARED_INTERMEDIATE_DIR)/chrome_version/chrome_dll_version.rc',
81 '../base/win/dllmain.cc',
83 '../webkit/glue/resources/aliasb.cur',
84 '../webkit/glue/resources/cell.cur',
85 '../webkit/glue/resources/col_resize.cur',
86 '../webkit/glue/resources/copy.cur',
87 '../webkit/glue/resources/none.cur',
88 '../webkit/glue/resources/row_resize.cur',
89 '../webkit/glue/resources/vertical_text.cur',
90 '../webkit/glue/resources/zoom_in.cur',
91 '../webkit/glue/resources/zoom_out.cur',
93 # TODO: It would be nice to have these pulled in
94 # automatically from direct_dependent_settings in
95 # their various targets (net.gyp:net_resources, etc.),
96 # but that causes errors in other targets when
97 # resulting .res files get referenced multiple times.
98 '<(SHARED_INTERMEDIATE_DIR)/chrome/browser_resources.rc',
99 '<(SHARED_INTERMEDIATE_DIR)/chrome/common_resources.rc',
100 '<(SHARED_INTERMEDIATE_DIR)/chrome/renderer_resources.rc',
101 '<(SHARED_INTERMEDIATE_DIR)/chrome/theme_resources.rc',
102 '<(SHARED_INTERMEDIATE_DIR)/chrome/theme_resources_standard.rc',
103 '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.rc',
104 '<(SHARED_INTERMEDIATE_DIR)/ui/gfx/gfx_resources.rc',
105 '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_resources.rc',
106 '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources_standard/ui_resources_standard.rc',
107 '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.rc',
108 '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_resources.rc',
110 # TODO(sgk): left-over from pre-gyp build, figure out
111 # if we still need them and/or how to update to gyp.
112 #'app/check_dependents.bat',
113 #'app/chrome.dll.deps',
116 '<(DEPTH)/third_party/wtl/include',
128 'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
135 'BaseAddress': '0x01c30000',
136 'ImportLibrary': '$(OutDir)\\lib\\chrome_dll.lib',
137 'ProgramDatabaseFile': '$(OutDir)\\chrome_dll.pdb',
138 # Set /SUBSYSTEM:WINDOWS for chrome.dll (for consistency).
141 ['incremental_chrome_dll==1', {
142 'OutputFile': '$(OutDir)\\initial\\chrome.dll',
143 'UseLibraryDependencyInputs': "true",
164 'AdditionalManifestFiles': '$(ProjectDir)\\app\\chrome.dll.manifest',
169 # The main browser executable's name is <(mac_product_name).
170 # Certain things will get confused if two modules in the
171 # executable share the same name, so append " Framework" to the
172 # product_name used for the framework. This will result in
173 # a name like "Chromium Framework.framework".
174 'product_name': '<(mac_product_name) Framework',
177 'CHROMIUM_BUNDLE_ID': '<(mac_bundle_id)',
179 # The dylib versions are of the form a[.b[.c]], where a is a
180 # 16-bit unsigned integer, and b and c are 8-bit unsigned
181 # integers. Any missing component is taken to be 0. The
182 # best mapping from product version numbers into this scheme
183 # is to just use a=BUILD, b=(PATCH/256), c=(PATCH%256). There
184 # is no ambiguity in this scheme because the build and patch
185 # numbers are guaranteed unique even across distinct major
186 # and minor version numbers. These settings correspond to
187 # -compatibility_version and -current_version.
188 'DYLIB_COMPATIBILITY_VERSION': '<(version_mac_dylib)',
189 'DYLIB_CURRENT_VERSION': '<(version_mac_dylib)',
191 # The framework is placed within the .app's versioned
192 # directory. DYLIB_INSTALL_NAME_BASE and
193 # LD_DYLIB_INSTALL_NAME affect -install_name.
194 'DYLIB_INSTALL_NAME_BASE':
195 '@executable_path/../Versions/<(version_full)',
196 # See tools/build/mac/copy_framework_unversioned for
197 # information on LD_DYLIB_INSTALL_NAME.
198 'LD_DYLIB_INSTALL_NAME':
199 '$(DYLIB_INSTALL_NAME_BASE:standardizepath)/$(WRAPPER_NAME)/$(PRODUCT_NAME)',
201 'INFOPLIST_FILE': 'app/framework-Info.plist',
203 # Define the order of symbols within the framework. This
205 'ORDER_FILE': 'app/framework.order',
208 'app/chrome_command_ids.h',
209 'app/chrome_dll_resource.h',
210 'app/chrome_main.cc',
211 'app/chrome_main_delegate.cc',
212 'app/chrome_main_delegate.h',
213 'app/chrome_main_app_mode_mac.mm',
214 'app/chrome_main_mac.mm',
215 'app/chrome_main_mac.h',
220 # TODO(mark): Come up with a fancier way to do this. It should
221 # only be necessary to list framework-Info.plist once, not the
222 # three times it is listed here.
223 'mac_bundle_resources': [
224 # This image is used to badge the lock icon in the
225 # authentication dialogs, such as those used for installation
226 # from disk image and Keystone promotion (if so enabled). It
227 # needs to exist as a file on disk and not just something in a
228 # resource bundle because that's the interface that
229 # Authorization Services uses. Also, Authorization Services
230 # can't deal with .icns files.
231 'app/theme/<(theme_dir_name)/product_logo_32.png',
233 'app/framework-Info.plist',
234 'app/nibs/About.xib',
235 'app/nibs/AboutIPC.xib',
236 'app/nibs/AvatarMenuItem.xib',
237 'app/nibs/BookmarkAllTabs.xib',
238 'app/nibs/BookmarkBar.xib',
239 'app/nibs/BookmarkBarFolderWindow.xib',
240 'app/nibs/BookmarkBubble.xib',
241 'app/nibs/BookmarkEditor.xib',
242 'app/nibs/BookmarkNameFolder.xib',
243 'app/nibs/BrowserWindow.xib',
244 'app/nibs/CollectedCookies.xib',
245 'app/nibs/CookieDetailsView.xib',
246 'app/nibs/ContentBlockedCookies.xib',
247 'app/nibs/ContentBlockedImages.xib',
248 'app/nibs/ContentBlockedJavaScript.xib',
249 'app/nibs/ContentBlockedPlugins.xib',
250 'app/nibs/ContentBlockedPopups.xib',
251 'app/nibs/ContentBlockedGeolocation.xib',
252 'app/nibs/DownloadItem.xib',
253 'app/nibs/DownloadShelf.xib',
254 'app/nibs/EditSearchEngine.xib',
255 'app/nibs/ExtensionInstalledBubble.xib',
256 'app/nibs/ExtensionInstallPrompt.xib',
257 'app/nibs/ExtensionInstallPromptInline.xib',
258 'app/nibs/ExtensionInstallPromptNoWarnings.xib',
259 'app/nibs/FindBar.xib',
260 'app/nibs/FirstRunBubble.xib',
261 'app/nibs/FirstRunDialog.xib',
262 'app/nibs/FullscreenExitBubble.xib',
263 'app/nibs/GlobalErrorBubble.xib',
264 'app/nibs/HungRendererDialog.xib',
265 'app/nibs/HttpAuthLoginSheet.xib',
266 'app/nibs/ImportProgressDialog.xib',
267 'app/nibs/InfoBar.xib',
268 'app/nibs/InfoBarContainer.xib',
269 'app/nibs/InstantOptIn.xib',
270 'app/nibs/MainMenu.xib',
271 'app/nibs/Notification.xib',
272 'app/nibs/Panel.xib',
273 'app/nibs/PreviewableContents.xib',
274 'app/nibs/SaveAccessoryView.xib',
275 'app/nibs/SadTab.xib',
276 'app/nibs/SpeechInputBubble.xib',
277 'app/nibs/TabView.xib',
278 'app/nibs/TaskManager.xib',
279 'app/nibs/Toolbar.xib',
280 'app/nibs/WrenchMenu.xib',
281 'app/theme/balloon_wrench.pdf',
282 'app/theme/chevron.pdf',
283 'app/theme/find_next_Template.pdf',
284 'app/theme/find_prev_Template.pdf',
285 'app/theme/menu_hierarchy_arrow.pdf',
286 'app/theme/menu_overflow_down.pdf',
287 'app/theme/menu_overflow_up.pdf',
289 'app/theme/omnibox_extension_app.pdf',
290 'app/theme/omnibox_history.pdf',
291 'app/theme/omnibox_http.pdf',
292 'app/theme/omnibox_https_invalid.pdf',
293 'app/theme/omnibox_https_valid.pdf',
294 'app/theme/omnibox_https_warning.pdf',
295 'app/theme/omnibox_search.pdf',
296 'app/theme/omnibox_tts.pdf',
297 'app/theme/otr_icon.pdf',
298 'app/theme/star.pdf',
299 'app/theme/star_lit.pdf',
300 'browser/mac/install.sh',
301 '<(SHARED_INTERMEDIATE_DIR)/repack/chrome.pak',
302 '<(SHARED_INTERMEDIATE_DIR)/repack/resources.pak',
303 '<!@pymod_do_main(repack_locales -o -g <(grit_out_dir) -s <(SHARED_INTERMEDIATE_DIR) -x <(SHARED_INTERMEDIATE_DIR) <(locales))',
304 # Note: pseudo_locales are generated via the packed_resources
305 # dependency but not copied to the final target. See
306 # common.gypi for more info.
308 'mac_bundle_resources!': [
309 'app/framework-Info.plist',
312 # Bring in pdfsqueeze and run it on all pdfs
313 '../build/temp_gyp/pdfsqueeze.gyp:pdfsqueeze',
314 '../crypto/crypto.gyp:crypto',
315 # On Mac, Flash gets put into the framework, so we need this
316 # dependency here. flash_player.gyp will copy the Flash bundle
318 '../third_party/adobe/flash/flash_player.gyp:flash_player',
319 'chrome_resources.gyp:packed_extra_resources',
320 'chrome_resources.gyp:packed_resources',
324 'rule_name': 'pdfsqueeze',
327 '<(PRODUCT_DIR)/pdfsqueeze',
330 '<(INTERMEDIATE_DIR)/pdfsqueeze/<(RULE_INPUT_ROOT).pdf',
332 'action': ['<(PRODUCT_DIR)/pdfsqueeze',
333 '<(RULE_INPUT_PATH)', '<@(_outputs)'],
334 'message': 'Running pdfsqueeze on <(RULE_INPUT_PATH)',
339 ['branding=="Chrome"', {
340 'theme_dir_name': 'google_chrome',
341 }, { # else: 'branding!="Chrome"
342 'theme_dir_name': 'chromium',
345 'repack_path': '../tools/grit/grit/format/repack.py',
349 'includes': ['chrome_repack_theme_resources_large.gypi']
354 # This step causes an error to be raised if the .order file
355 # does not account for all global text symbols. It
356 # validates the completeness of the .order file.
357 'postbuild_name': 'Verify global text symbol order',
359 'verify_order_path': 'tools/build/mac/verify_order',
362 '<(verify_order_path)',
364 '${BUILT_PRODUCTS_DIR}/${EXECUTABLE_PATH}',
368 # Modify the Info.plist as needed. The script explains why
369 # this is needed. This is also done in the chrome target.
370 # The framework needs the Breakpad keys if this feature is
371 # enabled. It does not need the Keystone keys; these always
372 # come from the outer application bundle. The framework
373 # doesn't currently use the Subversion keys for anything,
374 # but this seems like a really good place to store them.
375 'postbuild_name': 'Tweak Info.plist',
376 'action': ['<(tweak_info_plist_path)',
377 '--breakpad=<(mac_breakpad_compiled_in)',
378 '--breakpad_uploads=<(mac_breakpad_uploads)',
385 'postbuild_name': 'Symlink Libraries',
389 'Versions/Current/Libraries',
390 '${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/Libraries'
396 # Copy FFmpeg binaries for audio/video support.
397 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Libraries',
399 '<(PRODUCT_DIR)/ffmpegsumo.so',
403 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Internet Plug-Ins',
406 ['branding == "Chrome"', {
408 '<(PRODUCT_DIR)/Flash Player Plugin for Chrome.plugin',
409 '<(PRODUCT_DIR)/plugin.vch',
414 '<(PRODUCT_DIR)/PDF.plugin',
417 ['disable_nacl!=1', {
419 '<(PRODUCT_DIR)/ppGoogleNaClPluginChrome.plugin',
420 # We leave out nacl_irt_x86_64.nexe because we only
421 # support x86-32 NaCl on Mac OS X.
422 '<(PRODUCT_DIR)/nacl_irt_x86_32.nexe',
428 # Copy of resources used by tests.
429 'destination': '<(PRODUCT_DIR)',
431 '<(SHARED_INTERMEDIATE_DIR)/repack/resources.pak'
435 # Copy of resources used by tests.
436 'destination': '<(PRODUCT_DIR)/pseudo_locales',
438 '<(SHARED_INTERMEDIATE_DIR)/<(pseudo_locales).pak'
442 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/resources',
445 ['debug_devtools!=0', {
447 '<(PRODUCT_DIR)/resources/inspector',
454 ['branding=="Chrome"', {
457 # This location is for the Mac build. Note that the
458 # copying of these files for Windows and Linux is handled
459 # in chrome.gyp, as Mac needs to be dropped inside the
462 '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Default Apps',
463 'files': ['<@(default_apps_list)'],
467 ['mac_breakpad==1', {
469 # A real .dSYM is needed for dump_syms to operate on.
473 ['mac_breakpad_compiled_in==1', {
475 'app/breakpad_mac.mm',
476 'app/breakpad_mac.h',
479 '../breakpad/breakpad.gyp:breakpad',
480 'app/policy/cloud_policy_codegen.gyp:policy',
484 'destination': '<(PRODUCT_DIR)/$(CONTENTS_FOLDER_PATH)/Resources',
486 '<(PRODUCT_DIR)/crash_inspector',
487 '<(PRODUCT_DIR)/crash_report_sender.app'
491 }, { # else: mac_breakpad_compiled_in!=1
492 # No Breakpad, put in the stubs.
494 'app/breakpad_mac_stubs.mm',
495 'app/breakpad_mac.h',
497 }], # mac_breakpad_compiled_in
498 ['mac_keystone==1', {
499 'mac_bundle_resources': [
500 'browser/mac/keystone_promote_preflight.sh',
501 'browser/mac/keystone_promote_postflight.sh',
505 'postbuild_name': 'Copy KeystoneRegistration.framework',
507 'tools/build/mac/copy_framework_unversioned',
508 '../third_party/googlemac/Releases/Keystone/KeystoneRegistration.framework',
509 '${BUILT_PRODUCTS_DIR}/${CONTENTS_FOLDER_PATH}/Frameworks',
513 'postbuild_name': 'Symlink Frameworks',
517 'Versions/Current/Frameworks',
518 '${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/Frameworks'
525 '../pdf/pdf.gyp:pdf',
531 }, # target chrome_dll
533 }], # OS=="mac" or OS=="win"