Skip to content

Commit 3186cb3

Browse files
authored
chore: upgrade flutter to 3.29.0 (#381)
* chore: upgrade flutter to 3.29.0 * chore: upgrade macos project * chore: fix cloning flutter repo * chore: spelling * chore: drop unsupported web renderer option
1 parent e245b84 commit 3186cb3

File tree

16 files changed

+275
-49
lines changed

16 files changed

+275
-49
lines changed

.config/dictionaries/project.dic

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,11 @@ ldflags
6060
libasound
6161
libatk
6262
libatspi
63-
libsqlite
6463
libdrm
6564
libgbm
6665
libgcc
6766
libnss
67+
libsqlite
6868
libxkbcommon
6969
libxshmfence
7070
lintfix
@@ -119,6 +119,7 @@ transpiling
119119
UDCs
120120
unarchiving
121121
uniseg
122+
unshallow
122123
voteplan
123124
wasi
124125
wasmtime

earthly/flutter/Earthfile

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,23 @@ IMPORT ./installer AS installer
88
# Install flutter.
99
INSTALL_FLUTTER:
1010
FUNCTION
11-
ARG version=3.27.3
11+
ARG version=3.29.0
1212
ARG TARGETARCH
1313

1414
# Install Flutter
1515
IF [ "$TARGETARCH" = "amd64" ]
1616
RUN wget -qO - https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_$version-stable.tar.xz \
1717
| tar -xJ -C /usr/local
1818
ELSE IF [ "$TARGETARCH" = "arm64" ]
19-
GIT CLONE --branch $version https://github.com/flutter/flutter.git /usr/local
19+
# Restore below line when https://github.com/flutter/flutter/issues/162251 is solved.
20+
# GIT CLONE --branch $version https://github.com/flutter/flutter.git /usr/local/flutter
21+
22+
# And remove below lines to the end of this ELSE-IF block:
23+
GIT CLONE https://github.com/flutter/flutter.git /usr/local/flutter
24+
WORKDIR /usr/local/flutter
25+
RUN git fetch --unshallow
26+
RUN git checkout tags/$version
27+
WORKDIR /
2028
ELSE
2129
RUN echo >&2 "unsupported architecture: ${TARGETARCH}"; exit 1
2230
END
@@ -202,7 +210,7 @@ BUILD_WEB:
202210
WORKDIR $WORKDIR
203211
RUN flutter clean
204212
RUN flutter pub get
205-
RUN flutter build web --web-renderer canvaskit $BUILD_MODE --target $TARGET --dart-define SENTRY_DSN=$SENTRY_DSN
213+
RUN flutter build web $BUILD_MODE --target $TARGET --dart-define SENTRY_DSN=$SENTRY_DSN
206214

207215
WORKDIR "$WORKDIR/build"
208216
IF [ $SAVE_LOCALLY = true ]

examples/flutter/example/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,11 @@
55
*.swp
66
.DS_Store
77
.atom/
8+
.build/
89
.buildlog/
910
.history
1011
.svn/
12+
.swiftpm/
1113
migrate_working_dir/
1214

1315
# IntelliJ related
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
12
#include "Generated.xcconfig"
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
12
#include "Generated.xcconfig"

examples/flutter/example/ios/Podfile

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# Uncomment this line to define a global platform for your project
2+
# platform :ios, '12.0'
3+
4+
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
5+
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
6+
7+
project 'Runner', {
8+
'Debug' => :debug,
9+
'Profile' => :release,
10+
'Release' => :release,
11+
}
12+
13+
def flutter_root
14+
generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
15+
unless File.exist?(generated_xcode_build_settings_path)
16+
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
17+
end
18+
19+
File.foreach(generated_xcode_build_settings_path) do |line|
20+
matches = line.match(/FLUTTER_ROOT\=(.*)/)
21+
return matches[1].strip if matches
22+
end
23+
raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
24+
end
25+
26+
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
27+
28+
flutter_ios_podfile_setup
29+
30+
target 'Runner' do
31+
use_frameworks!
32+
33+
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
34+
target 'RunnerTests' do
35+
inherit! :search_paths
36+
end
37+
end
38+
39+
post_install do |installer|
40+
installer.pods_project.targets.each do |target|
41+
flutter_additional_ios_build_settings(target)
42+
end
43+
end
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
12
#include "ephemeral/Flutter-Generated.xcconfig"
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
#include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
12
#include "ephemeral/Flutter-Generated.xcconfig"
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
platform :osx, '10.14'
2+
3+
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
4+
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
5+
6+
project 'Runner', {
7+
'Debug' => :debug,
8+
'Profile' => :release,
9+
'Release' => :release,
10+
}
11+
12+
def flutter_root
13+
generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__)
14+
unless File.exist?(generated_xcode_build_settings_path)
15+
raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first"
16+
end
17+
18+
File.foreach(generated_xcode_build_settings_path) do |line|
19+
matches = line.match(/FLUTTER_ROOT\=(.*)/)
20+
return matches[1].strip if matches
21+
end
22+
raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\""
23+
end
24+
25+
require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
26+
27+
flutter_macos_podfile_setup
28+
29+
target 'Runner' do
30+
use_frameworks!
31+
32+
flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__))
33+
target 'RunnerTests' do
34+
inherit! :search_paths
35+
end
36+
end
37+
38+
post_install do |installer|
39+
installer.pods_project.targets.each do |target|
40+
flutter_additional_macos_build_settings(target)
41+
end
42+
end
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
PODS:
2+
- FlutterMacOS (1.0.0)
3+
- rust_lib_example (0.0.1):
4+
- FlutterMacOS
5+
6+
DEPENDENCIES:
7+
- FlutterMacOS (from `Flutter/ephemeral`)
8+
- rust_lib_example (from `Flutter/ephemeral/.symlinks/plugins/rust_lib_example/macos`)
9+
10+
EXTERNAL SOURCES:
11+
FlutterMacOS:
12+
:path: Flutter/ephemeral
13+
rust_lib_example:
14+
:path: Flutter/ephemeral/.symlinks/plugins/rust_lib_example/macos
15+
16+
SPEC CHECKSUMS:
17+
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24
18+
rust_lib_example: 3755c4211cbbe6e747b8900a36f354d634e660b3
19+
20+
PODFILE CHECKSUM: 7eb978b976557c8c1cd717d8185ec483fd090a82
21+
22+
COCOAPODS: 1.16.2

0 commit comments

Comments
 (0)