Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
bedf987f
Unverified
Commit
bedf987f
authored
Jan 11, 2018
by
Alexander Aprelev
Committed by
GitHub
Jan 11, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pipe strong mode option for iOS simulator. (#14002)
parent
99176578
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
5 deletions
+19
-5
xcode_backend.sh
packages/flutter_tools/bin/xcode_backend.sh
+8
-1
compile.dart
packages/flutter_tools/lib/src/compile.dart
+9
-3
resident_runner.dart
packages/flutter_tools/lib/src/resident_runner.dart
+2
-1
No files found.
packages/flutter_tools/bin/xcode_backend.sh
View file @
bedf987f
...
@@ -93,6 +93,11 @@ BuildApp() {
...
@@ -93,6 +93,11 @@ BuildApp() {
preview_dart_2_flag
=
"--preview-dart-2"
preview_dart_2_flag
=
"--preview-dart-2"
fi
fi
local
strong_flag
=
""
if
[[
-n
"
$STRONG
"
]]
;
then
strong_flag
=
"--strong"
fi
if
[[
"
$CURRENT_ARCH
"
!=
"x86_64"
]]
;
then
if
[[
"
$CURRENT_ARCH
"
!=
"x86_64"
]]
;
then
local
aot_flags
=
""
local
aot_flags
=
""
if
[[
"
$build_mode
"
==
"debug"
]]
;
then
if
[[
"
$build_mode
"
==
"debug"
]]
;
then
...
@@ -107,7 +112,8 @@ BuildApp() {
...
@@ -107,7 +112,8 @@ BuildApp() {
--target
=
"
${
target_path
}
"
\
--target
=
"
${
target_path
}
"
\
${
aot_flags
}
\
${
aot_flags
}
\
${
local_engine_flag
}
\
${
local_engine_flag
}
\
${
preview_dart_2_flag
}
${
preview_dart_2_flag
}
\
${
strong_flag
}
\
if
[[
$?
-ne
0
]]
;
then
if
[[
$?
-ne
0
]]
;
then
EchoError
"Failed to build
${
project_path
}
."
EchoError
"Failed to build
${
project_path
}
."
...
@@ -140,6 +146,7 @@ BuildApp() {
...
@@ -140,6 +146,7 @@ BuildApp() {
${
precompilation_flag
}
\
${
precompilation_flag
}
\
${
local_engine_flag
}
\
${
local_engine_flag
}
\
${
preview_dart_2_flag
}
\
${
preview_dart_2_flag
}
\
${
strong_flag
}
\
if
[[
$?
-ne
0
]]
;
then
if
[[
$?
-ne
0
]]
;
then
EchoError
"Failed to package
${
project_path
}
."
EchoError
"Failed to package
${
project_path
}
."
...
...
packages/flutter_tools/lib/src/compile.dart
View file @
bedf987f
...
@@ -120,14 +120,16 @@ Future<String> compile(
...
@@ -120,14 +120,16 @@ Future<String> compile(
/// The wrapper is intended to stay resident in memory as user changes, reloads,
/// The wrapper is intended to stay resident in memory as user changes, reloads,
/// restarts the Flutter app.
/// restarts the Flutter app.
class
ResidentCompiler
{
class
ResidentCompiler
{
ResidentCompiler
(
this
.
_sdkRoot
)
ResidentCompiler
(
this
.
_sdkRoot
,
{
bool
strongMode:
false
}
)
:
assert
(
_sdkRoot
!=
null
)
{
:
assert
(
_sdkRoot
!=
null
)
{
// This is a URI, not a file path, so the forward slash is correct even on Windows.
// This is a URI, not a file path, so the forward slash is correct even on Windows.
if
(!
_sdkRoot
.
endsWith
(
'/'
))
if
(!
_sdkRoot
.
endsWith
(
'/'
))
_sdkRoot
=
'
$_sdkRoot
/'
;
_sdkRoot
=
'
$_sdkRoot
/'
;
_strongMode
=
strongMode
;
}
}
String
_sdkRoot
;
String
_sdkRoot
;
bool
_strongMode
;
Process
_server
;
Process
_server
;
final
_StdoutHandler
stdoutHandler
=
new
_StdoutHandler
();
final
_StdoutHandler
stdoutHandler
=
new
_StdoutHandler
();
...
@@ -157,13 +159,17 @@ class ResidentCompiler {
...
@@ -157,13 +159,17 @@ class ResidentCompiler {
final
String
frontendServer
=
artifacts
.
getArtifactPath
(
final
String
frontendServer
=
artifacts
.
getArtifactPath
(
Artifact
.
frontendServerSnapshotForEngineDartSdk
Artifact
.
frontendServerSnapshotForEngineDartSdk
);
);
_server
=
await
processManager
.
start
(
<
String
>[
final
List
<
String
>
args
=
<
String
>[
_dartExecutable
(),
_dartExecutable
(),
frontendServer
,
frontendServer
,
'--sdk-root'
,
'--sdk-root'
,
_sdkRoot
,
_sdkRoot
,
'--incremental'
'--incremental'
]);
];
if
(
_strongMode
)
{
args
.
add
(
'--strong'
);
}
_server
=
await
processManager
.
start
(
args
);
_server
.
stdout
_server
.
stdout
.
transform
(
UTF8
.
decoder
)
.
transform
(
UTF8
.
decoder
)
.
transform
(
const
LineSplitter
())
.
transform
(
const
LineSplitter
())
...
...
packages/flutter_tools/lib/src/resident_runner.dart
View file @
bedf987f
...
@@ -42,7 +42,8 @@ class FlutterDevice {
...
@@ -42,7 +42,8 @@ class FlutterDevice {
{
bool
previewDart2
:
false
,
bool
strongMode
:
false
})
{
{
bool
previewDart2
:
false
,
bool
strongMode
:
false
})
{
if
(
previewDart2
)
if
(
previewDart2
)
generator
=
new
ResidentCompiler
(
generator
=
new
ResidentCompiler
(
artifacts
.
getArtifactPath
(
Artifact
.
flutterPatchedSdkPath
));
artifacts
.
getArtifactPath
(
Artifact
.
flutterPatchedSdkPath
),
strongMode:
strongMode
);
}
}
String
viewFilter
;
String
viewFilter
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment