Apple Ports Its Swift Programming Language to Linux

Apple Ports Its Swift Programming Language to Linux

Posted by · 10402 views · Translate
Alongside its open sourcing of the Swift Programming Language earlier today, Apple has announced a port of Swift to Linux.

With the launch of the open source Swift project, we are also releasing a port that works with the Linux operating system! You can build it from the Swift sources or download pre-built binaries for Ubuntu. The port is still a work in progress but we’re happy to say that it is usable today for experimentation. Currently x86_64 is the only supported architecture on Linux.

What’s Working in the Port Today:
● Swift without the Objective-C Runtime: Swift on Linux does not depend on the Objective-C runtime nor includes it. While Swift was designed to interoperate closely with Objective-C when it is present, it was also designed to work in environments where the Objective-C runtime does not exist.

● The core Swift Language and Standard Library on Linux shares most of the same implementation and APIs as on Apple platforms. There are some slight differences of behavior because of the absence of the Objective-C runtime on Linux (noted below).

● The Glibc Module: Most of the Linux C standard library is available through this module similar to the Darwin module on Apple platforms. Some headers aren’t yet imported into the module, such as tgmath.h. To try it out, just import Glibc.

● Swift Core Libraries: The Core Libraries provide implementations of core APIs from Foundation and XCTest to be used on Linux without Objective-C . The intention is that these APIs are available in a cross-platform manner regardless of whether you are using Swift on Apple’s platforms or Swift on Linux.

● LLDB Swift debugging and the REPL: You can debug your Swift binaries and experiment in the REPL just like you do on OS X.

● The Swift Package Manager is a first class citizen as it is on Apple’s platforms.


More details on the Linux port and what's not working can be found at the link below...

Read More


Apple Ports Its Swift Programming Language to Linux
joeiachievedit - December 7, 2015 at 2:50am
Two quick resources for using Swift on Linux - http://dev.iachieved.it/iachievedit/swift-on-linux/ and http://dev.iachieved.it/iachievedit/more-swift-on-linux/
Nobody - December 3, 2015 at 5:40pm
#LINUXMASTERRACE
Somebody - December 3, 2015 at 8:06pm
#OSXMASTERRACE Notice the XMAS?
Recent