| OLD | NEW |
| 1 # Copyright 2014 The Crashpad Authors. All rights reserved. | 1 # Copyright 2014 The Crashpad Authors. All rights reserved. |
| 2 # | 2 # |
| 3 # Licensed under the Apache License, Version 2.0 (the "License"); | 3 # Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 # you may not use this file except in compliance with the License. | 4 # you may not use this file except in compliance with the License. |
| 5 # You may obtain a copy of the License at | 5 # You may obtain a copy of the License at |
| 6 # | 6 # |
| 7 # http://www.apache.org/licenses/LICENSE-2.0 | 7 # http://www.apache.org/licenses/LICENSE-2.0 |
| 8 # | 8 # |
| 9 # Unless required by applicable law or agreed to in writing, software | 9 # Unless required by applicable law or agreed to in writing, software |
| 10 # distributed under the License is distributed on an "AS IS" BASIS, | 10 # distributed under the License is distributed on an "AS IS" BASIS, |
| 11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | 11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 # See the License for the specific language governing permissions and | 12 # See the License for the specific language governing permissions and |
| 13 # limitations under the License. | 13 # limitations under the License. |
| 14 | 14 |
| 15 { | 15 { |
| 16 'conditions': [ | 16 'conditions': [ |
| 17 ['OS=="mac"', { | 17 ['OS=="mac"', { |
| 18 'variables': { |
| 19 # Programs that use task_for_pid() can indicate to taskgated(8) in their |
| 20 # Info.plist that they are allowed to call that function. In order for |
| 21 # this to work, the programs in question must be signed by an authority |
| 22 # trusted by the system. Signing is beyond the scope of the build, but |
| 23 # the key to make this work is placed in Info.plist to enable the |
| 24 # desired behavior once the tools that require this access are signed. |
| 25 # |
| 26 # The tools built here are flat-file executables, and are not bundled. |
| 27 # To have an Info.plist, they must have a special __TEXT,__info_plist |
| 28 # section. This section is created at link time. |
| 29 # |
| 30 # The Info.plist for this purpose is mac/sectaskaccess_info.plist and is |
| 31 # referenced by OTHER_LDFLAGS. ninja runs the link step from the output |
| 32 # directory such as out/Release, and requires a relative path from that |
| 33 # directory. Xcode runs the link step from the directory of the |
| 34 # .xcodeproj, which is the directory of the .gyp file. |
| 35 'conditions': [ |
| 36 ['GENERATOR=="ninja"', { |
| 37 'sectaskaccess_info_plist': |
| 38 '../../tools/mac/sectaskaccess_info.plist', |
| 39 }, { # else: GENERATOR!="ninja" |
| 40 'sectaskaccess_info_plist': 'mac/sectaskaccess_info.plist', |
| 41 }], |
| 42 ], |
| 43 }, |
| 44 |
| 18 'targets': [ | 45 'targets': [ |
| 19 { | 46 { |
| 20 'target_name': 'tool_support', | 47 'target_name': 'tool_support', |
| 21 'type': 'static_library', | 48 'type': 'static_library', |
| 22 'dependencies': [ | 49 'dependencies': [ |
| 23 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', | 50 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', |
| 24 ], | 51 ], |
| 25 'include_dirs': [ | 52 'include_dirs': [ |
| 26 '..', | 53 '..', |
| 27 ], | 54 ], |
| (...skipping 26 matching lines...) Expand all Loading... |
| 54 '../compat/compat.gyp:compat', | 81 '../compat/compat.gyp:compat', |
| 55 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', | 82 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', |
| 56 '../util/util.gyp:util', | 83 '../util/util.gyp:util', |
| 57 ], | 84 ], |
| 58 'include_dirs': [ | 85 'include_dirs': [ |
| 59 '..', | 86 '..', |
| 60 ], | 87 ], |
| 61 'sources': [ | 88 'sources': [ |
| 62 'mac/exception_port_tool.cc', | 89 'mac/exception_port_tool.cc', |
| 63 ], | 90 ], |
| 91 'xcode_settings': { |
| 92 'OTHER_LDFLAGS': [ |
| 93 '-sectcreate', |
| 94 '__TEXT', |
| 95 '__info_plist', |
| 96 '<(sectaskaccess_info_plist)' |
| 97 ], |
| 98 }, |
| 64 }, | 99 }, |
| 65 { | 100 { |
| 66 'target_name': 'generate_dump', | 101 'target_name': 'generate_dump', |
| 67 'type': 'executable', | 102 'type': 'executable', |
| 68 'dependencies': [ | 103 'dependencies': [ |
| 69 'tool_support', | 104 'tool_support', |
| 70 '../compat/compat.gyp:compat', | 105 '../compat/compat.gyp:compat', |
| 71 '../minidump/minidump.gyp:minidump', | 106 '../minidump/minidump.gyp:minidump', |
| 72 '../snapshot/snapshot.gyp:snapshot', | 107 '../snapshot/snapshot.gyp:snapshot', |
| 73 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', | 108 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', |
| 74 '../util/util.gyp:util', | 109 '../util/util.gyp:util', |
| 75 ], | 110 ], |
| 76 'include_dirs': [ | 111 'include_dirs': [ |
| 77 '..', | 112 '..', |
| 78 ], | 113 ], |
| 79 'sources': [ | 114 'sources': [ |
| 80 'generate_dump.cc', | 115 'generate_dump.cc', |
| 81 ], | 116 ], |
| 117 'xcode_settings': { |
| 118 'OTHER_LDFLAGS': [ |
| 119 '-sectcreate', |
| 120 '__TEXT', |
| 121 '__info_plist', |
| 122 '<(sectaskaccess_info_plist)' |
| 123 ], |
| 124 }, |
| 82 }, | 125 }, |
| 83 { | 126 { |
| 84 'target_name': 'on_demand_service_tool', | 127 'target_name': 'on_demand_service_tool', |
| 85 'type': 'executable', | 128 'type': 'executable', |
| 86 'dependencies': [ | 129 'dependencies': [ |
| 87 'tool_support', | 130 'tool_support', |
| 88 '../compat/compat.gyp:compat', | 131 '../compat/compat.gyp:compat', |
| 89 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', | 132 '../third_party/mini_chromium/mini_chromium/base/base.gyp:base', |
| 90 '../util/util.gyp:util', | 133 '../util/util.gyp:util', |
| 91 ], | 134 ], |
| 92 'include_dirs': [ | 135 'include_dirs': [ |
| 93 '..', | 136 '..', |
| 94 ], | 137 ], |
| 95 'link_settings': { | 138 'link_settings': { |
| 96 'libraries': [ | 139 'libraries': [ |
| 97 '$(SDKROOT)/System/Library/Frameworks/CoreFoundation.framework', | 140 '$(SDKROOT)/System/Library/Frameworks/CoreFoundation.framework', |
| 98 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework', | 141 '$(SDKROOT)/System/Library/Frameworks/Foundation.framework', |
| 99 ], | 142 ], |
| 100 }, | 143 }, |
| 101 'sources': [ | 144 'sources': [ |
| 102 'mac/on_demand_service_tool.mm', | 145 'mac/on_demand_service_tool.mm', |
| 103 ], | 146 ], |
| 104 }, | 147 }, |
| 105 ], | 148 ], |
| 106 }, { | 149 }, { |
| 107 'targets': [], | 150 'targets': [], |
| 108 }], | 151 }], |
| 109 ], | 152 ], |
| 110 } | 153 } |
| OLD | NEW |