We already had implementations of some of the functions, and I didn't
bother rewriting them when we added sysinfo(2). Ross Anderson said in
https://www.lightbluetouchpaper.org/2016/07/29/yet-another-android-side-channel/
that we should "simply disable access to all procfs files", which made
me curious how many places we use /proc in bionic. This is the one that's
obviously unnecessary. The others I'm not aware of alternative APIs for.
Change-Id: Ia64f36b76f29a7a1dd67845270a5472e121aae10
Move soinfo and globals out of linker.cpp to
separate files.
Breaking up huge linker.cpp into smaller peaces
in order to make it easier to extract part of the
code that belongs to libdl.so and remove parts of
the code that do not belong to linker
(refactoring part 2 of many)
Change-Id: I868417f4b8d2b84d0e8265e354bc7977161497e2
Breaking up huge linker.cpp into smaller peaces
in order to make it easier to extract part of the
code that belongs to libdl.so and remove parts of
the code that do not belong to linker
(refactoring part 1 of many)
Change-Id: I57ac36677a815800dc127c8c45c3ea806c37e247
Test: bionic-unit-tests --gtest_filter=dl*:Dl*
This assumes that it's more likely we're unlinking a file than a directory,
though even if that's not true, as long as a failed unlink(2) is cheaper
than a successful lstat(2) -- which seems likely since there's no data to
copy -- we still win.
Change-Id: I0210e9cd3d31b8cf1813c55c810262ef327382ed
Bionic stdatomic.h is also used for the host (via a copy in
prebuilts/clang). Revert to guarding the include of uchar.h based on
__STDC_VERSION__, so it is included only when needed.
Change-Id: I5b45c7f5d16da223478512104702a3e4e5a975ae
Test: bionic tests on host and Angler. Confirmed failures I am
seeing are KIs.
* changes:
Add version information for legacy inlines.
versioner: remove unnecessary kernel/common symlink.
versioner: add symlink for kernel/android/uapi.
With the introduction of new tags for ndk_library, we'll have a lot
of tags that aren't architecture tags. If we have something tagged
`introduced=21`, it should be in all architectures.
Change-Id: Ib67f07db14625f6903919c181050316eb183bed5
The target was moved by commit 5956b4e, but none of the headers
contained were actually necessary to compile any bionic headers.
Bug: http://b/30170081
Change-Id: I8c1a7464de0992c20af194340c0e36d131a836e7
The android-only kernel headers were moved to their own directory by
commit d6e8b8c. Add a new symlink to match.
Change-Id: I06ce7c3167fbb1e058e4a137fae9375bb5792a46
With this change (and all the others below it in the stack), the only
difference between the arm android-9 libc.so in r13-beta1 and the one
we are now generating is the addition of LIBC_N and LIBC_O versions.
Test: make ndk, readelf stub libc.so to check symbol exists
Bug: https://github.com/android-ndk/ndk/issues/160
Change-Id: Iedab32592b2d979f3cc922ffd4ed406427de3dda
These functions were erroneously released in LIBC_PRIVATE for M, but
in fact need to be public. Since we need to be able to load them on M
even if they were built for a lower platform (and M needs to load on
newer platforms), we need to unversion them.
Change-Id: I333fe8ae7380cc2a5dbd699414399ec52f602383
This change includes dlwarning implementation and
the compatibility greylist for apps targeting pre-N.
Change-Id: Ibf02a07cc58cbbb1a5aef4ac34558c5d43e4305f
Test: Run bionic-unit-tests --gtest_filter=dl*:Dl*
When __memset_chk_fail moved to C++, we didn't take into account
that the stack wasn't set up correctly for the jump from assembler.
Presumably no one had run the 32-bit x86 tests until now!
Bug: http://b/30513094
Change-Id: Iab9fbc731b6bfecd7ca4d3f3844d0568a5d30d86
clang doesn't support attribute alloc_size, but GCC uses it to give
diagnostics where clang can't, and we had a test for one such case.
Bug: http://b/30513330
Change-Id: I4c14771258992d6bea684db7f91d60312642662f