History log of /bionic/linker/linker_environ.cpp
Revision Date Author Comments
eb847bc8666842a3cfc9c06e8458ad1abebebaf0 10-Oct-2013 Elliott Hughes <enh@google.com> Fix x86_64 build, clean up intermediate libraries.

The x86_64 build was failing because clone.S had a call to __thread_entry which
was being added to a different intermediate .a on the way to making libc.so,
and the linker couldn't guarantee statically that such a relocation would be
possible.

ld: error: out/target/product/generic_x86_64/obj/STATIC_LIBRARIES/libc_common_intermediates/libc_common.a(clone.o): requires dynamic R_X86_64_PC32 reloc against '__thread_entry' which may overflow at runtime; recompile with -fPIC

This patch addresses that by ensuring that the caller and callee end up in the
same intermediate .a. While I'm here, I've tried to clean up some of the mess
that led to this situation too. In particular, this removes libc/private/ from
the default include path (except for the DNS code), and splits out the DNS
code into its own library (since it's a weird special case of upstream NetBSD
code that's diverged so heavily it's unlikely ever to get back in sync).

There's more cleanup of the DNS situation possible, but this is definitely a
step in the right direction, and it's more than enough to get x86_64 building
cleanly.

Change-Id: I00425a7245b7a2573df16cc38798187d0729e7c4
42b2c6a5eed5e4ef35315b8cd32d1355f12a69b6 07-Feb-2013 Elliott Hughes <enh@google.com> Clean up the argc/argv/envp/auxv handling.

There's now only one place where we deal with this stuff, it only needs to
be parsed once by the dynamic linker (rather than by each recipient), and it's
now easier for us to get hold of auxv data early on.

Change-Id: I6314224257c736547aac2e2a650e66f2ea53bef5
4df577fef74063507cba229bce352bbcf89df279 18-Jan-2013 Guang Zhu <guangzhu@google.com> Revert "Filter ANDROID_PROPERTY_WORKSPACE"

Temporarily revert the change since DNS resolution seems
broken right now in ping util.

Bug: 8029617

This reverts commit a0f64756a4a55ab48b2b5511d4e7c45583dac44b.
bf1d22559376aa5c3fff5c278a90fd0832ec6207 18-Jan-2013 Guang Zhu <guangzhu@google.com> Revert "Filter ANDROID_PROPERTY_WORKSPACE"

Temporarily revert the change since DNS resolution seems
broken right now in ping util.

Bug: 8029617

This reverts commit a0f64756a4a55ab48b2b5511d4e7c45583dac44b.
a0f64756a4a55ab48b2b5511d4e7c45583dac44b 16-Jan-2013 Nick Kralevich <nnk@google.com> Filter ANDROID_PROPERTY_WORKSPACE

When executing a setuid executable, filter out ANDROID_PROPERTY_WORKSPACE
from the environment. Some applications implicitly trust the property
space and don't realize that it's passed by an environment variable
which can be modified by the caller.

Change-Id: I3e3a98941f0a1f249a2ff983ecbcfe1278aa9159
0894b2c5d35c9c3a7483ed8faaf65fd6d9ffb00b 02-Nov-2012 Elliott Hughes <enh@google.com> Cleaning the linker environment as we initialize it requires less API.

Change-Id: I612fd699e46833a411589478564a1f859223c380
18a206c81d9743481e364384affd43306911283d 30-Oct-2012 Elliott Hughes <enh@google.com> More dynamic linker cleanup.

I still want to break linker_format out into its own library so we can reuse
it for malloc debugging and so forth. (There are many similar pieces of code
in bionic, but the linker's one seems to be the most complete/functional.)

Change-Id: If3721853d28937c8e821ca1d23cf200e228a409a