Skip to content

Commit bf43e5c

Browse files
myleshortonclaude
andauthored
macos: raise the deployment target to 11.0 to match what we actually ship (#9083)
MACOSX_DEPLOYMENT_TARGET said 10.15, but the app has not been able to launch there for as long as it has bundled Sparkle. From a release build of Lantern.app: Frameworks/Sparkle.framework minos 11.0 -- no 10.15 slice Frameworks/objective_c.framework minos 13.0 -- both slices MacOS/Lantern minos 10.15 (x86_64), 11.0 (arm64) and the main binary loads Sparkle with LC_LOAD_DYLIB, not LC_LOAD_WEAK_DYLIB, so on 10.15 dyld refuses to load it and the app never starts. The arm64 slice is 11.0 regardless, since arm64 macOS did not exist before 11.0. The declared target was describing a configuration that has never run. Saying 11.0 costs nothing that works today and stops the target from blocking APIs the app can already rely on. FileHandle's throwing read/write/truncate are 10.15.4+, so SystemExtensionManager had to branch on availability with a fallback using readData(ofLength:) -- which raises an ObjC exception Swift cannot catch and reports no error at all. That branch was unreachable on every machine that can run the app, so it is gone along with the guard. Also refreshes PODFILE CHECKSUM in macos/Podfile.lock, since editing the Podfile changed it. That line alone: it is the Podfile's SHA1, and regenerating the whole lockfile here would rewrite every SPEC CHECKSUM and bump the recorded CocoaPods version as unrelated churn. Verified with a full local build (make macos-unit-tests, TEST SUCCEEDED) after rebasing onto the native-logs changes, so the new logger test runs at the 11.0 target. The built binary reports minos 11.0, previously 10.15. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 37ee2ef commit bf43e5c

4 files changed

Lines changed: 18 additions & 28 deletions

File tree

‎macos/Podfile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
platform :osx, '10.15'
1+
platform :osx, '11.0'
22

33
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
44
ENV['COCOAPODS_DISABLE_STATS'] = 'true'

‎macos/Podfile.lock‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,6 @@ SPEC CHECKSUMS:
140140
url_launcher_macos: 175a54c831f4375a6cf895875f716ee5af3888ce
141141
window_manager: e25faf20d88283a0d46e7b1a759d07261ca27575
142142

143-
PODFILE CHECKSUM: b1a5a5e815560a377d8b3e64b4f3f97e2bd372ba
143+
PODFILE CHECKSUM: c03e34b37a3e49373f4e9410aa6cfcb98b720641
144144

145145
COCOAPODS: 1.16.2

‎macos/Runner.xcodeproj/project.pbxproj‎

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -782,7 +782,7 @@
782782
"@executable_path/../../../../Frameworks",
783783
);
784784
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
785-
MACOSX_DEPLOYMENT_TARGET = 10.15;
785+
MACOSX_DEPLOYMENT_TARGET = 11.0;
786786
MARKETING_VERSION = "$(FLUTTER_BUILD_NAME)";
787787
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
788788
MTL_FAST_MATH = YES;
@@ -835,7 +835,7 @@
835835
"@executable_path/../../../../Frameworks",
836836
);
837837
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
838-
MACOSX_DEPLOYMENT_TARGET = 10.15;
838+
MACOSX_DEPLOYMENT_TARGET = 11.0;
839839
MARKETING_VERSION = "$(FLUTTER_BUILD_NAME)";
840840
MTL_FAST_MATH = YES;
841841
OTHER_LDFLAGS = "-lc++";
@@ -885,7 +885,7 @@
885885
"@executable_path/../../../../Frameworks",
886886
);
887887
LOCALIZATION_PREFERS_STRING_CATALOGS = YES;
888-
MACOSX_DEPLOYMENT_TARGET = 10.15;
888+
MACOSX_DEPLOYMENT_TARGET = 11.0;
889889
MARKETING_VERSION = "$(FLUTTER_BUILD_NAME)";
890890
MTL_FAST_MATH = YES;
891891
OTHER_LDFLAGS = "-lc++";
@@ -907,7 +907,7 @@
907907
BUNDLE_LOADER = "$(TEST_HOST)";
908908
CURRENT_PROJECT_VERSION = 1;
909909
GENERATE_INFOPLIST_FILE = YES;
910-
MACOSX_DEPLOYMENT_TARGET = 10.15;
910+
MACOSX_DEPLOYMENT_TARGET = 11.0;
911911
MARKETING_VERSION = 1.0;
912912
PRODUCT_BUNDLE_IDENTIFIER = org.getlantern.lantern.RunnerTests;
913913
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -923,7 +923,7 @@
923923
BUNDLE_LOADER = "$(TEST_HOST)";
924924
CURRENT_PROJECT_VERSION = 1;
925925
GENERATE_INFOPLIST_FILE = YES;
926-
MACOSX_DEPLOYMENT_TARGET = 10.15;
926+
MACOSX_DEPLOYMENT_TARGET = 11.0;
927927
MARKETING_VERSION = 1.0;
928928
PRODUCT_BUNDLE_IDENTIFIER = org.getlantern.lantern.RunnerTests;
929929
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -939,7 +939,7 @@
939939
BUNDLE_LOADER = "$(TEST_HOST)";
940940
CURRENT_PROJECT_VERSION = 1;
941941
GENERATE_INFOPLIST_FILE = YES;
942-
MACOSX_DEPLOYMENT_TARGET = 10.15;
942+
MACOSX_DEPLOYMENT_TARGET = 11.0;
943943
MARKETING_VERSION = 1.0;
944944
PRODUCT_BUNDLE_IDENTIFIER = org.getlantern.lantern.RunnerTests;
945945
PRODUCT_NAME = "$(TARGET_NAME)";
@@ -989,7 +989,7 @@
989989
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
990990
GCC_WARN_UNUSED_FUNCTION = YES;
991991
GCC_WARN_UNUSED_VARIABLE = YES;
992-
MACOSX_DEPLOYMENT_TARGET = 10.15;
992+
MACOSX_DEPLOYMENT_TARGET = 11.0;
993993
MTL_ENABLE_DEBUG_INFO = NO;
994994
SDKROOT = macosx;
995995
SWIFT_COMPILATION_MODE = wholemodule;
@@ -1021,7 +1021,7 @@
10211021
"$(inherited)",
10221022
"$(PROJECT_DIR)/Frameworks",
10231023
);
1024-
MACOSX_DEPLOYMENT_TARGET = 10.15;
1024+
MACOSX_DEPLOYMENT_TARGET = 11.0;
10251025
PROVISIONING_PROFILE_SPECIFIER = "";
10261026
"PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = "Macos Development Profile";
10271027
REGISTER_APP_GROUPS = YES;
@@ -1085,7 +1085,7 @@
10851085
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
10861086
GCC_WARN_UNUSED_FUNCTION = YES;
10871087
GCC_WARN_UNUSED_VARIABLE = YES;
1088-
MACOSX_DEPLOYMENT_TARGET = 10.15;
1088+
MACOSX_DEPLOYMENT_TARGET = 11.0;
10891089
MTL_ENABLE_DEBUG_INFO = YES;
10901090
ONLY_ACTIVE_ARCH = YES;
10911091
SDKROOT = macosx;
@@ -1135,7 +1135,7 @@
11351135
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
11361136
GCC_WARN_UNUSED_FUNCTION = YES;
11371137
GCC_WARN_UNUSED_VARIABLE = YES;
1138-
MACOSX_DEPLOYMENT_TARGET = 10.15;
1138+
MACOSX_DEPLOYMENT_TARGET = 11.0;
11391139
MTL_ENABLE_DEBUG_INFO = NO;
11401140
SDKROOT = macosx;
11411141
SWIFT_COMPILATION_MODE = wholemodule;
@@ -1168,7 +1168,7 @@
11681168
"$(inherited)",
11691169
"$(PROJECT_DIR)/Frameworks",
11701170
);
1171-
MACOSX_DEPLOYMENT_TARGET = 10.15;
1171+
MACOSX_DEPLOYMENT_TARGET = 11.0;
11721172
PROVISIONING_PROFILE_SPECIFIER = "";
11731173
"PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = "Macos Development Profile";
11741174
REGISTER_APP_GROUPS = YES;
@@ -1202,7 +1202,7 @@
12021202
"$(inherited)",
12031203
"$(PROJECT_DIR)/Frameworks",
12041204
);
1205-
MACOSX_DEPLOYMENT_TARGET = 10.15;
1205+
MACOSX_DEPLOYMENT_TARGET = 11.0;
12061206
PROVISIONING_PROFILE_SPECIFIER = "";
12071207
"PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = "Macos Development Profile";
12081208
REGISTER_APP_GROUPS = YES;

‎macos/Runner/VPN/SystemExtensionManager.swift‎

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1041,22 +1041,12 @@ internal enum SystemExtensionBundleHasher {
10411041
hasher.update(data: Data(relativePath.utf8))
10421042
hasher.update(data: Data([0]))
10431043

1044-
if #available(macOS 10.15.4, *) {
1045-
do {
1046-
while let chunk = try fileHandle.read(upToCount: readChunkSize), !chunk.isEmpty {
1047-
hasher.update(data: chunk)
1048-
}
1049-
} catch {
1050-
return false
1051-
}
1052-
} else {
1053-
while true {
1054-
let chunk = fileHandle.readData(ofLength: readChunkSize)
1055-
if chunk.isEmpty {
1056-
break
1057-
}
1044+
do {
1045+
while let chunk = try fileHandle.read(upToCount: readChunkSize), !chunk.isEmpty {
10581046
hasher.update(data: chunk)
10591047
}
1048+
} catch {
1049+
return false
10601050
}
10611051

10621052
hasher.update(data: Data([0]))

0 commit comments

Comments
 (0)