2

I tried to program in swift but somehow I can't build my code. I am using VSCode . I read that you have to install sourcekit-lsp, but I am unsure if I installed it correctly.

Then I did the following command to check the version:

$ swift -version
/snap/swift/5/bin/swift: error while loading shared libraries: libatomic.so.1: wrong ELF class: ELFCLASS32

but as you can see, there is something wrong with libatomic.so.1.

I then tried to install libatomic library but it is already installed.

I also tried the answers in this post -> How to solve wrong ELF class: ELFCLASS32

,but that didn't solve the problem neither.

What do I have to do to be able to code in swift in VSCode?

Larry
  • 101
  • 1
  • 4

1 Answers1

1

I think your missing dependencies

$ sudo apt-get install clang libpython-dev libblocksruntime-dev

I had the same error setting up swift-tensorflow (CPU only)

https://github.com/tensorflow/swift/blob/master/Installation.md

Conor
  • 111
  • 1