Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(30)

Side by Side Diff: gypfiles/gyp_v8

Issue 2327033002: [gn] Switch off gyp in runhooks by default (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « DEPS ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2012 the V8 project authors. All rights reserved. 3 # Copyright 2012 the V8 project authors. All rights reserved.
4 # Redistribution and use in source and binary forms, with or without 4 # Redistribution and use in source and binary forms, with or without
5 # modification, are permitted provided that the following conditions are 5 # modification, are permitted provided that the following conditions are
6 # met: 6 # met:
7 # 7 #
8 # * Redistributions of source code must retain the above copyright 8 # * Redistributions of source code must retain the above copyright
9 # notice, this list of conditions and the following disclaimer. 9 # notice, this list of conditions and the following disclaimer.
10 # * Redistributions in binary form must reproduce the above 10 # * Redistributions in binary form must reproduce the above
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 (x86_runtime, x64_runtime)) 111 (x86_runtime, x64_runtime))
112 112
113 if rc != 0: 113 if rc != 0:
114 print 'Error running GYP' 114 print 'Error running GYP'
115 sys.exit(rc) 115 sys.exit(rc)
116 116
117 117
118 if __name__ == '__main__': 118 if __name__ == '__main__':
119 args = sys.argv[1:] 119 args = sys.argv[1:]
120 120
121 if int(os.environ.get('GYP_CHROMIUM_NO_ACTION', 0)): 121 gyp_chromium_no_action = os.environ.get('GYP_CHROMIUM_NO_ACTION')
122 if gyp_chromium_no_action == '1':
122 print 'Skipping gyp_v8 due to GYP_CHROMIUM_NO_ACTION env var.' 123 print 'Skipping gyp_v8 due to GYP_CHROMIUM_NO_ACTION env var.'
123 sys.exit(0) 124 sys.exit(0)
124 125
126 running_as_hook = '--running-as-hook'
127 if running_as_hook in args and gyp_chromium_no_action != '0':
128 print 'GYP is now disabled by default in runhooks.\n'
129 print 'If you really want to run this, either run '
130 print '`python build/gyp_v8` explicitly by hand '
Michael Achenbach 2016/09/09 13:15:49 hmm - typo - will fix
131 print 'or set the environment variable GYP_CHROMIUM_NO_ACTION=0.'
132 sys.exit(0)
133
125 gyp_environment.set_environment() 134 gyp_environment.set_environment()
126 135
127 # This could give false positives since it doesn't actually do real option 136 # This could give false positives since it doesn't actually do real option
128 # parsing. Oh well. 137 # parsing. Oh well.
129 gyp_file_specified = False 138 gyp_file_specified = False
130 for arg in args: 139 for arg in args:
131 if arg.endswith('.gyp'): 140 if arg.endswith('.gyp'):
132 gyp_file_specified = True 141 gyp_file_specified = True
133 break 142 break
134 143
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 185
177 gyp_defines = os.environ.get('GYP_DEFINES', '') 186 gyp_defines = os.environ.get('GYP_DEFINES', '')
178 187
179 # Automatically turn on crosscompile support for platforms that need it. 188 # Automatically turn on crosscompile support for platforms that need it.
180 if all(('ninja' in gyp_generators, 189 if all(('ninja' in gyp_generators,
181 'OS=android' in gyp_defines, 190 'OS=android' in gyp_defines,
182 'GYP_CROSSCOMPILE' not in os.environ)): 191 'GYP_CROSSCOMPILE' not in os.environ)):
183 os.environ['GYP_CROSSCOMPILE'] = '1' 192 os.environ['GYP_CROSSCOMPILE'] = '1'
184 193
185 run_gyp(gyp_args) 194 run_gyp(gyp_args)
OLDNEW
« no previous file with comments | « DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698