Revert "Add dev_compiler to the SDK build process."

This broke the Mac and Windows builds, for reasons I'm still
investigating.

This reverts commit 2ddf244819.

TBR=jmesserly@google.com

Review URL: https://codereview.chromium.org/1813983003 .
This commit is contained in:
Paul Berry 2016-03-17 13:46:51 -07:00
parent 94c8b1fd7b
commit ceec063f27
7 changed files with 3 additions and 168 deletions

2
DEPS
View file

@ -41,7 +41,7 @@ vars = {
"dartdoc_tag" : "@v0.9.0",
"dart_services_rev" : "@7aea2574e6f3924bf409a80afb8ad52aa2be4f97",
"dart_style_tag": "@0.2.4",
"dev_compiler_rev": "@0c5dd2d1e999c421d978a478e267aac6279e087a",
"dev_compiler_rev": "@0.1.9",
"glob_rev": "@704cf75e4f26b417505c5c611bdaacd8808467dd",
"html_tag" : "@0.12.1+1",
"http_tag" : "@0.11.3+3",

View file

@ -15,7 +15,6 @@
'utils/dartdoc/dartdoc.gyp:dartdoc',
'utils/analysis_server/analysis_server.gyp:analysis_server',
'utils/dartanalyzer/dartanalyzer.gyp:dartanalyzer',
'utils/dartdevc/dartdevc.gyp:dartdevc',
],
'actions': [
{

View file

@ -12,7 +12,6 @@
'create_sdk',
'dart2js',
'dartanalyzer',
'dartdevc',
'packages',
'runtime',
'samples',
@ -58,13 +57,6 @@
'utils/dartanalyzer/dartanalyzer.gyp:dartanalyzer',
],
},
{
'target_name': 'dartdevc',
'type': 'none',
'dependencies': [
'utils/dartdevc/dartdevc.gyp:dartdevc',
],
},
{
'target_name': 'dartfmt',
'type': 'none',

View file

@ -1,86 +0,0 @@
#!/usr/bin/env bash
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
# Run dev compiler on the Dart VM. This script assumes the Dart repo's
# directory structure.
function follow_links() {
file="$1"
while [ -h "$file" ]; do
# On Mac OS, readlink -f doesn't work.
file="$(readlink "$file")"
done
echo "$file"
}
# Unlike $0, $BASH_SOURCE points to the absolute path of this file.
PROG_NAME="$(follow_links "$BASH_SOURCE")"
# Handle the case where dart-sdk/bin has been symlinked to.
BIN_DIR="$(cd "${PROG_NAME%/*}" ; pwd -P)"
SDK_DIR="$(cd "${BIN_DIR}/.." ; pwd -P)"
SDK_ARG="--dart-sdk=$SDK_DIR"
DART="$BIN_DIR/dart"
unset EXTRA_VM_OPTIONS
declare -a EXTRA_VM_OPTIONS
case $0 in
*_developer)
EXTRA_VM_OPTIONS+=('--checked')
;;
esac
# We allow extra vm options to be passed in through an environment variable.
if [[ $DART_VM_OPTIONS ]]; then
read -a OPTIONS <<< "$DART_VM_OPTIONS"
EXTRA_VM_OPTIONS+=("${OPTIONS[@]}")
fi
DART_ROOT="$(cd "${SDK_DIR}/.." ; pwd -P)"
DEV_COMPILER="$DART_ROOT/third_party/pkg/dev_compiler/bin/dartdevc.dart"
if [[ `uname` == 'Darwin' ]];
then
OUT_DIR="$DART_ROOT/xcodebuild/"
else
OUT_DIR="$DART_ROOT/out/"
fi
if [ -z "$DART_CONFIGURATION" ];
then
DIRS=$( ls "$OUT_DIR" )
# list of possible configurations in decreasing desirability
CONFIGS=("ReleaseX64" "ReleaseIA32" "DebugX64" "DebugIA32"
"ReleaseARM" "ReleaseARM64" "ReleaseARMV5TE" "ReleaseMIPS"
"DebugARM" "DebugARM64" "DebugARMV5TE" "DebugMIPS")
DART_CONFIGURATION="None"
for CONFIG in ${CONFIGS[*]}
do
for DIR in $DIRS;
do
if [ "$CONFIG" = "$DIR" ];
then
# choose most desirable configuration that is available and break
DART_CONFIGURATION="$DIR"
break 2
fi
done
done
if [ "$DART_CONFIGURATION" = "None" ]
then
echo "No valid dart configuration found in $OUT_DIR"
exit 1
fi
fi
BUILD_DIR="$OUT_DIR$DART_CONFIGURATION"
PACKAGE_ROOT="$BUILD_DIR/packages/"
exec "$DART" "${EXTRA_VM_OPTIONS[@]}" "--package-root=$PACKAGE_ROOT" "$DEV_COMPILER" "$SDK_ARG" "$@"

View file

@ -1,31 +0,0 @@
#!/usr/bin/env bash
# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
# Run dev compiler on the Dart VM. This script assumes the Dart SDK's
# directory structure.
function follow_links() {
file="$1"
while [ -h "$file" ]; do
# On Mac OS, readlink -f doesn't work.
file="$(readlink "$file")"
done
echo "$file"
}
# Unlike $0, $BASH_SOURCE points to the absolute path of this file.
PROG_NAME="$(follow_links "$BASH_SOURCE")"
# Handle the case where dart-sdk/bin has been symlinked to.
BIN_DIR="$(cd "${PROG_NAME%/*}" ; pwd -P)"
SDK_DIR="$(cd "${BIN_DIR}/.." ; pwd -P)"
SDK_ARG="--dart-sdk=$SDK_DIR"
SNAPSHOT="$BIN_DIR/snapshots/dartdevc.dart.snapshot"
# We are running the snapshot in the built SDK.
DART="$BIN_DIR/dart"
exec "$DART" "$SNAPSHOT" "$SDK_ARG" "$@"

View file

@ -19,7 +19,6 @@
# ......dartfmt
# ......dart2js
# ......dartanalyzer
# ......dartdevc
# ......pub
# ......snapshots/
# ........analysis_server.dart.snapshot
@ -27,7 +26,6 @@
# ........dartanalyzer.dart.snapshot
# ........dartdoc.dart.snapshot
# ........dartfmt.dart.snapshot
# ........dartdevc.dart.snapshot
# ........pub.dart.snapshot
# ........utils_wrapper.dart.snapshot
#.........resources/
@ -131,14 +129,14 @@ def CopyShellScript(src_file, dest_dir):
def CopyDartScripts(home, sdk_root):
for executable in ['dart2js_sdk', 'dartanalyzer_sdk', 'dartfmt_sdk',
'pub_sdk', 'dartdoc', 'dartdevc_sdk']:
'pub_sdk', 'dartdoc']:
CopyShellScript(os.path.join(home, 'sdk', 'bin', executable),
os.path.join(sdk_root, 'bin'))
def CopySnapshots(snapshots, sdk_root):
for snapshot in ['analysis_server', 'dart2js', 'dartanalyzer', 'dartfmt',
'utils_wrapper', 'pub', 'dartdoc', 'dartdevc']:
'utils_wrapper', 'pub', 'dartdoc']:
snapshot += '.dart.snapshot'
copyfile(join(snapshots, snapshot),
join(sdk_root, 'bin', 'snapshots', snapshot))

View file

@ -1,37 +0,0 @@
# Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
{
'targets': [
{
'target_name': 'dartdevc',
'type': 'none',
'dependencies': [
'../../runtime/dart-runtime.gyp:dart',
'../../pkg/pkg.gyp:pkg_packages',
],
'actions': [
{
'action_name': 'generate_dartdevc_snapshot',
'inputs': [
'<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)',
'../../sdk/lib/_internal/sdk_library_metadata/lib/libraries.dart',
'<(SHARED_INTERMEDIATE_DIR)/packages.stamp',
'<!@(["python", "../../tools/list_files.py", "\\.dart$", "../../third_party/pkg/dev_compiler"])',
'<!@(["python", "../../tools/list_files.py", "\\.dart$", "../../pkg/analyzer"])',
],
'outputs': [
'<(SHARED_INTERMEDIATE_DIR)/dartdevc.dart.snapshot',
],
'action': [
'<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)dart<(EXECUTABLE_SUFFIX)',
'--snapshot=<(SHARED_INTERMEDIATE_DIR)/dartdevc.dart.snapshot',
'--package-root=<(PRODUCT_DIR)/packages/',
'../../third_party/pkg/dev_compiler/bin/dartdevc.dart'
],
},
],
},
],
}