How does Ubuntu install Swift?

Source: Internet
Author: User

  What is Swift?

Swift is Apple's newest programming language, designed to replace Objective-c as the main language for building Mac OS X and IOS applications. Swift is very concise and easy to learn, and has a similar syntax to other popular programming languages.

However, the Swift language applies only to Apple devices, and programs that are developed cannot be run on Windows, Linux, or other systems. As Swift becomes more popular, more and more developers are hoping that Apple will open the source of swift, at least to enable it to support more platforms. Apple, too, listened to the vast majority of developers ' voices and eventually made Swift open source. As a business point of view, it's a good move for Apple to open up Swift, which at least makes it easier for more developers to create Mac OS X and IOS apps.

If you are interested in learning the Swift programming language, you can install it at any time on Linux. Apple is now releasing only the installer for Ubuntu 14.04 and Ubuntu 15.10, and is confident Apple will soon update the common installer for other platforms and Linux platforms.

  How Ubuntu installs Swift

1. First, we need to go to the swift download page to download the latest Swift program and then unzip it to a storage path.

2. Secondly, we need to install some of the dependencies needed for Swift operations, and you can install them using the following command:

sudo apt-get install clang Libicu-dev

3. Secondly, we need to install some of the dependencies needed for Swift operations, and you can install them using the following command:

sudo apt-get install clang Libicu-dev

4. Open the configuration file using the following command:

Gedit. Profile

5. In the "Last Insert Line" entry:

Export path=/path/to/usr/bin: "${path}"

6. Change the/path/to/in the appeal path to the decompression path after Swift download in the first step:

/home/billyfu/swift-2.2-snapshot-2015-12-31-a-ubuntu15.10/usr/bin

7. After the above steps are completed, you can use the following command to view the Swift version:

Swift–version

If you see the correct display version number, then Swift will be able to work on Ubuntu!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.