Commit Graph

9 Commits

Author SHA1 Message Date
buttaface
30c292ca87 [android] Update to NDK 23b (#39921)
The latest Long Term Support NDK finally removed binutils, including the bfd/gold
linkers and libgcc. This simplifies our Android support, including making lld the
default linker for Android. Disable three reflection tests that now fail, likely
related to issues with swift-reflection-dump and switching to lld.
2021-11-17 20:58:42 -08:00
Saleem Abdulrasool
15a5d2c54b Revert "[android] Update to NDK 23" 2021-10-16 11:07:23 -07:00
Butta
7fa1b4b2ac [android] Update to NDK 23
The latest Long Term Support NDK finally removed binutils, including the bfd/gold
linkers and libgcc. This simplifies our Android support, including making lld the
default linker for Android. Disable three reflection tests that now fail, likely
related to issues with swift-reflection-dump and switching to lld.

Also, add the libatomic dependency for Android armv7, just as on linux.
2021-10-12 12:37:01 +05:30
buttaface
e6f5913772 [android] Move to the NDK's unified sysroot (#34491)
Since the NDK removes the platforms/ and sysroot/ directories in the latest NDK
22, switch to the unified sysroot in toolchains/llvm/ and take advantage of a
bunch of simplification that's now possible.
2021-02-07 09:19:18 -08:00
Butta
796d6ade9a [android] Add support for natively building on Android
Check if building on Android through the ANDROID_DATA environment variable, then set
SWIFT_ANDROID_NATIVE_SYSROOT to the default layout for the Termux app, and key all the
include, lib, and other SDK paths off of that. The system libc and a few other libraries
are linked against from /system/lib[64]. Finally, check if lit is running natively on
Android and don't use adb if so.
2019-07-30 00:38:36 +05:30
Vlad Gorloff
096f7f38c0 Android Intel 32/64 bit (i.e. Android Simulator) support. 2019-05-28 23:26:13 +02:00
Saleem Abdulrasool
ab5d729ae0 build: extract the C++ header search path for android
Extract the C++ header search path from the system header search path.  This is
needed to ensure that we do not push the C++ headers into the swift compiler
search path.  The reason here is that when building the module, we would attempt
to include the C++ headers, which we cannot do since the ClangImporter in swift
explicitly sets the langugage to C.  This would break the stdlib build for
android.
2018-10-09 15:41:22 -07:00
Saleem Abdulrasool
583ceaede5 build: support android aarch64
This adds the needed support to enable building the standard library for android
aarch64 assuming that the appropriate parameters are passed to CMake.
2018-09-24 09:55:10 -07:00
Nathan Lanza
7429856034 Change various search and linker paths to account for changes in NDK16
ndk14 introduced "unified headers" which merged the headers for all
different API versions into one directory which effectively split the
"SWIFT_SDK_ANDROID_ARCH_${ARCH}_PATH" into two different directories.

Add include and library specific paths to various compilation and link
invocations across the Swift project to account for this change. Remove
some broken sysroot/sdk specific settings.
2018-05-02 14:18:11 -07:00