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

Side by Side Diff: sdk/bin/dart2js

Issue 16114013: Reland "Add --version option to dart2js and add version information (if available) to generated cod… (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix formatting. Created 7 years, 6 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 | « no previous file | sdk/bin/dart2js.bat » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2012, 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 function follow_links() { 6 function follow_links() {
7 while [ -h "$1" ]; do 7 while [ -h "$1" ]; do
8 # On Mac OS, readlink -f doesn't work. 8 # On Mac OS, readlink -f doesn't work.
9 1="$(readlink "$1")" 9 1="$(readlink "$1")"
10 done 10 done
(...skipping 23 matching lines...) Expand all
34 if test 8 -le `tput colors`; then 34 if test 8 -le `tput colors`; then
35 # Stdout has at least 8 colors, so enable colors. 35 # Stdout has at least 8 colors, so enable colors.
36 EXTRA_OPTIONS[${#EXTRA_OPTIONS[@]}]='--enable-diagnostic-colors' 36 EXTRA_OPTIONS[${#EXTRA_OPTIONS[@]}]='--enable-diagnostic-colors'
37 fi 37 fi
38 fi 38 fi
39 39
40 unset EXTRA_VM_OPTIONS 40 unset EXTRA_VM_OPTIONS
41 declare -a EXTRA_VM_OPTIONS 41 declare -a EXTRA_VM_OPTIONS
42 42
43 if test -f "$SNAPSHOT"; then 43 if test -f "$SNAPSHOT"; then
44 # TODO(ahe): Remove the following line when we are relatively sure it works.
45 echo Using snapshot "$SNAPSHOT" 1>&2
46
47 EXTRA_OPTIONS[${#EXTRA_OPTIONS[@]}]="--library-root=$SDK_DIR" 44 EXTRA_OPTIONS[${#EXTRA_OPTIONS[@]}]="--library-root=$SDK_DIR"
48 fi 45 fi
49 46
50 # Tell the VM to grow the heap more aggressively. This should only 47 # Tell the VM to grow the heap more aggressively. This should only
51 # be necessary temporarily until the VM is better at detecting how 48 # be necessary temporarily until the VM is better at detecting how
52 # applications use memory. 49 # applications use memory.
53 # TODO(ahe): Remove this option (http://dartbug.com/6495). 50 # TODO(ahe): Remove this option (http://dartbug.com/6495).
54 EXTRA_VM_OPTIONS[${#EXTRA_VM_OPTIONS[@]}]='--heap_growth_rate=512' 51 EXTRA_VM_OPTIONS[${#EXTRA_VM_OPTIONS[@]}]='--heap_growth_rate=512'
55 52
56 case $0 in 53 case $0 in
57 *_developer) 54 *_developer)
58 EXTRA_VM_OPTIONS[${#EXTRA_VM_OPTIONS[@]}]='--checked' 55 EXTRA_VM_OPTIONS[${#EXTRA_VM_OPTIONS[@]}]='--checked'
59 ;; 56 ;;
60 esac 57 esac
61 58
62 if test -f "$SNAPSHOT"; then 59 if test -f "$SNAPSHOT"; then
63 exec "$DART" "${EXTRA_VM_OPTIONS[@]}" "$SNAPSHOT" "dart2js" \ 60 exec "$DART" "${EXTRA_VM_OPTIONS[@]}" "$SNAPSHOT" "dart2js" \
64 "${EXTRA_OPTIONS[@]}" "$@" 61 "${EXTRA_OPTIONS[@]}" "$@"
65 else 62 else
66 exec "$DART" "${EXTRA_VM_OPTIONS[@]}" "$DART2JS" "${EXTRA_OPTIONS[@]}" "$@" 63 exec "$DART" "${EXTRA_VM_OPTIONS[@]}" "$DART2JS" "${EXTRA_OPTIONS[@]}" "$@"
67 fi 64 fi
OLDNEW
« no previous file with comments | « no previous file | sdk/bin/dart2js.bat » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698