Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Swift on Linux
Search
Ben Scheirman
October 13, 2016
Programming
1
750
Swift on Linux
Presented at CocoaConf Austin 2016 and Pragmaconf '16 in Verona, Italy
Ben Scheirman
October 13, 2016
Tweet
Share
More Decks by Ben Scheirman
See All by Ben Scheirman
A Promise for a Better Future
subdigital
0
120
Bézier Curves
subdigital
1
4.8k
Buckets of Code
subdigital
0
1.9k
Building 5 Calls for iOS
subdigital
0
94
tvOS Workshop
subdigital
1
110
Swift Solutions
subdigital
2
440
iOS 8 Networking
subdigital
4
880
iOS 8 App Extensions
subdigital
1
360
Effective Networking with iOS 8 and Swift
subdigital
4
1.6k
Other Decks in Programming
See All in Programming
AWS Application Composerで始める、 サーバーレスなデータ基盤構築 / 20240406-jawsug-hokuriku-shinkansen
kasacchiful
1
260
ゆるい個人開発のススメ
kuroppe1819
10
990
Ruby Function Composition
bkuhlmann
1
330
Snowflakeで眠ったデータを起こそう!
estie
0
120
GraphQLサーバの構成要素を整理する #ハッカー鮨 #tsukijigraphql / graphql server technology selection
izumin5210
4
840
try! Swift Tokyo 初参加報告LT
hinakko2
0
220
スキーマ駆動開発による品質とスピードの両立 - 私達は何故、スキーマを書くのか
kentaroutakeda
0
170
Java 22 Overview
kishida
1
180
Build Apps for iOS, Android & Desktop in 100% Kotlin With Compose Multiplatform (mDevCamp 2024)
zsmb
0
340
PHPはいつから死んでいるかの調査
chiroruxx
1
400
DMMプラットフォームがTiDB Cloudを採用した背景
pospome
8
4.1k
Fragment Composition of GraphQL
quramy
7
1k
Featured
See All Featured
The Art of Programming - Codeland 2020
erikaheidi
42
12k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
227
16k
Designing for Performance
lara
601
67k
Intergalactic Javascript Robots from Outer Space
tanoku
266
26k
The World Runs on Bad Software
bkeepers
PRO
61
6.7k
Music & Morning Musume
bryan
41
5.6k
Art, The Web, and Tiny UX
lynnandtonic
289
19k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
187
16k
GraphQLの誤解/rethinking-graphql
sonatard
50
9.2k
Building a Modern Day E-commerce SEO Strategy
aleyda
17
6.4k
The Invisible Side of Design
smashingmag
294
49k
How GitHub (no longer) Works
holman
304
140k
Transcript
Swift on Linux
Hi, I’m Ben @subdigital
None
None
Written in Swift
Running on $5/mo Linux VPS
(my little secret)
Swift 1.0 Sept 2014 Swift 2.0 Swift Open Sourced Swift
3.0! Sept 2015 Dec 2015 Sept 2016
… but what does that mean? + github.com/apple
1. Swift Language, Compiler, & Debugger (with full commit history!)
None
None
None
2. Swift Core Libraries
*not on Linux (yet) github.com/apple/swift-corelibs-foundation github.com/apple/swift-corelibs-xctest github.com/apple/swift-corelibs-libdispatch Foundation XCTest libDispatch*
3. Swift Package Manager github.com/apple/swift-package-manager
• Defines how modules are built • Resolves Dependencies •
Convention over Configuration
// Package.swift import PackageDescription let package = Package( name: “Foo”,
dependencies: [] )
None
4. Swift Evolution github.com/apple/swift-evolution
None
let’s play
vagrantup.com
git.io/vwJ4g
“Trusty Tahr” trusty(14.04) 64-bit
None
None
$ sudo apt-get install -y \ git \ clang \
libicu-dev
$ Demo
github.com/subdigital/ nsdateformatter
What Else?
?
Wrap your favorite C library!
Create a modulemap: module CCurl [system] { header "/usr/include/curl/curl.h" link
"curl" export * }
Add a git tag…. $ git add . $ git
commit -m “Initial commit” [master (root-commit) fa72d04] initial commit 1 file changed, 1 insertion(+) $ git tag 0.0.1
Reference from your Package.swift .Package(url: “../CCurl”, majorVersion: 0)
Doing active development? Don’t forget to update the tag…. every
time…
None
Thanks! @subdigital nsscreencast.com