From: Ricardo Wurmus <ricardo.wurmus@mdc-berlin.de>
To: Guix-devel <guix-devel@gnu.org>
Subject: ccall mechanism in Julia
Date: Fri, 6 Mar 2015 16:48:59 +0100 [thread overview]
Message-ID: <idjpp8mqg7o.fsf@bimsb-sys02.mdc-berlin.net> (raw)
Hi Guix,
I'm currently packaging up Julia, a programming language for technical
computing. When I configure the build process such that system
libraries are used instead of the bundled copies I run into a problem.
Julia's bindings to these libraries use the ccall mechanism; ccall
builds a map from library names to paths by parsing the output of
"ldconfig -p" at runtime. I worked around this problem by patching the
sources to include a static map of library names to store paths. Then I
noticed, however, that my patch effectively cripples the FFI. It is no
longer possible to call a function that is exported by a shared library
unless it happens to be in the static map that is created at build time.
Before I hack a little more on the sources to implement a solution that
also considers libraries that happen to lie around in
~/.guix-profile/lib I would like to ask for comments.
Would it be a very bad idea if I wrote a simple replacement for
"ldconfig -p" that returned all libraries in the user's profile? I
don't think this would be as bad as breaking the FFI and hard-coding
build-time paths to inputs.
What do you think?
~~ Ricardo
next reply other threads:[~2015-03-06 15:49 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-06 15:48 Ricardo Wurmus [this message]
2015-03-06 22:25 ` ccall mechanism in Julia Andreas Enge
2015-03-08 14:35 ` Ricardo Wurmus
2015-03-09 9:09 ` Ludovic Courtès
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=idjpp8mqg7o.fsf@bimsb-sys02.mdc-berlin.net \
--to=ricardo.wurmus@mdc-berlin.de \
--cc=guix-devel@gnu.org \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.