Install Swift on CentOS (Red Hat)

I would like to use the Swift language in my workplace.
swift.org currently provides binaries only for Ubuntu 14.04 and 15.10
. My workstation uses CentOS 6.6 (similar to Red Hat 6).

I tried running a binary file that throws this error message:

swift: error while loading shared libraries:
libedit.so.2: cannot open shared object file: No such file or directory

The build instructions for Ubuntu are here:
https://github.com/apple/swift/blob/master/README.md

Can anyone provide binaries or build instructions for CentOS 64-bit?

+4
source share
5 answers

, Swift . , :

http://www.swiftprogrammer.info/swift_centos_2.html

CentOS 6.7, , , 6.6. , , Apple Ubuntu:

  • Swift- (swiftc) (swift) .
  • REPL .

, Swift . , github .

, , - , Swift Linux . , Swift Linux, , Mac OS X iOS, Foundation, Linux, , Linux , Apple . Apple Ubuntu.

, , !

+2

Swift 3.0 Preview 6 Ubuntu 14.04 (), , CentOS x64 7.2. 'swift' 'swiftc:'

sudo ln -s /lib64/libedit.so.0 /lib64/libedit.so.2
sudo ln -s /usr/lib64/libicuuc.so /usr/lib64/libicuuc.so.52
sudo ln -s /usr/lib64/libicui18n.so /usr/lib64/libicui18n.so.52
+2

libedit.so libedit.so.2, swift Atom, , , - , : sudo ln -s/usr/include/sys//usr/include/x86_64-linux-gnu/sys

+1

Debian Red Hat API

libedit.so.2 rhel libedit.so.0.0.42. .

cd /usr/lib64
ln -s libedit.so libedit.so.2

, , , Centos 7.

 error: failed to launch REPL process: process launch failed: 'A' packet returned an error: -1

lldb. , ( 15/12/03), lldb IOS.

I would like to post this as a comment, but I can’t because of my insufficient reputation. Perhaps someone with lldb knowledge can give some advice on how to move further from this point.

0
source

In addition to the mgmart request, you may need to install bsdlib and symlink for versions of libicu18n.so and libicuuc.so in Red Hat.so

In Fedora, I used the following commands:

ln -s /usr/lib64/libicui18n.so.54 /usr/lib64/libicui18n.so.55
ln -s /usr/lib64/libicuuc.so.54 /usr/lib64/libicuuc.so.55
0
source

Source: https://habr.com/ru/post/1618475/


All Articles