New Swift Package Repository for Ubuntu/Debian Linux Distributions

Hi @futurejones and thanks for your efforts and for 5.6, but there could be problem with the link...

pisat@satserver:~ $ sudo apt update
Hit:1 http://deb.debian.org/debian bullseye InRelease
Hit:2 http://security.debian.org/debian-security bullseye-security InRelease                                          
Hit:3 http://deb.debian.org/debian bullseye-updates InRelease                                                         
Hit:4 http://archive.raspberrypi.org/debian bullseye InRelease                      
Err:5 https://archive.swiftlang.xyz/debian bullseye InRelease 
  Could not connect to archive.swiftlang.xyz:443 (147.75.47.197), connection timed out
Reading package lists... Done                           
Building dependency tree... Done
Reading state information... Done
All packages are up to date.
W: Failed to fetch https://archive.swiftlang.xyz/debian/dists/bullseye/InRelease  Could not connect to archive.swiftlang.xyz:443 (147.75.47.197), connection timed out
W: Some index files failed to download. They have been ignored, or old ones used instead.
pisat@satserver:~ $ 

Indeed, archive.swiftlang.xyz is not answering on https.

This also gives rise to misleading output from apt-get implying that a package named swiftlang simply does not exist:

$ sudo apt install swiftlang
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package swiftlang

(This is on Ubuntu 21.04; as far as I can tell, apt doesn't support a --verbose mode or anything like it.)

-ben

Neither does https://archive.swiftlang.xyz/repos/ Not even https://archive.swiftlang.xyz/ However, the basic home page https://www.swiftlang.xyz/ does work, so I guess the entire sub-domain is offline.

Of course neither of those URLs works because they're on the same host, which appears to be offline.

www.swiftlang.xyz is an alias for futurejones.github.io (185.199.108.153), while archive.swiftlang.xyz is an entirely different machine (147.75.47.197).

Hi everbody,
The repository archive.swiftlang.xyz is offline at the moment for server maintenance and hardware upgrade.
I will post an update when the repository is back online.

2 Likes

Hi everybody,
The repository is up and running again. It took a bit longer than expected as all data was lost and required a total rebuild.
I am working on adding Swift 5.6 and it should be available in the next few days.

6 Likes

Have you missed something?

curl -s https://archive.swiftlang.xyz/install.sh | sudo bash

The last option, option 4) offers 5.5, but option 1) installs 5.6.

I find this confusing.

@ea7kir when running the install script you will get the following menu -

--------------- Choose Swift Release Version ---------------

 If you always want to have the latest release/stable version of Swift available choose [1], if not, choose the version most suitable for your project. 
 The latest release/stable version of Swift is currently 5.6 

---------------------------------------------------------

  1) latest/main - This will update to the latest/stable release of Swift available
  2) developer - Swift developer builds - this will update to the latest developer build available
  3) Swift version 5.4.* - this will update to the latest point/patch release of Swift 5.4
  4) Swift version 5.5.* - this will update to the latest point/patch release of Swift 5.5

---------------------------------------------------------

Option 1 gives you the latest Swift release. This has just been updated to version 5.6.
If you need a specific version of swift for software compatibility you can choose a different option.

1 Like

Hi everybody,
Swift-5.6-RELEASE is now available in the repository.
Available for the following distributions.

  • Debian 10 buster
  • Debian 11 bullseye
  • Ubuntu 18.04 bionic
  • Ubuntu 20.04 focal
  • Ubuntu 21.04 hirsute
  • Ubuntu 21.10 impish
  • Ubuntu 22.04 jammy

Any distribution based on the Debian or Ubuntu versions above will also be compatible.

4 Likes

Nice! But, no impish?

Sorry, but my brain operates differently to others. I was assuming that "latest/stable" meant "latest or stable", where "latest" would mean the non-stable development version.

@Karl sorry missed that one, yes impish is available. I will add it to the list.

1 Like

It seems buster/amd64 and bullseye/amd64 are still in 5.5.3 now.

Likewise, on Ubuntu 21.10, I'm still only getting 5.5.3 after an apt update.

Now it's there.

I get the following error trying to install swiftlang:

trying to overwrite '/usr/bin/clang-13', which is also in package clang-13 1:13.0.0-2

Any advice?

I found this on another post. It may help...

DELETING (Safe to delete...

  1. ~/Library/org.swift.swiftpm: configured mirrors, package collection lists, package fingerprints, etc.

  2. ~/Library/Caches/org.swift.swiftpm: global cache of fetched packages.

  3. .build in each package directory: products and intermediates of the particular package’s build.

All are safe to delete as long as SwiftPM is not running. 1 contains the global configurations, so deleting it essentially reverts to factory defaults. But 2 and 3 are just caches, so you lose nothing if you delete them.

@gonsolo what OS and distribution are you using?

Linux Ubuntu 21.10.

After uninstalling clang-13 the following error occurs:

trying to overwrite '/usr/lib/libLTO.so', which is also in package llvm-dev 1:13.0-53~exp1

After uninstalling llvm-dev it works.

Some random notes:

  1. It is unfortunate that swiftlang clashes with clang-13 and llvm-dev.
  2. It would be good to coordinate with Debian/Ubuntu LLVM package teams.
  3. It would be good to have Swift in llvm-project and not using a special LLVM and Clang version.
  4. I'm still super happy that this repository exists at all. :slight_smile:
2 Likes

@gonsolo I have uploaded new Swift 5.6 packages to fix the clang-13 and llvm-dev conflicts.
If you run sudo apt update you will get the new packages which should install without any problems.

2 Likes