This repository has been archived by the owner on Aug 14, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from vgorloff/develop
RC 1.0.13
- Loading branch information
Showing
30 changed files
with
552 additions
and
143 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
Patches/swift-corelibs-foundation/Foundation/CGFloat.swift.diff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
diff --git a/Foundation/CGFloat.swift b/Foundation/CGFloat.swift | ||
index 1bb768df2982ea692bee7a6c0cc62f1c7327f293..5f33c061dcfc6f6b3e4972af3dce20311b4b3488 100644 | ||
--- a/Foundation/CGFloat.swift | ||
+++ b/Foundation/CGFloat.swift | ||
@@ -31,7 +31,7 @@ public struct CGFloat { | ||
self.native = NativeType(value) | ||
} | ||
|
||
-#if !os(Windows) && (arch(i386) || arch(x86_64)) | ||
+#if !(os(Windows) || os(Android)) && (arch(i386) || arch(x86_64)) | ||
@_transparent public init(_ value: Float80) { | ||
self.native = NativeType(value) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
diff --git a/cmake/modules/AddSwift.cmake b/cmake/modules/AddSwift.cmake | ||
index 5a7e220c6b04dbbef3288f996c4922ea539aac76..02e51b5f069ad8d5649c28d21ddf5351973482e6 100644 | ||
--- a/cmake/modules/AddSwift.cmake | ||
+++ b/cmake/modules/AddSwift.cmake | ||
@@ -435,6 +435,8 @@ function(_add_variant_link_flags) | ||
set(android_libcxx_path "${SWIFT_ANDROID_NDK_PATH}/sources/cxx-stl/llvm-libc++/libs/armeabi-v7a") | ||
elseif("${LFLAGS_ARCH}" MATCHES aarch64) | ||
set(android_libcxx_path "${SWIFT_ANDROID_NDK_PATH}/sources/cxx-stl/llvm-libc++/libs/arm64-v8a") | ||
+ elseif("${LFLAGS_ARCH}" MATCHES i686) | ||
+ set(android_libcxx_path "${SWIFT_ANDROID_NDK_PATH}/sources/cxx-stl/llvm-libc++/libs/x86") | ||
else() | ||
message(SEND_ERROR "unknown architecture (${LFLAGS_ARCH}) for android") | ||
endif() |
13 changes: 13 additions & 0 deletions
13
Patches/swift/cmake/modules/SwiftAndroidSupport.cmake.diff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
diff --git a/cmake/modules/SwiftAndroidSupport.cmake b/cmake/modules/SwiftAndroidSupport.cmake | ||
index c6dcc783c68091927edc1cc065d0bbb8c435501d..2bd1a068c5c2f92268fa50f59a009d6e58a984bc 100644 | ||
--- a/cmake/modules/SwiftAndroidSupport.cmake | ||
+++ b/cmake/modules/SwiftAndroidSupport.cmake | ||
@@ -23,6 +23,8 @@ function(swift_android_lib_for_arch arch var) | ||
list(APPEND paths "${_prebuilt}/${_host}/lib/armv7-a") | ||
elseif(arch STREQUAL aarch64) | ||
list(APPEND paths "${_prebuilt}/${_host}/lib64") | ||
+ elseif(arch STREQUAL i686) | ||
+ list(APPEND paths "${_prebuilt}/${_host}/lib") | ||
else() | ||
message(SEND_ERROR "unknown architecture (${arch}) for android") | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
diff --git a/cmake/modules/SwiftConfigureSDK.cmake b/cmake/modules/SwiftConfigureSDK.cmake | ||
index 21e47a6e6382cc19ea192d388677ec3e6276bc86..5c68072a79588f4217a29608da78403a2b2e9284 100644 | ||
--- a/cmake/modules/SwiftConfigureSDK.cmake | ||
+++ b/cmake/modules/SwiftConfigureSDK.cmake | ||
@@ -186,6 +186,11 @@ macro(configure_sdk_unix name architectures) | ||
set(SWIFT_SDK_ANDROID_ARCH_${arch}_ALT_SPELLING "aarch64") | ||
set(SWIFT_SDK_ANDROID_ARCH_${arch}_PATH "${SWIFT_ANDROID_NDK_PATH}/platforms/android-${SWIFT_ANDROID_API_LEVEL}/arch-arm64") | ||
set(SWIFT_SDK_ANDROID_ARCH_${arch}_TRIPLE "aarch64-unknown-linux-android") | ||
+ elseif("${arch}" STREQUAL "i686") | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_TRIPLE "i686-linux-android") | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_ALT_SPELLING "i686") | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_PATH "${SWIFT_ANDROID_NDK_PATH}/platforms/android-${SWIFT_ANDROID_API_LEVEL}/arch-x86") | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_TRIPLE "i686-unknown-linux-android") | ||
else() | ||
message(FATAL_ERROR "unknown arch for android SDK: ${arch}") | ||
endif() | ||
@@ -196,8 +201,13 @@ macro(configure_sdk_unix name architectures) | ||
elseif("${CMAKE_HOST_SYSTEM_NAME}" STREQUAL "Linux") | ||
set(_swift_android_prebuilt_build "linux-x86_64") | ||
endif() | ||
- set(SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_PREBUILT_PATH | ||
- "${SWIFT_ANDROID_NDK_PATH}/toolchains/${SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_TRIPLE}-${SWIFT_ANDROID_NDK_GCC_VERSION}/prebuilt/${_swift_android_prebuilt_build}") | ||
+ if("${arch}" STREQUAL "i686") | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_PREBUILT_PATH | ||
+ "${SWIFT_ANDROID_NDK_PATH}/toolchains/x86-${SWIFT_ANDROID_NDK_GCC_VERSION}/prebuilt/${_swift_android_prebuilt_build}") | ||
+ else() | ||
+ set(SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_PREBUILT_PATH | ||
+ "${SWIFT_ANDROID_NDK_PATH}/toolchains/${SWIFT_SDK_ANDROID_ARCH_${arch}_NDK_TRIPLE}-${SWIFT_ANDROID_NDK_GCC_VERSION}/prebuilt/${_swift_android_prebuilt_build}") | ||
+ endif() | ||
else() | ||
if(NOT SWIFT_SDK_${prefix}_ARCH_${arch}_PATH) | ||
set(SWIFT_SDK_${prefix}_ARCH_${arch}_PATH "/") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
diff --git a/include/swift/Runtime/SwiftDtoa.h b/include/swift/Runtime/SwiftDtoa.h | ||
index c309d2e97985ef70d6c714ca802e00831f113fe9..41a892eaaab662d640588c6a274a569545b5a7b7 100644 | ||
--- a/include/swift/Runtime/SwiftDtoa.h | ||
+++ b/include/swift/Runtime/SwiftDtoa.h | ||
@@ -37,6 +37,10 @@ | ||
#endif | ||
#endif | ||
|
||
+#if defined(__ANDROID__) && defined(__i386) | ||
+ #undef SWIFT_DTOA_FLOAT80_SUPPORT | ||
+#endif | ||
+ | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
diff --git a/stdlib/public/Platform/Glibc.swift.gyb b/stdlib/public/Platform/Glibc.swift.gyb | ||
index 4c011570295f58d717387bc686e878df853de74d..2de990adfffaf01e077c2fc84059b44d0fc8359d 100644 | ||
--- a/stdlib/public/Platform/Glibc.swift.gyb | ||
+++ b/stdlib/public/Platform/Glibc.swift.gyb | ||
@@ -36,7 +36,7 @@ public let FLT_RADIX = Double.radix | ||
|
||
%for type, prefix in [('Float', 'FLT'), ('Double', 'DBL'), ('Float80', 'LDBL')]: | ||
% if type == "Float80": | ||
-#if arch(i386) || arch(x86_64) | ||
+#if !os(Android) && (arch(i386) || arch(x86_64)) | ||
% end | ||
// Where does the 1 come from? C counts the usually-implicit leading | ||
// significand bit, but Swift does not. Neither is really right or wrong. |
Oops, something went wrong.