| # Copyright 2015 The Chromium Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/config/mac/rules.gni") |
| import("//build/mac/tweak_info_plist.gni") |
| import("//build/util/branding.gni") |
| |
| # This is the part of the shim process compiled into Chrome. It runs only |
| # in the shim process, after the shim finds and loads the Chrome |
| # Framework bundle. |
| source_set("app_shim") { |
| sources = [ |
| "../app/chrome_crash_reporter_client.h", |
| "app_shim_controller.h", |
| "app_shim_controller.mm", |
| "app_shim_delegate.h", |
| "app_shim_delegate.mm", |
| "chrome_main_app_mode_mac.mm", |
| ] |
| |
| deps = [ |
| "//chrome:strings", |
| "//chrome/browser/ui:ui", |
| "//chrome/common", |
| "//chrome/common:mojo_bindings", |
| "//components/crash/content/app", |
| "//content/public/browser", |
| "//ipc", |
| "//mojo/core/embedder", |
| "//ui/accelerated_widget_mac", |
| "//ui/base", |
| "//ui/views:views", |
| ] |
| } |
| |
| tweak_info_plist("app_mode_loader_plist") { |
| info_plist = "app_mode-Info.plist" |
| args = [ |
| "--breakpad=0", |
| "--keystone=0", |
| "--scm=0", |
| ] |
| } |
| |
| mac_app_bundle("app_mode_loader") { |
| extra_configs = [ "//build/config/compiler:wexit_time_destructors" ] |
| |
| info_plist_target = ":app_mode_loader_plist" |
| extra_substitutions = [ |
| "APP_MODE_APP_BUNDLE_ID=$chrome_mac_bundle_id.app.@APP_MODE_SHORTCUT_ID@", |
| ] |
| |
| sources = [ |
| "app_mode_loader_mac.mm", |
| ] |
| |
| if (is_component_build) { |
| # Loaders are installed to ~/Applications. In a component build, include |
| # the absolute path to the out dir in their library search path so that |
| # their components are found at launch. |
| ldflags = [ |
| "-rpath", |
| rebase_path(root_out_dir), |
| ] |
| } |
| |
| deps = [ |
| "//base", |
| "//chrome/common:app_mode_app_support", |
| "//chrome/common:constants", |
| "//chrome/common:non_code_constants", |
| ] |
| |
| libs = [ |
| "AppKit.framework", |
| "CoreFoundation.framework", |
| "Foundation.framework", |
| ] |
| } |