2

I just installed a fresh FreeBSD but when I try to install emacs with pkg install emacs, I've the following error.

ld-elf.so.1: Shared object "libssl.so.9" not found, required by "pkg". 

The only thing I've done is portsnap fetch extract

Aside ls, cd and man, it's the second command on this system.

Any idea?

2
  • portsnap is for ports, not packages. You do not need to do that. As always, refer to the most excellent FreeBSD Handbook for information. Commented Oct 29, 2018 at 12:52
  • Which version of FreeBSD is this? I have had the same issue with 12.0-BETA2 - its related to a recent update to OpenSSL in the base system. Some parts of the system are still playing catchup. Commented Oct 30, 2018 at 9:39

2 Answers 2

2

You need to install openssl:

pkg install openssl 

That will provide you with libssl.so.9 which will be located here:

/usr/local/lib/libssl.so.9 

After that, you can:

pkg install emacs 

If pkg on your system just won't execute then you can use one of the following first:

pkg-static bootstrap -f pkg-static install pkg -f 
4
  • 2
    You have to use pkg-static instead. Commented Oct 28, 2018 at 3:50
  • @arrowd No, you don't. I successfully installed it with pkg install. Commented Oct 28, 2018 at 3:52
  • 2
    But OP isn't able to do so. You see, his pkg executable can't start. Commented Oct 28, 2018 at 10:21
  • @arrowd This is a fresh install. Had he upgraded then pkg may have depended on dynamic libraries. If it just won't start then what he actually needs is pkg bootstrap or pkg-static install pkg. He can then use pkg with no issues so he doesn't have to use pkg-static to install emacs (which is what he is trying to) and your comment isn't providing enough information as it doesn't show anything about what actually needs to be done. Commented Oct 29, 2018 at 0:00
0

The only way I got it to work was by disabling the fingerprint and signature_type in the /etc/pkg/FreeBSD.conf, this is a known bug as per the forum and this is the only alternative I found to the ever time consuming alternative to portsnap fetch.

FreeBSD: { url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest", mirror_type: "srv", #signature_type: "fingerprints", #fingerprints: "/usr/share/keys/pkg", enabled: yes } 

Yes, I know it makes security a concern.

You must log in to answer this question.