mailing list of musl libc
 help / color / mirror / code / Atom feed
* Deploying a dynamic executable on glibc systems - how?
@ 2016-09-15 13:20 Jon Chesterfield
  2016-09-15 15:14 ` Rich Felker
  0 siblings, 1 reply; 2+ messages in thread
From: Jon Chesterfield @ 2016-09-15 13:20 UTC (permalink / raw)
  To: musl

[-- Attachment #1: Type: text/plain, Size: 1090 bytes --]

Hi all,

I have just been through the process of shipping a program built on a
recent glibc system for use on an old one. This has left me looking for an
alternative.

In general, I like the approach of statically linking everything and
shipping the single enormous binary. This solves the compatibility problems
in exchange for removing dynamic linking.

Unfortunately I also like dlopen and the combination of static linking and
dlopen is an unhappy one.

My thoughts on resolving this are:
1/ link the entire musl libc into a static main executable
2/ put all the symbols in a table analogous to a plt in this executable
3/ hack the loader to look in said table
4/ open plugin using dlopen

The idea is to keep main static enough that it doesn't need the system
loader to start, yet dynamic enough that libc can be exported.

However, "first hack the loader" suggests there may be a better way. I'm
essentially looking for a way of deploying an application that can load
plugins without also installing the musl loader to the host. Can someone
see a better solution?

Kind regards,

Jon

[-- Attachment #2: Type: text/html, Size: 1285 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-09-15 15:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-15 13:20 Deploying a dynamic executable on glibc systems - how? Jon Chesterfield
2016-09-15 15:14 ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

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 NNTP newsgroup(s).