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

Side by Side Diff: editor/tools/compile_analyzer_java.py

Issue 240723006: Replace Java based analyzer with Dart based analyzer when building SDK (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: merge Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « editor/tools/compile_analyzer.py ('k') | sdk/bin/dartanalyzer » ('j') | 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 # Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 # 5 #
6 # Script to compile the analyzer. 6 # Script to compile the analyzer.
7 # 7 #
8 # Usage: compile_analyzer.py OPTIONS files 8 # Usage: compile_analyzer.py OPTIONS files
9 # 9 #
10 10
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 print >> output, 'Implementation-Version: %s' % GetDartVersion() 93 print >> output, 'Implementation-Version: %s' % GetDartVersion()
94 94
95 def VerifyJavacGetPath(): 95 def VerifyJavacGetPath():
96 javac_path = GetJavacPath() 96 javac_path = GetJavacPath()
97 try: 97 try:
98 subprocess.check_output([javac_path, "-version"]) 98 subprocess.check_output([javac_path, "-version"])
99 except: 99 except:
100 print "You do not have JDK installed, can't build the analyzer" 100 print "You do not have JDK installed, can't build the analyzer"
101 exit(1) 101 exit(1)
102 return javac_path 102 return javac_path
103 103
104 def GetJavacPath(): 104 def GetJavacPath():
105 if 'JAVA_HOME' in os.environ: 105 if 'JAVA_HOME' in os.environ:
106 return join(os.environ['JAVA_HOME'], 'bin', 106 return join(os.environ['JAVA_HOME'], 'bin',
107 'javac' + GetExecutableExtension()) 107 'javac' + GetExecutableExtension())
108 else: 108 else:
109 return "javac" 109 return "javac"
110 110
111 def GetJarToolPath(): 111 def GetJarToolPath():
112 if 'JAVA_HOME' in os.environ: 112 if 'JAVA_HOME' in os.environ:
113 return join(os.environ['JAVA_HOME'], 'bin', 'jar' + GetExecutableExtension() ) 113 return join(os.environ['JAVA_HOME'], 'bin', 'jar' + GetExecutableExtension() )
(...skipping 19 matching lines...) Expand all
133 os.makedirs(options.output_dir) 133 os.makedirs(options.output_dir)
134 134
135 CopyFiles(options) 135 CopyFiles(options)
136 CreateManifestFile(options) 136 CreateManifestFile(options)
137 CompileAnalyzer(options, args) 137 CompileAnalyzer(options, args)
138 CreateJarFile(options) 138 CreateJarFile(options)
139 139
140 140
141 if __name__ == '__main__': 141 if __name__ == '__main__':
142 main() 142 main()
OLDNEW
« no previous file with comments | « editor/tools/compile_analyzer.py ('k') | sdk/bin/dartanalyzer » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698