unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: Andy Wingo <wingo@pobox.com>
To: Maxime Devos <maximedevos@telenet.be>
Cc: guile-devel@gnu.org
Subject: Re: Linking to libraries in the ELF?
Date: Tue, 09 Mar 2021 22:04:05 +0100	[thread overview]
Message-ID: <875z202g56.fsf@pobox.com> (raw)
In-Reply-To: <875z3fr9yf.fsf@telenet.be> (Maxime Devos's message of "Fri, 29 Jan 2021 17:20:40 +0100")

On Fri 29 Jan 2021 17:20, Maxime Devos <maximedevos@telenet.be> writes:

> I've got this crazy idea a few days ago, about the FFI interface.
> When a program written in C is compiled with some shared libraries,
> these libraries are referred to in special [insert ELF terminology
> here] of the binary.  I wonder if it would be reasonable and feasible
> to do something similar for compiles guile modules?

These sections of executables or shared libraries are actually
*interpreted* by the system dynamic library loader, ld.so.  Guile has
its own loader, independent of ld.so, and so can implement this -- or do
more flexible things.  In any case we probably shouldn't tie ourselves
to the particular implementation of a particular loader.

Of course, dynamic-link was... not a great interface.  But with the
recent changes in git I think it can be fine (see "Foreign Libraries" in
the manual).  For the FFI the bigger problem IMO is generating faster
foreign procedure bindings -- i.e. farther on the
compilation-vs-interpretation scale.

Cheers,

Andy



      reply	other threads:[~2021-03-09 21:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-29 16:20 Linking to libraries in the ELF? Maxime Devos
2021-03-09 21:04 ` Andy Wingo [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875z202g56.fsf@pobox.com \
    --to=wingo@pobox.com \
    --cc=guile-devel@gnu.org \
    --cc=maximedevos@telenet.be \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).