Skip to content

Commit

Permalink
DevL fix patches for Swift 6.0
Browse files Browse the repository at this point in the history
  • Loading branch information
andriydruk committed Jun 4, 2024
1 parent 12585f1 commit bb452d1
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 20 deletions.
7 changes: 3 additions & 4 deletions build/Linux/002-install-ndk.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

cd $HOME

for version in 25c
for version in 26c
do
ndk=android-ndk-r$version
ndk_zip=$ndk-linux.zip
Expand All @@ -14,6 +14,5 @@ do
done

# exports
echo "export ANDROID_NDK25=\$HOME/android-ndk-r25c" >> .build_env
echo "export ANDROID_NDK=\$ANDROID_NDK25" >> .build_env
echo "export ANDROID_NDK_HOME=\$ANDROID_NDK25" >> .build_env
echo "export ANDROID_NDK=\$HOME/android-ndk-r26c" >> .build_env
echo "export ANDROID_NDK_HOME=\$ANDROID_NDK" >> .build_env
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
diff --git a/include/swift/Basic/LangOptions.h b/include/swift/Basic/LangOptions.h
index e48e8891b39..719dfeb9c79 100644
index 1401f7324fd..6700ed5aaee 100644
--- a/include/swift/Basic/LangOptions.h
+++ b/include/swift/Basic/LangOptions.h
@@ -342,6 +342,11 @@ namespace swift {
@@ -352,6 +352,11 @@ namespace swift {
/// was not compiled with -enable-testing.
bool EnableTestableAttrRequiresTestableModule = true;

Expand All @@ -15,7 +15,7 @@ index e48e8891b39..719dfeb9c79 100644
/// Flags for developers
///
diff --git a/include/swift/Option/FrontendOptions.td b/include/swift/Option/FrontendOptions.td
index 60213f1f2a5..07bb4f9bbd8 100644
index af94cecfd66..ff22ef602ea 100644
--- a/include/swift/Option/FrontendOptions.td
+++ b/include/swift/Option/FrontendOptions.td
@@ -157,6 +157,11 @@ def verify_generic_signatures : Separate<["-"], "verify-generic-signatures">,
Expand All @@ -31,10 +31,10 @@ index 60213f1f2a5..07bb4f9bbd8 100644
HelpText<"Automatically import declared cross-import overlays.">;
def disable_cross_import_overlays : Flag<["-"], "disable-cross-import-overlays">,
diff --git a/lib/Driver/ToolChains.cpp b/lib/Driver/ToolChains.cpp
index 8c3b3d0e1d0..a39fac0334d 100644
index a945f376fa3..ed49ed28200 100644
--- a/lib/Driver/ToolChains.cpp
+++ b/lib/Driver/ToolChains.cpp
@@ -250,6 +250,7 @@ void ToolChain::addCommonFrontendArgs(const OutputInfo &OI,
@@ -270,6 +270,7 @@ void ToolChain::addCommonFrontendArgs(const OutputInfo &OI,
inputArgs.AddAllArgs(arguments, options::OPT_enable_experimental_feature);
inputArgs.AddAllArgs(arguments, options::OPT_enable_upcoming_feature);
inputArgs.AddLastArg(arguments, options::OPT_warn_implicit_overrides);
Expand All @@ -43,23 +43,23 @@ index 8c3b3d0e1d0..a39fac0334d 100644
inputArgs.AddLastArg(arguments, options::OPT_enable_app_extension);
inputArgs.AddLastArg(arguments, options::OPT_enable_app_extension_library);
diff --git a/lib/Frontend/CompilerInvocation.cpp b/lib/Frontend/CompilerInvocation.cpp
index f9350ef5c62..374d47f6982 100644
index 4beea4d7b51..c86026dca88 100644
--- a/lib/Frontend/CompilerInvocation.cpp
+++ b/lib/Frontend/CompilerInvocation.cpp
@@ -720,6 +720,8 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,
@@ -820,6 +820,8 @@ static bool ParseLangArgs(LangOptions &Opts, ArgList &Args,

Opts.EnableThrowWithoutTry |= Args.hasArg(OPT_enable_throw_without_try);

+ Opts.DisableObjCAttr |= Args.hasArg(OPT_experimental_disable_objc_attr);
+
Opts.ThrowsAsTraps |= Args.hasArg(OPT_throws_as_traps);

if (auto A = Args.getLastArg(OPT_enable_objc_attr_requires_foundation_module,
OPT_disable_objc_attr_requires_foundation_module)) {
Opts.EnableObjCAttrRequiresFoundation
diff --git a/lib/Parse/ParseDecl.cpp b/lib/Parse/ParseDecl.cpp
index 4acf53c30ef..409a869c595 100644
index 2c6f69cd220..0f94a99adf9 100644
--- a/lib/Parse/ParseDecl.cpp
+++ b/lib/Parse/ParseDecl.cpp
@@ -5924,6 +5924,30 @@ Parser::parseDecl(ParseDeclOptions Flags,
@@ -6565,6 +6565,30 @@ ParserResult<Decl> Parser::parseDecl(bool IsAtStartOfLineOrPreviousHadSemi,
return DeclResult;
}

Expand Down
10 changes: 5 additions & 5 deletions patches/release/6.0/swift/0005-Disable-all-tests.patch
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
diff --git a/utils/build-presets.ini b/utils/build-presets.ini
index 84b0baaa41d..ebbac0abd71 100644
index 66665164c9b..7c57361b97b 100644
--- a/utils/build-presets.ini
+++ b/utils/build-presets.ini
@@ -841,8 +841,6 @@ build-swift-stdlib-unittest-extra
@@ -862,8 +862,6 @@ build-swift-stdlib-unittest-extra
# Executes the lit tests for the installable package that is created
# Assumes the swift-integration-tests repo is checked out

Expand All @@ -11,7 +11,7 @@ index 84b0baaa41d..ebbac0abd71 100644
# Build the benchmarks against the toolchain.
toolchain-benchmarks

@@ -914,12 +912,6 @@ mixin-preset=
@@ -970,12 +968,6 @@ mixin-preset=
build-subdir=buildbot_linux

release
Expand All @@ -24,12 +24,12 @@ index 84b0baaa41d..ebbac0abd71 100644

build-ninja

@@ -936,8 +928,6 @@ install-destdir=%(install_destdir)s
@@ -992,8 +984,6 @@ install-destdir=%(install_destdir)s
# Path to the .tar.gz package we would create.
installable-package=%(installable_package)s

-host-test
-
install-prefix=/usr
install-llvm
install-swift
install-static-linux-config

0 comments on commit bb452d1

Please sign in to comment.