Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Speaker Deck
PRO
Sign in
Sign up for free
Swift on Linux
Ben Scheirman
October 13, 2016
Programming
1
660
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
89
Bézier Curves
subdigital
1
4.2k
Buckets of Code
subdigital
0
1.8k
Building 5 Calls for iOS
subdigital
0
88
tvOS Workshop
subdigital
1
93
Swift Solutions
subdigital
2
430
iOS 8 Networking
subdigital
4
850
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
OIDC仕様に準拠した Makuake ID連携基盤構築の裏側
ymtdzzz
0
130
LIFFで動く割り勘アプリTATEKAをリリースしてみた話
inoue2002
0
210
花き業界のサプライチェーンを繋げるプロダクト開発の進め方
userlike1
0
100
フロントエンドで学んだことをデータ分析で使ってみた話
daichi_igarashi
0
170
新卒でサービス立ち上げから Hasuraを使って3年経った振り返り
yutorin
0
200
tidy_rpart
bk_18
0
540
低レイヤーから始める GUI
fadis
18
9.2k
MapLibre GL JS とCSSアニメーションでできること
satoshi7190
0
200
社会人 20 年目エンジニア、発信で技術学びなおしてる話
e99h2121
1
140
Azure Functionsをサクッと開発、サクッとデプロイ/vscodeconf2023-baba
nina01
1
320
Quarto Tips for Academic Presentation
nicetak
0
900
T3 Stack and TypeScript ecosystem
quramy
3
690
Featured
See All Featured
Java REST API Framework Comparison - PWX 2021
mraible
PRO
13
5.4k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
7
570
Making the Leap to Tech Lead
cromwellryan
116
7.6k
Fashionably flexible responsive web design (full day workshop)
malarkey
396
63k
JazzCon 2018 Closing Keynote - Leadership for the Reluctant Leader
reverentgeek
175
9.1k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
217
21k
Adopting Sorbet at Scale
ufuk
65
7.8k
How to train your dragon (web standard)
notwaldorf
66
4.2k
Happy Clients
brianwarren
90
5.8k
GraphQLの誤解/rethinking-graphql
sonatard
39
7.8k
Code Reviewing Like a Champion
maltzj
508
38k
How GitHub Uses GitHub to Build GitHub
holman
465
280k
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