<div dir="ltr">This is tricky; three options:<div>1) patch the files to use your ld-linux; patchelf is supposed to be able to do this, but when I tried --set-interpreter on a simple binary I got this error:<br></div><div><div>cannot find section .interp</div><div><br></div><div>You could still patch it in ugly ways.</div><div><br></div><div>2) you can wrap your commands in shell scripts which run the linker; you have a stable interface in the form of POSIX shell script /bin/sh; it goes like this:</div><div>./copy-of-ld --inhibit-cache ./foo</div><div><br></div><div>3) you can set the interpreter at build time; this is supposedly done with -Wl,--dynamic-linker=foo, but by default your toolchain probably uses linker scripts which will set a different linker. You may dump the default linker script and override it (gcc -T) with your own fork.</div><div><br></div><div>In any case I'd be interest to read about why you want to avoid the ld-linux dep and how you implement it in the end.  :-)</div><div><br></div><div>Cheers,</div><div>- Loïc Minier</div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div>







</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jul 21, 2016 at 12:14 PM, Martin Winter <span dir="ltr"><<a href="mailto:mwinter@opensourcerouting.org" target="_blank">mwinter@opensourcerouting.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi there,<br>
<br>
I’m currently failing on my package with this error.<br>
<br>
I have the libc6 included as a stage package, but trying to find the correct linker option<br>
to actually use the library included in snap instead of the system wide one.<br>
<br>
Anyone knows how to get gcc/ld to use the correct library?<span class="HOEnZb"><font color="#888888"><br>
<br>
- Martin<br>
<br>
-- <br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.ubuntu.com" target="_blank">Snapcraft@lists.ubuntu.com</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailman/listinfo/snapcraft</a><br>
</font></span></blockquote></div><br></div>