Commit Graph

220 Commits

Author SHA1 Message Date
Chao-Ying Fu
75f8d8217e Remove unused .ctors, .dtors, and .eh_frame in MIPS crt*_so.S.
Change-Id: I9b2d28c7c189d0f3a2ded694fadd0380cfd8e6e5
2012-08-28 13:21:42 -07:00
Andrew Hsieh
17f2af7e1f am a2b32b34: Merge "Update malloc.h"
* commit 'a2b32b34220a1bdea566502da1e3254c90f62f16':
  Update malloc.h
2012-08-22 01:19:57 -07:00
Andrew Hsieh
a2b32b3422 Merge "Update malloc.h" 2012-08-22 01:08:42 -07:00
Andrew Hsieh
bfb393846b am 143949da: Merge "Add a .note.android.ident section to Android ELF binaries"
* commit '143949daba4c1f040753a9456a5e8d7e505e5045':
  Add a .note.android.ident section to Android ELF binaries
2012-08-21 19:55:56 -07:00
Andrew Hsieh
fc638f96ae Add a .note.android.ident section to Android ELF binaries
See related CL:
  https://android-review.googlesource.com/#/c/37590

Change-Id: I1d5ab2f754731e9995061de560389c0efa121dea
2012-08-21 18:50:08 +08:00
Andrew Hsieh
ef423edc2c am e3cfaa6d: Merge "Enclosed functions in fenv.h with __BEGIN_DECLS/__END_DECLS"
* commit 'e3cfaa6d4251136ad6f3221d881ac12786169663':
  Enclosed functions in fenv.h with __BEGIN_DECLS/__END_DECLS
2012-08-21 03:27:39 -07:00
Andrew Hsieh
58a4918b94 Update malloc.h
Remove functions never implemented in bionic from malloc.h

Related CLs:
  https://android-review.googlesource.com/#/c/41728
  https://android-review.googlesource.com/#/c/41731
  https://android-review.googlesource.com/#/c/41717

Change-Id: I06639071e3fb442e2389a932382a88a7318606b9
2012-08-21 18:18:00 +08:00
Andrew Hsieh
a5280d312d Enclosed functions in fenv.h with __BEGIN_DECLS/__END_DECLS
Those are C funcitons

