mailing list of musl libc
 help / color / mirror / code / Atom feed
* How to build libc.a with -fPIC for all archive members?
@ 2014-02-10 12:35 Oliver Schneider
  2014-02-10 13:27 ` Oliver Schneider
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Oliver Schneider @ 2014-02-10 12:35 UTC (permalink / raw)
  To: musl

Hi,

how can I build the static library from the musl source, but compiling
with -fPIC?

I tried the obvious:

CFLAGS=-fPIC ./configure --enable-gcc-wrapper --disable-shared

and then built. But I am getting the following linker error still
(albeit for a different member function and object file than before):

/usr/local/musl/lib/libc.a(memmove.o): relocation R_X86_64_PC32 against
symbol `memcpy' can not be used when making a shared object; recompile
with -fPIC
final link failed: Bad value

The reason I want to do this, is to have a statically linked .so. I.e.
an .so that has no external dependency other than the system calls. Or
is this known to conflict with the ever-present glibc in some way?

Thanks for any insight into how to resolve this,

// Oliver


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

end of thread, other threads:[~2014-02-10 19:43 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-02-10 12:35 How to build libc.a with -fPIC for all archive members? Oliver Schneider
2014-02-10 13:27 ` Oliver Schneider
2014-02-10 14:04   ` Oliver Schneider
2014-02-10 14:07 ` Szabolcs Nagy
2014-02-10 19:43 ` 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).