Commit graph

18 commits

Author SHA1 Message Date
Dan Albert
4d4a7832ad Add a few more legacy inlines for strto*_l.
These three functions are the only reason we need libandroid_support
post-L. Add these so we can remove it entirely for LP64 or users
targeting L+.

Test: make checkbuild
Test: build/soong/scripts/build-ndk-prebuilts.sh
Test: Imported the prebuilts generated from the above to the NDK,
      `./checkbuild.py && ./run_tests.py` with a handful of patches
      to remove libandroid_support for L+.
Bug: None

Change-Id: I39f8ee686bd76ebdb2fc3745b013d56175ba8ff0
2018-02-06 13:45:29 -08:00
Dan Albert
989d804859 Reland "Cleanup transitive includes in the legacy inlines."
This reverts commit 54c71521b5.

Bug: None
Test: make checkbuild
Change-Id: Ica6a4f7ecadfcc854160a60a5db1b44ae3b6c821
2018-01-18 23:39:48 +00:00
Joachim Sauer
54c71521b5 Revert "Revert "Revert "Revert "Revert "Cleanup transitive includes in the legacy inlines."""""
This reverts commit a074ac79d7.

Reason for revert: Broke several builds.

Change-Id: I406f0b0aa0c37961ad031d2f6c5ea4241f3f1111
2018-01-18 11:37:34 +00:00
Dan Albert
a074ac79d7 Revert "Revert "Revert "Revert "Cleanup transitive includes in the legacy inlines.""""
This reverts commit b37e9aa9a6.

Reason for revert: trying again
Test: make native
Change-Id: Ide23f0a752fd6ca88e44449e996eb5809db6712d
2018-01-11 09:43:23 -08:00
Ryan Prichard
51a7fe8fbd Mark abs/labs/llabs as 19+ rather than 21+
The libc.map.txt file already defines these three functions as having
been introduced in API 19, but these header files had declared them as
21 and up.

See https://android-review.googlesource.com/c/platform/development/+/233407

imaxabs is already declared as 19 and up.

Test: build-ndk-prebuilts.sh && ./update_platform.py &&
  checkbuild.py && run_tests.py
Test: manually build app against 18 and 19

Change-Id: Iaeed48d7e6c438d816635a0433a056e557e8ebc2
2018-01-08 17:46:27 -08:00
Dan Albert
b37e9aa9a6 Revert "Revert "Revert "Cleanup transitive includes in the legacy inlines."""
This reverts commit f945fb6b8a.

Reason for revert: haven't fixed all the builds yet

Change-Id: I55aff5d0290c27691427d91a8e46ae01c87da6b2
2017-10-24 09:20:41 +00:00
Dan Albert
f945fb6b8a Revert "Revert "Cleanup transitive includes in the legacy inlines.""
This reverts commit 9cb8639b18.

Fixed all the broken builds that were reported to me before this was
reverted.

Test: make checkbuild  # kikey960, marlin, aosp_arm64; master and aosp
2017-10-17 11:07:26 -07:00
Orion Hodson
9cb8639b18 Revert "Cleanup transitive includes in the legacy inlines."
This reverts commit 43df953502.

Reason for revert: Breaks most AOSP builds.
https://android-build.googleplex.com/builds/branch-dashboard/aosp-master?build_id=4399910

Change-Id: I53459f97b7dffb1f7f602db03893564dd3cfe6bf
2017-10-17 08:41:23 +00:00
Dan Albert
43df953502 Cleanup transitive includes in the legacy inlines.
We don't want to be exposing so much through the headers for the
implementation details unless we have to.

Test: make checkbuild
Bug: None
Change-Id: Ieca9cd8106725e08887a3e9fde60d1eef64ef98b
2017-10-13 14:39:03 -07:00
Elliott Hughes
2f94a29d9c Rename _Exit in a way that works with libandroid_support.
Bug: N/A
Test: builds
Change-Id: I2aeaf9bafe7d51e91b67f22d68f4e52191df062b
2017-09-19 18:34:40 +00:00
Dan Albert
cd8828c346 Put back the _Exit rename for pre-L.
Somehow I accidentally removed this in
https://android-review.googlesource.com/c/445150.

Test: make checkbuild
Bug: None
Change-Id: Ia6744af6c7b6dc2f149e9eab6e1f39863f96f6ca
2017-08-07 14:47:00 -07:00
Dan Albert
bd3f657e56 Fix error condition on strtof inline.
Test: make checkbuild
Test: pull into ndk, ./run_tests.py
Bug: https://github.com/android-ndk/ndk/issues/415
Change-Id: I1575f799c9e849d66456c785208a36709a7b8122
2017-07-26 17:21:47 -07:00
Elliott Hughes
79dd9889d1 Work around missing _Exit in old API levels.
Rather than do this in libandroid_support, we may as well just stick it with
the other historical stdlib workarounds in bionic itself...

Bug: N/A
Test: built new NDK test
Change-Id: Ia5cf4010581eb79d4adf924e87d0bc050b9e2839
2017-06-30 16:39:25 -07:00
Elliott Hughes
5bc78c8bcd Add and use constants for the Android API levels.
Test: bionic tests still pass
Change-Id: If1b619cfc9db1d3f5d91f14f2ace71058dca0c4a
2016-11-16 16:55:42 -08:00
Dan Albert
a3ce418ca6 Revert "Add legacy inlines for locale aware APIs."
We can't really add these to the unified headers yet since we're
still using the old headers as well, and libandroid_support needs to
work with both. These functions are already defined in
libandroid_support, so when using unified headers we'll get duplicate
definitions.

This was only going to be a temporary solution anyway. Instead we'll
just rely on libandroid_support (and eventually its rewrite) to handle
these.

This reverts commit 6576a3749b.

Test: ./tools/update_headers.py && make ndk && make native
      # Copied into working directory for unified headers NDK work.
      ndk/checkbuild.py
      ndk/run_tests.py --force-unified-headers
Bug: None

Change-Id: I5762e815e2030c89d7f2540df08dd67b6c2d10a5
2016-10-31 16:47:22 -07:00
Dan Albert
6576a3749b Add legacy inlines for locale aware APIs.
Test: make checkbuild tests
Bug: http://b/31639993
Change-Id: Ic43d690dff3c6960d7826bd0b064640a3ea0e883
2016-09-22 00:44:37 -07:00
Josh Gao
b8e1b705d1 Make the legacy inline headers compile standalone.
It's useful to have the legacy inlines compile by themselves, both to
make header unification easier, and to ensure that the inline versions
match the regular declarations. Notably, this wasn't true for
sigismember, which took a const sigset_t* in the regular header, and
sigset_t* in the inline version.

Bug: http://b/28178111
Change-Id: Id8a3b7dcb1bfa61eed93c9fb50d3192744f8bef5
2016-04-15 13:06:08 -07:00
Dan Albert
466dbe4444 Put back inline definitions if using an old API.
All these inlines were turned in to out of line definitions in L.
This brings us a step closer to being able to just use the current
bionic headers for the NDK, rather than having many old versions of
them.

Change-Id: Ie010bc727d78d3742abc577c70f6578db2e68625
2015-01-29 17:30:40 -08:00