Change-Id: I8f481f29b278b8f28d9ce04635d0f04e9e148cb5
2012-08-21 10:41:51 +08:00
Andrew Hsieh
1148901643 am 7f26cea9: Merge "Update stdint.h; Refresh <arch>/include/machine/* stdint.h: https://android-review.googlesource.com/#/c/41714/ https://android-review.googlesource.com/#/c/40576/ <arch>/include/machine/*: to be consistent with bionic/libc/<arch
* commit '7f26cea9049c087b0552fb0f364ab6142a1ad227':
  Update stdint.h; Refresh <arch>/include/machine/*   stdint.h: https://android-review.googlesource.com/#/c/41714/             https://android-review.googlesource.com/#/c/40576/   <arch>/include/machine/*: to be consistent with      bionic/libc/<arch>/include/machine/*
2012-08-20 05:36:04 -07:00
Andrew Hsieh
bc95f91d24 am e33ad352: Merge "Remove linux-unistd.h"
* commit 'e33ad3528d23349a01113289272ffeff08106cf7':
  Remove linux-unistd.h
2012-08-20 05:36:02 -07:00
Andrew Hsieh
7305bb5363 am ed722f12: Merge "Replace link.h for mips with new version for all platforms"
* commit 'ed722f1242d330bd3fe29ff0793e4c616190ef2d':
  Replace link.h for mips with new version for all platforms
2012-08-20 05:36:01 -07:00
Andrew Hsieh
7f26cea904 Merge "Update stdint.h; Refresh <arch>/include/machine/* stdint.h: https://android-review.googlesource.com/#/c/41714/ https://android-review.googlesource.com/#/c/40576/ <arch>/include/machine/*: to be consistent with bionic/libc/<arch>/include/machine/*" 2012-08-20 05:22:01 -07:00
Andrew Hsieh
e33ad3528d Merge "Remove linux-unistd.h" 2012-08-20 05:21:26 -07:00
Andrew Hsieh
61a3e1462c Update stdint.h; Refresh <arch>/include/machine/*
stdint.h: https://android-review.googlesource.com/#/c/41714/
            https://android-review.googlesource.com/#/c/40576/
  <arch>/include/machine/*: to be consistent with
     bionic/libc/<arch>/include/machine/*

Change-Id: Ieeb44c3e864bf64c4cad4d3c9d94024a7b520181
2012-08-20 18:32:15 +08:00
Pavel Chupin
51d4794277 Replace link.h for mips with new version for all platforms
Update from bionic/libc/include/link.h
For details see https://android-review.googlesource.com/#/c/41705

Change-Id: Ib9e658aa0606584b148e951ad199dc12c2f563c2
Signed-off-by: Pavel Chupin <pavel.v.chupin@intel.com>
2012-08-20 10:48:23 +04:00
Andrew Hsieh
7de8e93107 Remove linux-unistd.h
Change-Id: I95cc89bfacb05d92da658fa533cb75ac65d397bf
2012-08-18 16:08:51 +08:00
Andrew Hsieh
1659906d5e Merge "Retire LOCAL_NDK_VERSION (DO NOT MERGE)" 2012-08-18 01:04:19 -07:00
Andrew Hsieh
8bb4fd7683 Update/Copy fenv.h
Update from bionic/libm/arm/fenv.h
Copy from bionic/libm/mips/fenv.h

Related issue:
  http://code.google.com/p/android/issues/detail?id=36229

Change-Id: I4cba9523ecc466720927798e461fc167d6d6df7c
2012-08-17 19:02:58 +08:00
Andrew Hsieh
b31b79830b Retire LOCAL_NDK_VERSION (DO NOT MERGE)
Change-Id: If37bcae0c5833f195e954a8bfbda6b8686b3705e
2012-08-17 07:17:31 +08:00
Andrew Hsieh
e395327a7c Add comments about why "call" instead of "jump" is used.
Related CL: https://android-review.googlesource.com/#/c/38651

Change-Id: I425e06f08fda90501a686c7e437d4e70fc1e4a1b
2012-07-25 15:39:00 -07:00
Andrew Hsieh
556182feb4 Fix SEGV when unwinding stack pasts __libc_init
Changed "jump __libc_init" to "call __libc_init" otherwise stack unwinding
past __libc_init may get wrong return address and crash the program or do
wield things.  With "call", return address is pushed on stack and unwinding
stops correctly at _start.  Note that __libc_init never returns, so this
fix wonʼt affect normal program execution.  But just in case it "does"
return, jump to address 0 and halt.

Change-Id: Id194fb32adcbf89ae59939cee33c50b5bbdd36fe
2012-06-28 14:28:21 -07:00
Andrew Hsieh
5e30a6ae14 ndk: Add crtbrand.c ; crtbegin_static.S includes "atexit.S" for x86/mips
"atexit" isn't defined in libc.a for x86/mips (unlike their arm's counterpart).
Include atexit.S otherwise app using atexit() may fail to link statically.

Also, add crtbegin.c to brand crtbegin_static/dynamic.c with .note.ABI-tag
section of given API level.  See $NDK/gen-platforms.sh

Change-Id: I2fdbb92119e3ca2da2c1ced6d77e63136ec35c34
2012-06-25 17:58:12 -07:00
Andrew Hsieh
62ef547786 ndk: Remove if_dl.h header
Remove AF_LINK and sockaddr_dl which are specpfic to BSD
(ie. doesn't exist in Linux)

Change-Id: I47fe4cdf76df14af99eaa17cfc366a65aee3f5ae
2012-06-12 10:38:00 +08:00
David 'Digit' Turner
5e7c4e6a57 ndk: Remove prebuilt C runtime objects. Add sources instead.
This patch removes all prebuilt C runtime object files from
the ndk/platforms/ directory. We replace them with equivalent
assembly sources lifted from the following directories:

  bionic/libc/private/      (for __dso_handle.S and __dso_handle_so.S)
  bionic/libc/arch-$ARCH/   (for all others)

Note: This requires that your NDK's gen-platforms.sh script be
      capable of rebuilding the object files from sources.
      See https://android-review.googlesource.com/36822

The goal here is to make it much easier to update these files,
and track their changes relative to the content of bionic/lib.
For example to fix the following issues in the future:

Change-Id: If4c84e2584b0e58ca3585b034bb8a13a8add8ab9
http://code.google.com/p/android/issues/detail?id=26911
http://code.google.com/p/android/issues/detail?id=23203
2012-05-31 10:58:57 +02:00
Raghu Gandham
ae9a5f960c [MIPS] Import signal.h from bionic. This version fixes the
warning emitted by the toolchain
2012-05-02 18:46:58 -07:00
Andrew Hsieh
d0e65433d0 Fixed compilation error #include <android/*h>
Fixed compilation error when header in #include <android/*h> is
included alone.

Fix for rect.h already exists in $ANDROID/frameworks/native/include/android

Change-Id: I7c49e044507581c5ad591f26f99cda6870b411c5
2012-04-20 15:50:10 +08:00
Andrew Hsieh
dab6072046 Refresh development/ndk/platforms/android-9/arch-x86/include/machine
Apply changes in bionic/libc/arch-x86/include/machine to
development/ndk/platforms/android-9/arch-x86/include/machine:

   commit 5fbf2e09921723cfdea75e83c1fac2080f0ad564

Change-Id: Ie0fe711ae4c866d9c1300430d5e9613ccb82da22
2012-04-06 13:29:08 +08:00
David 'Digit' Turner
16c0f25354 ndk: ANativeActivity: Fix 'clazz' member documentation.
As discussed on android-ndk, the member is misnamed

Change-Id: I2a5a1c8dce327ddf9ab7a4d14f4e2fdf62808753
2012-04-03 19:30:08 +08:00
Andrew Hsieh
3f59495d17 Remove auto-gen project.properties
It's auto-gen by tool from default.properties in the same dir, etc.

Change-Id: I081ecb809699d42b707218b08e61b97fc9a51f1a
2012-04-02 18:32:04 +08:00
David 'Digit' Turner
b2f20362ac ndk: <dlfcn.h>: dladdr() takes a 'const void*' parameter, not 'void*'
This is a back-port to API level 8 of a non-ABI-breaking change of the declaration.
2012-04-02 18:15:50 +08:00
Glenn Kasten
00038deedc Native media sample app for NDK API level 14 2012-04-02 18:08:03 +08:00
David 'Digit' Turner
e43487b854 ndk: android-9: Add missing <sys/eventfd.h> header
For some reason, the header was missing from previous NDK releases.
Note: the function symbols are properly listed in arch-$ARCH/symbols/libc.so.functions.txt
2012-04-02 18:05:57 +08:00
David 'Digit' Turner
ef0d31ec73 ndk: <signal.h>: Increase _NSIG definition to 64
This is a minor update to this NDK header to better match the upstream definition.
2012-04-02 18:03:00 +08:00
David 'Digit' Turner
015d0543d2 ndk: <pthread.h>: formatting + updates
This patch improves the formatting of <pthread.h> as exposed by the NDK:

- change '#if __cplusplus' into '#ifdef __cplusplus'
- change C++-style comment into C-style comment

Change-Id: Ib093058e8d7a7554d8329a40e102cde11d065932
2012-04-02 17:59:26 +08:00
David 'Digit' Turner
002d5366b6 ndk: <unistd.h>: minor cleanup
- Cleanup declaration of lseek64() to use off64_t instead of loff_t
- Cleanup declaration of prctl() to use variable number of arguments

The cleanups are performed to better match upstream.

Change-Id: I3c9420e328c3772bbb57dc9108dc879aa698a981
2012-04-02 17:54:27 +08:00
David 'Digit' Turner
3da072d28f ndk: <sys/cdefs.h> minor update
This patch fixes some formatting issues in <sys/cdefs.h>:

- change '#if __STDC_VERSION__ > xxx' into '#if defined(__STDC_VERSION__) && __STDC_VERSION > xxx'
- add __LIBC_HIDDEN__ definition (not technically required, but makes comparing the headers with upstream easier)
2012-04-02 17:41:16 +08:00
David 'Digit' Turner
1fe0de682b ndk: minor header update
<net/ethernet.h>: new header
<netdb.h>: add EAI_ADDRFAMILY definition
2012-04-02 16:07:07 +08:00
David 'Digit' Turner
f4e62ff4a3 ndk: Fix ipv6 related headers
This fixes two minor issues with recent updates to the IPv6 related headers:

- add missing <linux/ipv6.h> kernel header
- avoid conflict in netinet/in6.h, the macro is already defined by <linux/in6.h>
2012-04-02 16:04:42 +08:00
David 'Digit' Turner
6c32dacf97 ndk: Fix <sys/atomics.h> declarations.
The atomic operations exported by the platform's C library do not
provide full memory barriers. This can result in incorrect results
when NDK machine code linked against them runs on multi-core devices.

While the bug has been fixed in the platform, this NDK header change
ensures that any source code that includes <sys/atomics.h> will end
up using a correct implementation of these functions, based on the
corresponding GCC builtins.

These builtins always provide a full barrier and have reasonable
performance. Application developers who depend on <sys/atomics.h>
should recompile their unmodified sources against this version
of the NDK as soon as possible.
2012-04-02 15:59:46 +08:00
David 'Digit' Turner
5704b40d70 ndk: minor update to <netinet/...> headers.
This patch contains a minor update to the netinet headers from the C library.
Most of the changes come from later platform release, but can be safely back-ported
to previous API levels since they don't change the ABI:

- <netinet/icmp6.h>, <netinet/ip6.h>: new headers
- <netinet/in.h>: now always include <linux/ipv6.h> by default
- <netinet/in6.h>: add macros: IN6_IS_ADDR_ULA, IN6ADDR_LOOPBACK_INIT
- <netinet/ip.h>: add macro: IPTOS_MINCOST
- <net/if_ether.h>: always include <sys/types.h> by default.
2012-04-02 15:31:20 +08:00
David 'Digit' Turner
554c5eca78 ndk: libc: Add RLIM_RTTIME to <asm-generic/resource.h>
This is a back-port of a fix that was performed in 4.0.1 to all previous platforms.
2012-04-02 15:14:10 +08:00
David 'Digit' Turner
34c6c855bc ndk: arm: Update <asm/ptrace.h> and <asm/user.h>
This is a minor update to two ARM-specific kernel headers.

- <asm/ptrace.h>: Add two new constants
- <asm/user.h>: Add 'struct vfp_user' and 'struct vfp_user_exc'
2012-04-02 15:11:02 +08:00
Andrew Hsieh
a79e56e2f8 Fixed inconsistent minSdkVersion and target= in NDK samples
Also removed Dummy.java and auto-gen files
Inspired by http://code.google.com/p/android/issues/detail?id=20017
2012-04-02 15:00:03 +08:00
Andrew Hsieh
0523af7ca2 Fixed to #include correct 32-bit headers
Corrected for example <asm/io.h> to include io_32.h instead of io_64.h
(which is missing, BTW).

Copied from the results of commit (same title) in bionic.git:
126601dd3f5303b50033dcb88945d928aa764aa4
2012-04-02 14:35:36 +08:00
Andrew Hsieh
2c9504731b Merge "MIPS platform files for building the NDK" 2012-03-30 19:10:05 -07:00
Raghu Gandham
22d3d88a7a [MIPS] crt* Object files generated from .S files.
The object files are generated with the assembler
built from binutils-2.21
2012-03-30 18:27:51 -07:00
Chao-Ying Fu
718e73cf26 MIPS platform files for building the NDK
Change-Id: If19af75003aeb8872d23d7901f01c434bdc58a5f
2012-03-30 18:09:22 -07:00
Andrew Hsieh
1a94764ca2 Merge "ndk: Add MIPS Platform files which contain C runtime headers and sources of crt* assembler files" 2012-03-28 18:18:15 -07:00
Raghu Gandham
a8a0638b9e ndk: Add MIPS Platform files which contain C runtime headers
and sources of crt* assembler files

Change-Id: I10547e8b589d36a7937a0833d86d4406a232aa2c
Signed-off-by: Raghu Gandham <raghu@mips.com>
2012-03-27 15:45:08 -07:00
Andrew Hsieh
2038b5acc5 am 799fada5: Merge "ndk: Include limits.h in wchar.h as it contains the definitions for INT_MAX and INT_MIN. Without this fix, the following lines will fail when configuring gnu stdlibc++ library. (INT_MAX and INT_MIN are undefined.)"
* commit '799fada598b048b02bf63c0eea9b6d676f9be142':
  ndk: Include limits.h in wchar.h as it contains the definitions for INT_MAX and INT_MIN. Without this fix, the following lines will fail when configuring gnu stdlibc++ library. (INT_MAX and INT_MIN are undefined.)
2012-03-27 09:39:02 -07:00