* kodi: LD_LIBRARY_PATH vs. RUNPATH
[not found] ` <20170321115837.12BE620EBA@vcs0.savannah.gnu.org>
@ 2017-03-21 13:10 ` Ludovic Courtès
2017-03-21 13:50 ` Marius Bakke
0 siblings, 1 reply; 2+ messages in thread
From: Ludovic Courtès @ 2017-03-21 13:10 UTC (permalink / raw)
To: guix-devel, Marius Bakke
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!
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: kodi: LD_LIBRARY_PATH vs. RUNPATH
2017-03-21 13:10 ` kodi: LD_LIBRARY_PATH vs. RUNPATH Ludovic Courtès
@ 2017-03-21 13:50 ` Marius Bakke
0 siblings, 0 replies; 2+ messages in thread
From: Marius Bakke @ 2017-03-21 13:50 UTC (permalink / raw)
To: Ludovic Courtès, guix-devel
[-- Attachment #1: Type: text/plain, Size: 1506 bytes --]
Ludovic Courtès <ludo@gnu.org> writes:
> 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?
I agree, this was a lazy fix on my part to enable some expected
functionality (scraping, add-ons) because I could not figure out how to
pass LDFLAGS (the environment variable was not enough).
Will work on a proper fix; adding it to the 'kodi-test' executable
should also sort the failing web tests, methinks.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-03-21 13:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20170321115836.24499.97319@vcs0.savannah.gnu.org>
[not found] ` <20170321115837.12BE620EBA@vcs0.savannah.gnu.org>
2017-03-21 13:10 ` kodi: LD_LIBRARY_PATH vs. RUNPATH Ludovic Courtès
2017-03-21 13:50 ` Marius Bakke
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
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).