A Recap of the Swift Porting Efforts #2
Posted on March 11, 2016 中文版
Since last month a few new things on the Swift porting front have landed on master. Let’s recap what happened in February and what is under development at the moment.
Windows
The Cygwin Windows port by Han Sangjin has been merged two weeks ago, you can check out PR #1108 for more info.
Development is still ongoing and after PR #1466, that will be useful for other ports too, is currently centered around PR #1516 that aims to link the swiftc binary against the Windows MSVC library.
Android
The Android porting team composed by Zhuowei Zhang, the prolific Brian Gesiak and others have opened PR #1442 that collects all the work done in the past months and their extension is now under review.
This huge set of changes will likely be broken down into smaller PRs, i recommend you to follow the PR if you are interested in Swift on Android or even just to learn more about the inner workings of the toolchain thanks to the interesting comments. And if you want to help, feel free to chime in.
ARM
A few new contributions from William Dillon that with PR #1157 has added support for Google’s Gold linker. Additionally, the thumb
arch type is now allowed and you’ll be able to compile binaries using thumb/thumb 2 extensions where supported.
Regarding Swift availability on ARMv6, Swift 3.0 binaries are now available for download, this version is an improvement over the previously released 2.2 package (it contains the Foundation and XCTest too) and it’s what i recommend you to use. It has been compiled from a snapshot of the Swift master from mid February.
PowerPC64le
I actually missed this one last time since support for this platform has been introduced in January with PR #979 by Anton Blanchard. Only the little endian flavor of the PowerPC64 architecture seems to be supported at the moment, the OS is as expected Linux.
Cross compilation
Cross compilation from OSX to other OSes and architectures has been investigated by different people in the past months and PR #1398 by @froody provides an example of how this could be done
Adding support for cross compilation could be done in a number of different ways and providing something clean, with a low number of moving parts will not be easy. This functionality will likely be the main subject of the next update.
Did you like this article? Let me know on Twitter!