Subject: bug#39079: SBCL CFFI from Guix unable to find dynamic libraries

From: Pierre Neidhardt <[email-masked]>
Date: Mon, 13 Jan 2020 23:22:28 +0100

Hi!

Evan Straw <[email-masked]> writes:

> However, the thing that still doesn't appear to be working right is loading
> libraries from the foreign distro. I get the same behavior as before when
> attempting to load a library under the foreign distro's library directory
> (/usr/lib/x86_64-linux-gnu): It loads the library itself but fails upon trying
> to load any dependencies, even if they are in the same directory.

What are "dependencies" here?
Can you provide a full recipe of what you are trying to do, including
your .sbclrc and the Lisp code snippets you've run to test this?

> Ideally, I would just install the libraries I need from Guix, but I
> specifically want to interface with a library from the system, in this
> case PulseAudio (I've just been using libcurl as a test to make sure
> it works).

Does it work for the libraries installed with Guix?

> I did some investigation and tried both installing just CFFI from another
> source, and then SBCL itself. Installing CFFI from Quicklisp but keeping SBCL
> from Guix gave the same behavior and was unable to load dependencies of the
> library. Installing SBCL from APT and CFFI from Quicklisp was able to load the
> library and all dependencies with no issues. From this, I'm wondering if it's a
> problem with SBCL itself instead of CFFI?

This seems to be a red herring, as Guix does not change how CFFI loads
libraries.  The only thing that changes is where the libraries are found
with Guix packages.

Let's see what we can reproduce with your examples! :)

-- 
Pierre Neidhardt
https://ambrevar.xyz/