Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit a6fe7ef

Browse files
vsmenonJonah Williams
authored andcommitted
Enable/tweak web sdk source maps, take 2 (#13161)
Update outline step to remove absolute paths here as well. See: https://dart-review.googlesource.com/c/sdk/+/122178/5/utils/dartdevc/BUILD.gn
1 parent ae0110d commit a6fe7ef

File tree

3 files changed

+98
-95
lines changed

3 files changed

+98
-95
lines changed

web_sdk/BUILD.gn

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ copy("web_ui_library") {
9898
# Compile the DDC SDK's summary.
9999
prebuilt_dart_action("flutter_dartdevc_kernel_sdk_outline") {
100100
deps = [
101+
"//third_party/dart:create_sdk",
101102
"//third_party/dart/pkg:pkg_files_stamp",
102103
"//third_party/dart/utils/dartdevc:dartdevc_files_stamp",
103104
"//third_party/dart/utils/dartdevc:dartdevc_sdk_patch_stamp",
@@ -120,9 +121,9 @@ prebuilt_dart_action("flutter_dartdevc_kernel_sdk_outline") {
120121
"--multi-root-scheme",
121122
"org-dartlang-sdk",
122123
"--multi-root",
123-
rebase_path("../../"),
124+
"file:///" + rebase_path("$root_out_dir"),
124125
"--libraries-file",
125-
"file:///" + rebase_path("$root_out_dir/flutter_web_sdk/libraries.json"),
126+
"org-dartlang-sdk:///flutter_web_sdk/libraries.json",
126127
"--output",
127128
rebase_path(sdk_dill),
128129
"--source",
@@ -139,6 +140,7 @@ prebuilt_dart_action("flutter_dartdevc_kernel_sdk_outline") {
139140
# Compiles the DDC SDK's JS code.
140141
prebuilt_dart_action("flutter_dartdevc_kernel_sdk") {
141142
deps = [
143+
"//third_party/dart:create_sdk",
142144
"//third_party/dart/pkg:pkg_files_stamp",
143145
"//third_party/dart/utils/dartdevc:dartdevc_files_stamp",
144146
"//third_party/dart/utils/dartdevc:dartdevc_sdk_patch_stamp",
@@ -169,11 +171,12 @@ prebuilt_dart_action("flutter_dartdevc_kernel_sdk") {
169171
"--multi-root-scheme",
170172
"org-dartlang-sdk",
171173
"--multi-root",
172-
rebase_path("../../"),
174+
"file:///" + rebase_path("$root_out_dir"),
173175
"--multi-root-output-path",
174176
rebase_path("$root_out_dir/"),
175177
"--libraries-file",
176-
"file:///" + rebase_path("$root_out_dir/flutter_web_sdk/libraries.json"),
178+
"org-dartlang-sdk:///flutter_web_sdk/libraries.json",
179+
"--inline-source-map",
177180
"--modules",
178181
"amd",
179182
"-o",

web_sdk/libraries.json

Lines changed: 48 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,6 @@
4848
"ui": {
4949
"uri": "lib/ui/ui.dart"
5050
},
51-
"_engine": {
52-
"uri": "lib/_engine/engine.dart"
53-
},
5451
"js": {
5552
"uri": "../dart-sdk/lib/js/dart2js/js_dart2js.dart"
5653
},
@@ -116,123 +113,126 @@
116113
},
117114
"svg": {
118115
"uri": "../dart-sdk/lib/svg/dart2js/svg_dart2js.dart"
116+
},
117+
"_engine": {
118+
"uri": "lib/_engine/engine.dart"
119119
}
120120
}
121121
},
122122
"dartdevc": {
123123
"libraries": {
124124
"async": {
125-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart",
126-
"uri": "../../../third_party/dart/sdk/lib/async/async.dart"
125+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart",
126+
"uri": "../dart-sdk/lib/async/async.dart"
127127
},
128128
"_runtime": {
129-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/runtime.dart"
129+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/runtime.dart"
130130
},
131131
"_interceptors": {
132-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/interceptors.dart"
132+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/interceptors.dart"
133133
},
134134
"mirrors": {
135-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/mirrors_patch.dart",
135+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/mirrors_patch.dart",
136136
"supported": false,
137-
"uri": "../../../third_party/dart/sdk/lib/mirrors/mirrors.dart"
137+
"uri": "../dart-sdk/lib/mirrors/mirrors.dart"
138138
},
139139
"_debugger": {
140-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/debugger.dart"
140+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/debugger.dart"
141141
},
142142
"io": {
143-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/io_patch.dart",
143+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/io_patch.dart",
144144
"supported": false,
145-
"uri": "../../../third_party/dart/sdk/lib/io/io.dart"
145+
"uri": "../dart-sdk/lib/io/io.dart"
146146
},
147147
"_internal": {
148-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart",
149-
"uri": "../../../third_party/dart/sdk/lib/internal/internal.dart"
148+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart",
149+
"uri": "../dart-sdk/lib/internal/internal.dart"
150150
},
151151
"_metadata": {
152-
"uri": "../../../third_party/dart/sdk/lib/html/html_common/metadata.dart"
152+
"uri": "../dart-sdk/lib/html/html_common/metadata.dart"
153153
},
154154
"_http": {
155-
"uri": "../../../third_party/dart/sdk/lib/_http/http.dart"
155+
"uri": "../dart-sdk/lib/_http/http.dart"
156156
},
157157
"_js_primitives": {
158-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_primitives.dart"
158+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/js_primitives.dart"
159159
},
160160
"_js_helper": {
161-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_helper.dart"
161+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/js_helper.dart"
162162
},
163163
"ui": {
164164
"uri": "lib/ui/ui.dart"
165165
},
166-
"_engine": {
167-
"uri": "lib/_engine/engine.dart"
168-
},
169166
"js": {
170-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/lib/js/dart2js/js_dart2js.dart"
167+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/lib/js/dart2js/js_dart2js.dart"
171168
},
172169
"_js_mirrors": {
173-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_mirrors.dart"
170+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/js_mirrors.dart"
174171
},
175172
"html_common": {
176-
"uri": "../../../third_party/dart/sdk/lib/html/html_common/html_common_dart2js.dart"
173+
"uri": "../dart-sdk/lib/html/html_common/html_common_dart2js.dart"
177174
},
178175
"_native_typed_data": {
179-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/native_typed_data.dart"
176+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/native_typed_data.dart"
180177
},
181178
"core": {
182-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/core_patch.dart",
183-
"uri": "../../../third_party/dart/sdk/lib/core/core.dart"
179+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/core_patch.dart",
180+
"uri": "../dart-sdk/lib/core/core.dart"
184181
},
185182
"js_util": {
186-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/lib/js_util/dart2js/js_util_dart2js.dart"
183+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/lib/js_util/dart2js/js_util_dart2js.dart"
187184
},
188185
"collection": {
189-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/collection_patch.dart",
190-
"uri": "../../../third_party/dart/sdk/lib/collection/collection.dart"
186+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/collection_patch.dart",
187+
"uri": "../dart-sdk/lib/collection/collection.dart"
191188
},
192189
"typed_data": {
193-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/typed_data_patch.dart",
194-
"uri": "../../../third_party/dart/sdk/lib/typed_data/typed_data.dart"
190+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/typed_data_patch.dart",
191+
"uri": "../dart-sdk/lib/typed_data/typed_data.dart"
195192
},
196193
"web_audio": {
197-
"uri": "../../../third_party/dart/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart"
194+
"uri": "../dart-sdk/lib/web_audio/dart2js/web_audio_dart2js.dart"
198195
},
199196
"html": {
200-
"uri": "../../../third_party/dart/sdk/lib/html/dart2js/html_dart2js.dart"
197+
"uri": "../dart-sdk/lib/html/dart2js/html_dart2js.dart"
201198
},
202199
"developer": {
203-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/developer_patch.dart",
204-
"uri": "../../../third_party/dart/sdk/lib/developer/developer.dart"
200+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/developer_patch.dart",
201+
"uri": "../dart-sdk/lib/developer/developer.dart"
205202
},
206203
"isolate": {
207-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/isolate_patch.dart",
204+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/isolate_patch.dart",
208205
"supported": false,
209-
"uri": "../../../third_party/dart/sdk/lib/isolate/isolate.dart"
206+
"uri": "../dart-sdk/lib/isolate/isolate.dart"
210207
},
211208
"web_gl": {
212-
"uri": "../../../third_party/dart/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart"
209+
"uri": "../dart-sdk/lib/web_gl/dart2js/web_gl_dart2js.dart"
213210
},
214211
"indexed_db": {
215-
"uri": "../../../third_party/dart/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart"
212+
"uri": "../dart-sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart"
216213
},
217214
"convert": {
218-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/convert_patch.dart",
219-
"uri": "../../../third_party/dart/sdk/lib/convert/convert.dart"
215+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/convert_patch.dart",
216+
"uri": "../dart-sdk/lib/convert/convert.dart"
220217
},
221218
"_isolate_helper": {
222-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/isolate_helper.dart"
219+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/isolate_helper.dart"
223220
},
224221
"math": {
225-
"patches": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/math_patch.dart",
226-
"uri": "../../../third_party/dart/sdk/lib/math/math.dart"
222+
"patches": "../dart-sdk/lib/_internal/js_dev_runtime/patch/math_patch.dart",
223+
"uri": "../dart-sdk/lib/math/math.dart"
227224
},
228225
"_foreign_helper": {
229-
"uri": "../../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/foreign_helper.dart"
226+
"uri": "../dart-sdk/lib/_internal/js_dev_runtime/private/foreign_helper.dart"
230227
},
231228
"web_sql": {
232-
"uri": "../../../third_party/dart/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart"
229+
"uri": "../dart-sdk/lib/web_sql/dart2js/web_sql_dart2js.dart"
233230
},
234231
"svg": {
235-
"uri": "../../../third_party/dart/sdk/lib/svg/dart2js/svg_dart2js.dart"
232+
"uri": "../dart-sdk/lib/svg/dart2js/svg_dart2js.dart"
233+
},
234+
"_engine": {
235+
"uri": "lib/_engine/engine.dart"
236236
}
237237
}
238238
}

web_sdk/libraries.yaml

Lines changed: 43 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -16,116 +16,116 @@
1616
dartdevc:
1717
libraries:
1818
_runtime:
19-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/runtime.dart"
19+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/runtime.dart"
2020

2121
_debugger:
22-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/debugger.dart"
22+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/debugger.dart"
2323

2424
_foreign_helper:
25-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/foreign_helper.dart"
25+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/foreign_helper.dart"
2626

2727
_http:
28-
uri: "../../third_party/dart/sdk/lib/_http/http.dart"
28+
uri: "../dart-sdk/lib/_http/http.dart"
2929

3030
_interceptors:
31-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/interceptors.dart"
31+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/interceptors.dart"
3232

3333
_internal:
34-
uri: "../../third_party/dart/sdk/lib/internal/internal.dart"
35-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart"
34+
uri: "../dart-sdk/lib/internal/internal.dart"
35+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart"
3636

3737
_isolate_helper:
38-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/isolate_helper.dart"
38+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/isolate_helper.dart"
3939

4040
_js_helper:
41-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_helper.dart"
41+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/js_helper.dart"
4242

4343
_js_mirrors:
44-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_mirrors.dart"
44+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/js_mirrors.dart"
4545

4646
_js_primitives:
47-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/js_primitives.dart"
47+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/js_primitives.dart"
4848

4949
_metadata:
50-
uri: "../../third_party/dart/sdk/lib/html/html_common/metadata.dart"
50+
uri: "../dart-sdk/lib/html/html_common/metadata.dart"
5151

5252
_native_typed_data:
53-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/private/native_typed_data.dart"
53+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/private/native_typed_data.dart"
5454

5555
async:
56-
uri: "../../third_party/dart/sdk/lib/async/async.dart"
57-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart"
56+
uri: "../dart-sdk/lib/async/async.dart"
57+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart"
5858

5959
collection:
60-
uri: "../../third_party/dart/sdk/lib/collection/collection.dart"
61-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/collection_patch.dart"
60+
uri: "../dart-sdk/lib/collection/collection.dart"
61+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/collection_patch.dart"
6262

6363
convert:
64-
uri: "../../third_party/dart/sdk/lib/convert/convert.dart"
65-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/convert_patch.dart"
64+
uri: "../dart-sdk/lib/convert/convert.dart"
65+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/convert_patch.dart"
6666

6767
core:
68-
uri: "../../third_party/dart/sdk/lib/core/core.dart"
69-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/core_patch.dart"
68+
uri: "../dart-sdk/lib/core/core.dart"
69+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/core_patch.dart"
7070

7171
developer:
72-
uri: "../../third_party/dart/sdk/lib/developer/developer.dart"
73-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/developer_patch.dart"
72+
uri: "../dart-sdk/lib/developer/developer.dart"
73+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/developer_patch.dart"
7474

7575
io:
76-
uri: "../../third_party/dart/sdk/lib/io/io.dart"
77-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/io_patch.dart"
76+
uri: "../dart-sdk/lib/io/io.dart"
77+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/io_patch.dart"
7878
supported: false
7979

8080
isolate:
81-
uri: "../../third_party/dart/sdk/lib/isolate/isolate.dart"
82-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/isolate_patch.dart"
81+
uri: "../dart-sdk/lib/isolate/isolate.dart"
82+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/isolate_patch.dart"
8383
supported: false
8484

8585
mirrors:
86-
uri: "../../third_party/dart/sdk/lib/mirrors/mirrors.dart"
87-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/mirrors_patch.dart"
86+
uri: "../dart-sdk/lib/mirrors/mirrors.dart"
87+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/mirrors_patch.dart"
8888
supported: false
8989

9090
math:
91-
uri: "../../third_party/dart/sdk/lib/math/math.dart"
92-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/math_patch.dart"
91+
uri: "../dart-sdk/lib/math/math.dart"
92+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/math_patch.dart"
9393

9494
typed_data:
95-
uri: "../../third_party/dart/sdk/lib/typed_data/typed_data.dart"
96-
patches: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/patch/typed_data_patch.dart"
95+
uri: "../dart-sdk/lib/typed_data/typed_data.dart"
96+
patches: "../dart-sdk/lib/_internal/js_dev_runtime/patch/typed_data_patch.dart"
9797

9898
html:
99-
uri: "../../third_party/dart/sdk/lib/html/dart2js/html_dart2js.dart"
99+
uri: "../dart-sdk/lib/html/dart2js/html_dart2js.dart"
100100

101101
html_common:
102-
uri: "../../third_party/dart/sdk/lib/html/html_common/html_common_dart2js.dart"
102+
uri: "../dart-sdk/lib/html/html_common/html_common_dart2js.dart"
103103

104104
indexed_db:
105-
uri: "../../third_party/dart/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart"
105+
uri: "../dart-sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart"
106106

107107
js:
108-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/lib/js/dart2js/js_dart2js.dart"
108+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/lib/js/dart2js/js_dart2js.dart"
109109

110110
js_util:
111-
uri: "../../third_party/dart/sdk/lib/_internal/js_dev_runtime/lib/js_util/dart2js/js_util_dart2js.dart"
111+
uri: "../dart-sdk/lib/_internal/js_dev_runtime/lib/js_util/dart2js/js_util_dart2js.dart"
112112

113113
svg:
114-
uri: "../../third_party/dart/sdk/lib/svg/dart2js/svg_dart2js.dart"
114+
uri: "../dart-sdk/lib/svg/dart2js/svg_dart2js.dart"
115115

116116
web_audio:
117-
uri: "../../third_party/dart/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart"
117+
uri: "../dart-sdk/lib/web_audio/dart2js/web_audio_dart2js.dart"
118118

119119
web_gl:
120-
uri: "../../third_party/dart/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart"
120+
uri: "../dart-sdk/lib/web_gl/dart2js/web_gl_dart2js.dart"
121121

122122
web_sql:
123-
uri: "../../third_party/dart/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart"
123+
uri: "../dart-sdk/lib/web_sql/dart2js/web_sql_dart2js.dart"
124124

125125
ui:
126126
uri: "lib/ui/ui.dart"
127127

128-
_engine:
128+
_engine:
129129
uri: "lib/_engine/engine.dart"
130130

131131
dart2js:

0 commit comments

Comments
 (0)