guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

extension paths


From: Linas Vepstas
Subject: extension paths
Date: Thu, 26 Jan 2017 15:51:36 -0600

I'd like to ask for help/clarification (and maybe even volunteer to
write the required code) to resolve this extension-loading problem.

I have almost a dozen C++ shared libs that implement guile modules,
and regularly struggle to get them loaded correctly.   First, they
need to be installed into one of 8 different places:

    /usr/lib/guile/2.0/extensions
    /usr/local/lib/guile/2.0/extensions
    /usr/lib64/guile/2.0/extensions
    /usr/local/lib64/guile/2.0/extensions
    /usr/lib/guile/2.2/extensions
    /usr/local/lib/guile/2.2/extensions
    /usr/lib64/guile/2.2/extensions
    /usr/local/lib64/guile/2.2/extensions

which is unworkable in practice.  So what I usually do is to install
wher I want to, and then do this:

(setenv "LTDL_LIBRARY_PATH"
   (if (getenv "LTDL_LIBRARY_PATH")
      (string-append (getenv "LTDL_LIBRARY_PATH") ":" path)
      path))

(load-extension "libblah" "blah_guile_init")

so that libblah gets found via the env variable.  But this too, is not
always ... stable. What I'd like to have is something like

(add-to-extension-path "/path/to/whereever")

that gets searched, when loading guile extensions...

Comments? Suggestions?

--linas



reply via email to

[Prev in Thread] Current Thread [Next in Thread]