# Stabilizing Swift on Linux

**URL:** <https://forums.swift.org/t/stabilizing-swift-on-linux/68743>\
**Category:** Compiler\
**Tags:** abistability, linux\
**Created:** [November 30, 2023, 8:27pm UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743 "2023-11-30T20:27:13Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![zaneenders](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/zaneenders/32/27225_2.png) [@zaneenders](https://forums.swift.org/u/zaneenders)\
**Post date:** [November 30, 2023, 8:27pm UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/1 "2023-11-30T20:27:13Z")

</div>

Hi,

I read this article and my idea for trying to solve the problem, is could we stabilize Swift's ABI on Linux and then maybe other languages could start using that as an ABI instead of C.

> **[C Isn't A Programming Language Anymore - Faultlore](https://faultlore.com/blah/c-isnt-a-language/)**

Is it even possible to stabilize Swift on Linux?

Also wow nice work the entire Swift team!!

Context I am an undergrad so I don't know a lot of the details yet. I have taken a Compilers class and OS is next semester.

Thanks,  
Zane

---

<div class="post-metadata">

**Author:** ![David\_Smith](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/david_smith/32/37508_2.png) [@David\_Smith](https://forums.swift.org/u/David_Smith)\
**Post date:** [November 30, 2023, 9:08pm UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/2 "2023-11-30T21:08:15Z")

</div>

It's a lovely idea, but I don't know if we're currently in a place where it's the right thing to do. Stabilizing an ABI is a profoundly labor intensive decision that also limits future evolution of the language and libraries. On Darwin this was basically a non-choice; in order for the platform to adopt Swift it had to happen, and adopting Swift in the platform was always the goal. Without a similarly critical driver on Linux I'm not sure the tradeoffs make sense.

---

<div class="post-metadata">

**Author:** ![wadetregaskis](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/wadetregaskis/32/8494_2.png) [@wadetregaskis](https://forums.swift.org/u/wadetregaskis)\
**Post date:** [December 1, 2023, 1:28am UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/3 "2023-12-01T01:28:41Z")

</div>

Although, given the ABI freeze on Apple platforms and the collateral impact it has on all other platforms, is it _that_ much more restrictive [to evolution] to formally freeze it on Linux too?

---

<div class="post-metadata">

**Author:** ![taylorswift](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/taylorswift/32/43413_2.png) [@taylorswift](https://forums.swift.org/u/taylorswift)\
**Post date:** [December 1, 2023, 1:47am UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/4 "2023-12-01T01:47:02Z")

</div>

> [@wadetregaskis](#):
>
> is it _that_ much more restrictive [to evolution] to formally freeze it on Linux too?

it would make life on the server harder in the medium term, because linux libraries will have to start accumulating availability guards the same way macOS libraries currently do.

---

<div class="post-metadata">

**Author:** ![wadetregaskis](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/wadetregaskis/32/8494_2.png) [@wadetregaskis](https://forums.swift.org/u/wadetregaskis)\
**Post date:** [December 1, 2023, 2:47am UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/5 "2023-12-01T02:47:56Z")

</div>

Maybe I’m misunderstanding, but I think you’re alluding to OS version checks (and the like)? Isn’t that separate from whether there’s a well-defined, compatible library interface?

---

<div class="post-metadata">

**Author:** ![taylorswift](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/taylorswift/32/43413_2.png) [@taylorswift](https://forums.swift.org/u/taylorswift)\
**Post date:** [December 1, 2023, 2:59am UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/6 "2023-12-01T02:59:26Z")

</div>

linux apps are currently exempt from version checks because it is assumed they are always running with the latest version of the swift runtime. a lot of library interfaces depend on the swift runtime and cannot be stabilized unless the runtime is also stabilized.

---

<div class="post-metadata">

**Author:** ![wadetregaskis](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/wadetregaskis/32/8494_2.png) [@wadetregaskis](https://forums.swift.org/u/wadetregaskis)\
**Post date:** [December 1, 2023, 4:31am UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/7 "2023-12-01T04:31:57Z")

</div>

What sort of things are expected to change about the runtime's ABI, in the foreseeable future?

It seems like it'd be hard to make significant changes on any platform if _any_ platform is frozen in this respect, since it's generally undesirable to have significant differences between platforms. (see also the state of Foundation to date, case in point)

---

<div class="post-metadata">

**Author:** ![hassila](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/hassila/32/22647_2.png) [@hassila](https://forums.swift.org/u/hassila)\
**Post date:** [December 1, 2023, 5:46pm UTC](https://forums.swift.org/t/stabilizing-swift-on-linux/68743/8 "2023-12-01T17:46:22Z")

</div>

I think one possible critical driver for Linux is among other things to support binary dependencies and evolution across toolchain versions - we are fighting quite a bit with those issues currently as we want to ship a stable ABI for our customers plugins.

I am personally a bit afraid that the desire to do a perfect solution that works across multiple distros will stop support for a single distribution.
