From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id eKt9E99Gc1/8dgAA0tVLHw (envelope-from ) for ; Tue, 29 Sep 2020 14:38:23 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id gJpnD99Gc18gTgAA1q6Kng (envelope-from ) for ; Tue, 29 Sep 2020 14:38:23 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A71749404D2 for ; Tue, 29 Sep 2020 14:38:22 +0000 (UTC) Received: from localhost ([::1]:47866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kNGDW-0007K0-Ac for larch@yhetil.org; Tue, 29 Sep 2020 10:02:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46364) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kNGDL-0007HB-Ax for help-guix@gnu.org; Tue, 29 Sep 2020 10:02:43 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:37755) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kNGDK-0004ef-5g; Tue, 29 Sep 2020 10:02:42 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=58402 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kNGDI-0003Zo-UA; Tue, 29 Sep 2020 10:02:41 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: divoplade Subject: Re: How do I set LTDL_LIBRARY_PATH? References: <5e8245d2af36f13d6119b53cd14c2ebd7ca8fdf8.camel@divoplade.fr> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 8 =?utf-8?Q?Vend=C3=A9miaire?= an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Tue, 29 Sep 2020 16:02:38 +0200 In-Reply-To: <5e8245d2af36f13d6119b53cd14c2ebd7ca8fdf8.camel@divoplade.fr> (divoplade's message of "Thu, 17 Sep 2020 22:58:36 +0200") Message-ID: <87zh5865q9.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: help-guix@gnu.org Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: "Help-Guix" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of help-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=help-guix-bounces@gnu.org X-Spam-Score: -0.51 X-TUID: E83U0sVLIIcP Hi, divoplade skribis: > I have written a small C guile module to access (some parts of) the GNU > nettle library. I can install it with guix, but then if I try to load > it from within an environment: > > guix environment --ad-hoc guile guile-nettle -- guile < (load-extension "libguile-nettle" "init_nettle") > EOF > > guile does not find "libguile-nettle" (In procedure dynamic-link: file: > "libguile-nettle", message: "file not found") > > This is because guile expects it to be in LTDL_LIBRARY_PATH, and guix > does not set that up. Common practice is to arrange so that bindings refer to C libraries by absolute file name. For example: --8<---------------cut here---------------start------------->8--- $ grep /libgcrypt $(find $(guix build guile-gcrypt) -name \*config.scm) "/gnu/store/qc3k3kd458pgrqsc7ih641160q81npwq-libgcrypt-1.8.5/lib/libgcryp= t") $ grep /libz $(find $(guix build guile-zlib) -name \*config.scm) "/gnu/store/rykm237xkmq7rl1p0nwass01p090p88x-zlib-1.2.11/lib/libz") --8<---------------cut here---------------end--------------->8--- HTH! Ludo=E2=80=99.