linuxarchlinuxbarrierlibcrypto

How to fix an error `libcrypto.so.3: cannot open shared object file: No such file or directory"?


Premise

I want to share a single keyboard between two computers(ArchLinux and Windows), and there are some options to realize it on.

I choiced an option using Barrier.

Expect

Following steps bellow on a ArchLinux machine and verify there are no error:

Installing barrier : $ sudo pacman -S barrier

Using barrier : $ barrier

Actual

I got error at the step using barrier.

The error message is : barrier: error while loading shared libraries: libcrypto.so.3: cannot open shared object file: No such file or directory

Question

How to fix "No such file or directory" about libcrypto.so.3?

Additional information

Commands output

$ ldd /usr/bin/barrier | grep libcrypto
        libcrypto.so.3 => not found
        libcrypto.so.1.1 => /usr/lib/libcrypto.so.1.1 (0x00007fcf0f000000)
$ sudo ldconfig -p | grep libcrypto
        libcrypto.so.1.1 (libc6,x86-64) => /usr/lib/libcrypto.so.1.1
        libcrypto.so (libc6,x86-64) => /usr/lib/libcrypto.so

Tried things

  1. Executed sudo barrier, nothing new.
  2. Searched Barrier issues on github, and I obtained no result about the problem not found libcrypto.

Solution

  • How to fix

    At the issue in my Github repository , I knew that libcrypto is a library that is included the package openssl .

    And I did reinstalling openssl, installing openssl-1.1 and executing command $ barrier, no error, Barrier was launched.

    Cause of error

    Probablly, The error was occured by I had not the library libcrypto.so.3in my machine. So, when I reinstalliing openssl (i.e. update by pacman -Sy openssl), the library is placed in /usr/lib, and the error had dissapeared.

    References

    1. OpenSSL's issue
    2. StackOverflow's answer