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
910
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Swift on Linux
Presented at CocoaConf Austin 2016 and Pragmaconf '16 in Verona, Italy
Ben Scheirman
October 13, 2016
More Decks by Ben Scheirman
See All by Ben Scheirman
A Promise for a Better Future
subdigital
0
200
Bézier Curves
subdigital
1
5.7k
Buckets of Code
subdigital
0
2k
Building 5 Calls for iOS
subdigital
0
160
tvOS Workshop
subdigital
1
190
Swift Solutions
subdigital
2
500
iOS 8 Networking
subdigital
4
980
iOS 8 App Extensions
subdigital
1
400
Effective Networking with iOS 8 and Swift
subdigital
4
1.7k
Other Decks in Programming
See All in Programming
Go 1.27 における memory allocation の高速化
andpad
0
120
AIが無かった頃の素敵な出会いの話
codmoninc
1
400
AI時代のPHPer生存戦略 ~「言語、もうなんでもよくない?」に本気で向き合う~
vivion
0
310
Built Our Own Background Agent at LayerX
layerx
PRO
9
5.1k
数百円から始めるRuby電子工作
tarosay
0
140
Terraform標準の組織で AWS CDKをどう使うか
mu7889yoon
1
500
仕様駆動開発へのトライを機に チームに適合する手法を模索し続けている話
freee
PRO
0
460
夏だ!祭りだ!祭りとはドメインモデリングでは?
ryugen04
0
200
ITヒヤリハットを整理してみた ~ライフサイクルと原因から考える再発防止策~
koukimiura
1
140
改善しないと、タスクが回らない。 “てんこ盛りポジション” を引き継いだ情シスの、入社3ヶ月の業務改善録
krm963
0
260
AI時代、エンジニアはどう育つのか -未経験エンジニアの成長を間近で見て考えたこと-
thasu0123
0
220
霧の中の代数的エフェクト
funnyycat
1
490
Featured
See All Featured
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
66
57k
Accessibility Awareness
sabderemane
1
170
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
210
VelocityConf: Rendering Performance Case Studies
addyosmani
332
25k
GraphQLとの向き合い方2022年版
quramy
50
15k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.8k
Making the Leap to Tech Lead
cromwellryan
135
10k
Unlocking the hidden potential of vector embeddings in international SEO
frankvandijk
0
890
Context Engineering - Making Every Token Count
addyosmani
9
1k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
430
A Guide to Academic Writing Using Generative AI - A Workshop
ks91
PRO
1
370
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