Commit Graph

17 Commits

Author SHA1 Message Date
David 'Digit' Turner
98f56b100c ndk: disable logs in release builds of native_app_glue library.
This patch disables all the logs from the 'native_app_glue' helper
library (used to implement native activities with the NDK), unless
you're building a debug build.

Change-Id: Iaad9d7c48a392ec119704074ab76e131d7806adb
2012-01-05 16:41:09 +01:00
David 'Digit' Turner
95ae335fd5 native_app_glue: fix APP_CMD_TERM_WINDOW pre-hook
The window field must not be set to NULL in the pre-hook, only the
post-one. See http://code.google.com/p/android/issues/detail?id=14352

Change-Id: Ib6214d47c97766bf4a5e148b6b6707e08366fe36
2011-02-02 00:54:02 +01:00
David 'Digit' Turner
3c7c38b2bb NDK: Last cleanup of the platform headers
- fix a declaration omission in 3/<grp.h>
- add missing 8/<err.h>
- simplify 8/<stdio.h>
- update 9/ headers to the latest Bionic versions
- fix a typo in android_native_app_glue.h
- use __BEGIN_DECLS .. __END_DECLS whenever possible.
- remove C++-style comments from headers

Change-Id: I58b98b3973cde494436206194ba33416a11ca8ee
2010-11-04 04:07:16 -07:00
Jeff Brown
9f44e97108 Update NDK headers and samples to sync up with looper API changes.
Change-Id: I7082603bf280888be90dc4df687521aaae9b1d02
2010-09-14 02:02:15 -07:00
Dianne Hackborn
d3d58cf7d3 Update to follow ALooper ident change.
Also the native-activity sample also has some very simple code showing
how to listen to the accelerometer.

Change-Id: I0629b8bc40cddd66233c1675cd5e8b42a9b722d8
2010-09-07 15:47:35 -07:00
Dianne Hackborn
79b946e8f2 Some native activity sample code cleanup.
Update to include newest headers and library, tweak glue code to
work better with state saving and add support for config changes.

Change-Id: I4d27bd4a0f542f217efaec86cf4f219aca020426
2010-08-11 00:31:37 -07:00
David 'Digit' Turner
4948c16366 Remove prebuilt static library "libthreaded_app.a".
Make the "glue library" part of the NDK as an importable module,
this has several benefits:

- no need to distribute a binary here with no easy way to regenerate it

- no need to explicitely list -lthreaded_app in your LOCAL_LDLIBS
  (this is handled automatically by the module import capability)

- allows easier native debugging of what's really happening.

Note that the header is renamed <threaded_native_app.h>

+ Modify the native-activity sample to use and import the new module
+ Start documenting usage in the header file. We probably need something
  better, and will probably put it under development/ndk/docs/ at some
  point.

After this patch, we should be able to get rid of the code under
framework/base/native/{include.glue}

Change-Id: I6e81d70a225a6ca006beabf6e8b42529e8f371b9
2010-07-13 23:50:02 -07:00
Jean-Baptiste Queru
7e203f10b6 Delete NDK.
It is being moved to a standalone project.

Change-Id: If863753b9bf10ec2b7351fd39eccf28a989102f7
2010-03-24 09:22:53 -07:00
David 'Digit' Turner
4653cb897b cpufeatures license is BSD, no Apache 2.0 2010-02-22 16:23:24 -08:00
David 'Digit' Turner
693ad65e24 Add missing copyright disclaimers to cpufeatures and hello-neon 2010-02-22 14:11:07 -08:00
David 'Digit' Turner
43809914f6 Add 'cpufeatures' library to perform runtime CPU family/features detection.
It is provided as a static library that NDK developers can link against.
The code is designed to run on all official Android platforms, starting
from Android 1.5.
2010-02-05 16:03:39 -08:00
David 'Digit' Turner
eee1675aa4 Look for Android.mk in $(APP_PROJECT_PATH)/jni by default.
This gets rid of the 'sources' directory and allows all sources
of a given Android application to be in the same directory tree
without using a symlink trick.

Note that apps/<name>/Application.mk is still required though.
A later release of the NDK will get rid of it too, but the change
is too drastic for the upcoming release.

The change moves various source files from sources into their
app/<name>/project/jni directory as well.

The whole documentation is updated to reflect the change.
2009-07-29 19:04:44 +02:00
David 'Digit' Turner
197a8fea8e Add sample "san-angeles" program to demo OpenGL ES from native code.
Note that the app will only build against an android-4 SDK.
(Interestingly, the resulting binary runs very well under android-3).

This also adds missing license headers to the 'two-libs' sample.
2009-07-29 19:02:21 +02:00
David 'Digit' Turner
4ddb7840c2 Add a "unit-tests" sample application to perform unit testing. 2009-07-27 12:26:17 +02:00
David 'Digit' Turner
985338c05c Expose the Zlib headers (<zlib.h> and <zconf.h>) in the android-1.5 NDK sysroot.
This is OK because the Zlib ABI is fixed and stable.

Also get rid of the sample zlib sources since we don't need the static library anymore.
2009-05-19 12:10:09 +02:00
Xavier Ducrohet
f99249b80b Change the NDK samples package names to be lower case. Also added minSdkVersion=3 in the manifests. 2009-05-07 14:03:22 -07:00
David 'Digit' Turner
b9a8479e48 Initial import of new NDK into donut tree 2009-05-07 20:39:04 +02:00