all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: ludo@gnu.org (Ludovic Courtès)
To: guix-devel@gnu.org, Marius Bakke <mbakke@fastmail.com>
Subject: kodi: LD_LIBRARY_PATH vs. RUNPATH
Date: Tue, 21 Mar 2017 14:10:20 +0100	[thread overview]
Message-ID: <87k27i3hdv.fsf_-_@gnu.org> (raw)
In-Reply-To: <20170321115837.12BE620EBA@vcs0.savannah.gnu.org> (Marius Bakke's message of "Tue, 21 Mar 2017 07:58:37 -0400 (EDT)")

Hi Marius,

mbakke@fastmail.com (Marius Bakke) skribis:

> commit 4b9a5bd990a4c734828571147f9fec01c7053fcc
> Author: Marius Bakke <mbakke@fastmail.com>
> Date:   Tue Mar 21 07:02:36 2017 +0100
>
>     gnu: kodi: Wrap executable so it finds libcurl.
>     
>     * gnu/packages/kodi.scm (kodi)[arguments]: Add 'wrap' phase.

[...]

> +         (add-after 'install 'wrap
> +           (lambda* (#:key inputs outputs #:allow-other-keys)
> +             (let ((out (assoc-ref outputs "out"))
> +                   (curl (string-append (assoc-ref inputs "curl") "/lib")))
> +               (wrap-program (string-append out "/bin/kodi")
> +                 `("LD_LIBRARY_PATH" suffix (,curl)))
> +               #t))))))

I think it would be nicer to add libcurl to the RUNPATH of kodi, by
adding -Wl,-rpath=/…/curl/lib to the LDFLAGS for the ‘kodi’ executable,
rather than clobbering LD_LIBRARY_PATH (that’s more “controlled” and
less intrusive).

Perhaps that’s more complicated to do though (finding the right makefile
or makefile variable to pass, etc.)

WDYT?

Thanks,
Ludo’.

PS: Apologies if I missed an earlier discussion of this!

       reply	other threads:[~2017-03-21 13:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20170321115836.24499.97319@vcs0.savannah.gnu.org>
     [not found] ` <20170321115837.12BE620EBA@vcs0.savannah.gnu.org>
2017-03-21 13:10   ` Ludovic Courtès [this message]
2017-03-21 13:50     ` kodi: LD_LIBRARY_PATH vs. RUNPATH Marius Bakke

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=87k27i3hdv.fsf_-_@gnu.org \
    --to=ludo@gnu.org \
    --cc=guix-devel@gnu.org \
    --cc=mbakke@fastmail.com \
    /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.