diff --git a/ndk/GNUmakefile b/ndk/GNUmakefile
new file mode 100644
index 000000000..3cd1635ea
--- /dev/null
+++ b/ndk/GNUmakefile
@@ -0,0 +1,18 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# DO NOT MODIFY THIS FILE
+include build/core/main.mk
+# END OF FILE
diff --git a/ndk/README.TXT b/ndk/README.TXT
new file mode 100644
index 000000000..56299c68c
--- /dev/null
+++ b/ndk/README.TXT
@@ -0,0 +1,27 @@
+ Android Native Development Kit (NDK)
+
+
+Welcome, this NDK is designed to allow Android application developers
+to include native code in their Android application packages, compiled
+as JNI shared libraries.
+
+A high-level overview of the NDK's features and limitations can be found
+in docs/OVERVIEW.TXT. Please read this document as it contains crucial
+information for correct usage.
+
+Before using the NDK, you will need to follow the steps described by
+docs/INSTALL.TXT which lists the NDK pre-requisites and the steps needed
+to set it up properly on your machine.
+
+We recommend developers to make themselves familiar with JNI concepts. Also
+note that the NDK is *not* a good way to write non-JNI native code for the
+Android platform.
+
+The document docs/ROADMAP.TXT gives a tentative roadmap for upcoming
+NDK features and improvements.
+
+Finally, discussions related to the Android NDK happen on the public
+"android-ndk" forum located at the following address:
+
+ http://groups.google.com/group/android-ndk
+
diff --git a/ndk/apps/hello-jni/Application.mk b/ndk/apps/hello-jni/Application.mk
new file mode 100644
index 000000000..f5ac83979
--- /dev/null
+++ b/ndk/apps/hello-jni/Application.mk
@@ -0,0 +1,2 @@
+APP_PROJECT_PATH := $(call my-dir)/project
+APP_MODULES := hello-jni
diff --git a/ndk/apps/hello-jni/project/AndroidManifest.xml b/ndk/apps/hello-jni/project/AndroidManifest.xml
new file mode 100644
index 000000000..4cfdf5824
--- /dev/null
+++ b/ndk/apps/hello-jni/project/AndroidManifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/hello-jni/project/build.properties b/ndk/apps/hello-jni/project/build.properties
new file mode 100644
index 000000000..a6504854e
--- /dev/null
+++ b/ndk/apps/hello-jni/project/build.properties
@@ -0,0 +1,15 @@
+# This file is used to override default values used by the Ant build system.
+#
+# This file must be checked in Version Control Systems, as it is
+# integral to the build system of your project.
+
+# The name of your application package as defined in the manifest.
+# Used by the 'uninstall' rule.
+#application-package=com.example.myproject
+
+# The name of the source folder.
+#source-folder=src
+
+# The name of the output folder.
+#out-folder=bin
+
diff --git a/ndk/apps/hello-jni/project/build.xml b/ndk/apps/hello-jni/project/build.xml
new file mode 100644
index 000000000..8beda0e5e
--- /dev/null
+++ b/ndk/apps/hello-jni/project/build.xml
@@ -0,0 +1,61 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/hello-jni/project/default.properties b/ndk/apps/hello-jni/project/default.properties
new file mode 100644
index 000000000..4513a1e4f
--- /dev/null
+++ b/ndk/apps/hello-jni/project/default.properties
@@ -0,0 +1,11 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must be checked in Version Control Systems.
+#
+# To customize properties used by the Ant build system use,
+# "build.properties", and override values to adapt the script to your
+# project structure.
+
+# Project target.
+target=android-3
diff --git a/ndk/apps/hello-jni/project/local.properties b/ndk/apps/hello-jni/project/local.properties
new file mode 100644
index 000000000..4bdd176a2
--- /dev/null
+++ b/ndk/apps/hello-jni/project/local.properties
@@ -0,0 +1,10 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must *NOT* be checked in Version Control Systems,
+# as it contains information specific to your local configuration.
+
+# location of the SDK. This is only used by Ant
+# For customization when using a Version Control System, please read the
+# header note.
+sdk-location=/opt/digit/android/main/cupcake/android/out/host/linux-x86/sdk/android-sdk_eng.digit_linux-x86
diff --git a/ndk/apps/hello-jni/project/res/layout/main.xml b/ndk/apps/hello-jni/project/res/layout/main.xml
new file mode 100644
index 000000000..abcc47f17
--- /dev/null
+++ b/ndk/apps/hello-jni/project/res/layout/main.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
diff --git a/ndk/apps/hello-jni/project/res/values/strings.xml b/ndk/apps/hello-jni/project/res/values/strings.xml
new file mode 100644
index 000000000..c5260737b
--- /dev/null
+++ b/ndk/apps/hello-jni/project/res/values/strings.xml
@@ -0,0 +1,4 @@
+
+
+ HelloJni
+
diff --git a/ndk/apps/hello-jni/project/src/com/example/HelloJni/HelloJni.java b/ndk/apps/hello-jni/project/src/com/example/HelloJni/HelloJni.java
new file mode 100644
index 000000000..94073c778
--- /dev/null
+++ b/ndk/apps/hello-jni/project/src/com/example/HelloJni/HelloJni.java
@@ -0,0 +1,66 @@
+/*
+ * Copyright (C) 2009 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.example.HelloJni;
+
+import android.app.Activity;
+import android.widget.TextView;
+import android.os.Bundle;
+
+
+public class HelloJni extends Activity
+{
+ /** Called when the activity is first created. */
+ @Override
+ public void onCreate(Bundle savedInstanceState)
+ {
+ super.onCreate(savedInstanceState);
+
+ /* Create a TextView and set its content.
+ * the text is retrieved by calling a native
+ * function.
+ */
+ TextView tv = new TextView(this);
+ tv.setText( stringFromJNI() );
+ setContentView(tv);
+ }
+
+ /* A native method that is implemented by the
+ * 'hello-jni' native library, which is packaged
+ * with this application.
+ */
+ public native String stringFromJNI();
+
+ /* This is another native method declaration that is *not*
+ * implemented by 'hello-jni'. This is simply to show that
+ * you can declare as many native methods in your Java code
+ * as you want, their implementation is searched in the
+ * currently loaded native libraries only the first time
+ * you call them.
+ *
+ * Trying to call this function will result in a
+ * java.lang.UnsatisfiedLinkError exception !
+ */
+ public native String unimplementedStringFromJNI();
+
+ /* this is used to load the 'hello-jni' library on application
+ * startup. The library has already been unpacked into
+ * /data/data/com.example.HelloJni/lib/libhello-jni.so at
+ * installation time by the package manager.
+ */
+ static {
+ System.loadLibrary("hello-jni");
+ }
+}
diff --git a/ndk/apps/hello-jni/project/tests/AndroidManifest.xml b/ndk/apps/hello-jni/project/tests/AndroidManifest.xml
new file mode 100644
index 000000000..d6be01ebf
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/AndroidManifest.xml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/hello-jni/project/tests/build.properties b/ndk/apps/hello-jni/project/tests/build.properties
new file mode 100644
index 000000000..a6504854e
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/build.properties
@@ -0,0 +1,15 @@
+# This file is used to override default values used by the Ant build system.
+#
+# This file must be checked in Version Control Systems, as it is
+# integral to the build system of your project.
+
+# The name of your application package as defined in the manifest.
+# Used by the 'uninstall' rule.
+#application-package=com.example.myproject
+
+# The name of the source folder.
+#source-folder=src
+
+# The name of the output folder.
+#out-folder=bin
+
diff --git a/ndk/apps/hello-jni/project/tests/build.xml b/ndk/apps/hello-jni/project/tests/build.xml
new file mode 100644
index 000000000..8beda0e5e
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/build.xml
@@ -0,0 +1,61 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/hello-jni/project/tests/default.properties b/ndk/apps/hello-jni/project/tests/default.properties
new file mode 100644
index 000000000..4513a1e4f
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/default.properties
@@ -0,0 +1,11 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must be checked in Version Control Systems.
+#
+# To customize properties used by the Ant build system use,
+# "build.properties", and override values to adapt the script to your
+# project structure.
+
+# Project target.
+target=android-3
diff --git a/ndk/apps/hello-jni/project/tests/local.properties b/ndk/apps/hello-jni/project/tests/local.properties
new file mode 100644
index 000000000..4bdd176a2
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/local.properties
@@ -0,0 +1,10 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must *NOT* be checked in Version Control Systems,
+# as it contains information specific to your local configuration.
+
+# location of the SDK. This is only used by Ant
+# For customization when using a Version Control System, please read the
+# header note.
+sdk-location=/opt/digit/android/main/cupcake/android/out/host/linux-x86/sdk/android-sdk_eng.digit_linux-x86
diff --git a/ndk/apps/hello-jni/project/tests/src/com/example/HelloJni/HelloJniTest.java b/ndk/apps/hello-jni/project/tests/src/com/example/HelloJni/HelloJniTest.java
new file mode 100644
index 000000000..519d85768
--- /dev/null
+++ b/ndk/apps/hello-jni/project/tests/src/com/example/HelloJni/HelloJniTest.java
@@ -0,0 +1,21 @@
+package com.example.HelloJni;
+
+import android.test.ActivityInstrumentationTestCase;
+
+/**
+ * This is a simple framework for a test of an Application. See
+ * {@link android.test.ApplicationTestCase ApplicationTestCase} for more information on
+ * how to write and extend Application tests.
+ *
+ * To run this test, you can type:
+ * adb shell am instrument -w \
+ * -e class com.example.HelloJni.HelloJniTest \
+ * com.example.HelloJni.tests/android.test.InstrumentationTestRunner
+ */
+public class HelloJniTest extends ActivityInstrumentationTestCase {
+
+ public HelloJniTest() {
+ super("com.example.HelloJni", HelloJni.class);
+ }
+
+}
diff --git a/ndk/apps/two-libs/Application.mk b/ndk/apps/two-libs/Application.mk
new file mode 100644
index 000000000..a2fd402d6
--- /dev/null
+++ b/ndk/apps/two-libs/Application.mk
@@ -0,0 +1,2 @@
+APP_PROJECT_PATH := $(call my-dir)/project
+APP_MODULES := twolib-first twolib-second
diff --git a/ndk/apps/two-libs/project/AndroidManifest.xml b/ndk/apps/two-libs/project/AndroidManifest.xml
new file mode 100644
index 000000000..fe3f9d91c
--- /dev/null
+++ b/ndk/apps/two-libs/project/AndroidManifest.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/two-libs/project/build.properties b/ndk/apps/two-libs/project/build.properties
new file mode 100644
index 000000000..a6504854e
--- /dev/null
+++ b/ndk/apps/two-libs/project/build.properties
@@ -0,0 +1,15 @@
+# This file is used to override default values used by the Ant build system.
+#
+# This file must be checked in Version Control Systems, as it is
+# integral to the build system of your project.
+
+# The name of your application package as defined in the manifest.
+# Used by the 'uninstall' rule.
+#application-package=com.example.myproject
+
+# The name of the source folder.
+#source-folder=src
+
+# The name of the output folder.
+#out-folder=bin
+
diff --git a/ndk/apps/two-libs/project/build.xml b/ndk/apps/two-libs/project/build.xml
new file mode 100644
index 000000000..5783bd77b
--- /dev/null
+++ b/ndk/apps/two-libs/project/build.xml
@@ -0,0 +1,61 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/two-libs/project/default.properties b/ndk/apps/two-libs/project/default.properties
new file mode 100644
index 000000000..4513a1e4f
--- /dev/null
+++ b/ndk/apps/two-libs/project/default.properties
@@ -0,0 +1,11 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must be checked in Version Control Systems.
+#
+# To customize properties used by the Ant build system use,
+# "build.properties", and override values to adapt the script to your
+# project structure.
+
+# Project target.
+target=android-3
diff --git a/ndk/apps/two-libs/project/local.properties b/ndk/apps/two-libs/project/local.properties
new file mode 100644
index 000000000..4bdd176a2
--- /dev/null
+++ b/ndk/apps/two-libs/project/local.properties
@@ -0,0 +1,10 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must *NOT* be checked in Version Control Systems,
+# as it contains information specific to your local configuration.
+
+# location of the SDK. This is only used by Ant
+# For customization when using a Version Control System, please read the
+# header note.
+sdk-location=/opt/digit/android/main/cupcake/android/out/host/linux-x86/sdk/android-sdk_eng.digit_linux-x86
diff --git a/ndk/apps/two-libs/project/res/layout/main.xml b/ndk/apps/two-libs/project/res/layout/main.xml
new file mode 100644
index 000000000..14ae52eec
--- /dev/null
+++ b/ndk/apps/two-libs/project/res/layout/main.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
diff --git a/ndk/apps/two-libs/project/res/values/strings.xml b/ndk/apps/two-libs/project/res/values/strings.xml
new file mode 100644
index 000000000..ae57f1f2c
--- /dev/null
+++ b/ndk/apps/two-libs/project/res/values/strings.xml
@@ -0,0 +1,4 @@
+
+
+ TwoLib
+
diff --git a/ndk/apps/two-libs/project/src/com/example/TwoLib/TwoLib.java b/ndk/apps/two-libs/project/src/com/example/TwoLib/TwoLib.java
new file mode 100644
index 000000000..741305db5
--- /dev/null
+++ b/ndk/apps/two-libs/project/src/com/example/TwoLib/TwoLib.java
@@ -0,0 +1,46 @@
+/*
+ * Copyright (C) 2009 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.example.TwoLib;
+
+import android.app.Activity;
+import android.widget.TextView;
+import android.os.Bundle;
+
+public class TwoLib extends Activity
+{
+ /** Called when the activity is first created. */
+ @Override
+ public void onCreate(Bundle savedInstanceState)
+ {
+ super.onCreate(savedInstanceState);
+
+ TextView tv = new TextView(this);
+ int x = 1000;
+ int y = 42;
+
+ // here, we dynamically load the library at runtime
+ // before calling the native method.
+ //
+ System.loadLibrary("twolib-second");
+
+ int z = add(x, y);
+
+ tv.setText( "The sum of " + x + " and " + y + " is " + z );
+ setContentView(tv);
+ }
+
+ public native int add(int x, int y);
+}
diff --git a/ndk/apps/two-libs/project/tests/AndroidManifest.xml b/ndk/apps/two-libs/project/tests/AndroidManifest.xml
new file mode 100644
index 000000000..a7dd6020b
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/AndroidManifest.xml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/two-libs/project/tests/build.properties b/ndk/apps/two-libs/project/tests/build.properties
new file mode 100644
index 000000000..a6504854e
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/build.properties
@@ -0,0 +1,15 @@
+# This file is used to override default values used by the Ant build system.
+#
+# This file must be checked in Version Control Systems, as it is
+# integral to the build system of your project.
+
+# The name of your application package as defined in the manifest.
+# Used by the 'uninstall' rule.
+#application-package=com.example.myproject
+
+# The name of the source folder.
+#source-folder=src
+
+# The name of the output folder.
+#out-folder=bin
+
diff --git a/ndk/apps/two-libs/project/tests/build.xml b/ndk/apps/two-libs/project/tests/build.xml
new file mode 100644
index 000000000..5783bd77b
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/build.xml
@@ -0,0 +1,61 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ndk/apps/two-libs/project/tests/default.properties b/ndk/apps/two-libs/project/tests/default.properties
new file mode 100644
index 000000000..4513a1e4f
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/default.properties
@@ -0,0 +1,11 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must be checked in Version Control Systems.
+#
+# To customize properties used by the Ant build system use,
+# "build.properties", and override values to adapt the script to your
+# project structure.
+
+# Project target.
+target=android-3
diff --git a/ndk/apps/two-libs/project/tests/local.properties b/ndk/apps/two-libs/project/tests/local.properties
new file mode 100644
index 000000000..4bdd176a2
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/local.properties
@@ -0,0 +1,10 @@
+# This file is automatically generated by Android Tools.
+# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
+#
+# This file must *NOT* be checked in Version Control Systems,
+# as it contains information specific to your local configuration.
+
+# location of the SDK. This is only used by Ant
+# For customization when using a Version Control System, please read the
+# header note.
+sdk-location=/opt/digit/android/main/cupcake/android/out/host/linux-x86/sdk/android-sdk_eng.digit_linux-x86
diff --git a/ndk/apps/two-libs/project/tests/src/com/example/TwoLib/TwoLibTest.java b/ndk/apps/two-libs/project/tests/src/com/example/TwoLib/TwoLibTest.java
new file mode 100644
index 000000000..292450243
--- /dev/null
+++ b/ndk/apps/two-libs/project/tests/src/com/example/TwoLib/TwoLibTest.java
@@ -0,0 +1,21 @@
+package com.example.TwoLib;
+
+import android.test.ActivityInstrumentationTestCase;
+
+/**
+ * This is a simple framework for a test of an Application. See
+ * {@link android.test.ApplicationTestCase ApplicationTestCase} for more information on
+ * how to write and extend Application tests.
+ *
+ * To run this test, you can type:
+ * adb shell am instrument -w \
+ * -e class com.example.TwoLib.TwoLibTest \
+ * com.example.TwoLib.tests/android.test.InstrumentationTestRunner
+ */
+public class TwoLibTest extends ActivityInstrumentationTestCase {
+
+ public TwoLibTest() {
+ super("com.example.TwoLib", TwoLib.class);
+ }
+
+}
diff --git a/ndk/build/core/add-application.mk b/ndk/build/core/add-application.mk
new file mode 100644
index 000000000..e4026521a
--- /dev/null
+++ b/ndk/build/core/add-application.mk
@@ -0,0 +1,62 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this script is used to record an application definition in the
+# NDK build system, before performing any build whatsoever.
+#
+# It is included repeatedly from build/core/main.mk and expects a
+# variable named '_application_mk' which points to a given Application.mk
+# file that will be included here. The latter must define a few variables
+# to describe the application to the build system, and the rest of the
+# code here will perform book-keeping and basic checks
+#
+
+$(call assert-defined, _application_mk)
+
+$(call clear-vars, $(NDK_APP_VARS))
+
+include $(_application_mk)
+
+$(call check-required-vars,$(NDK_APP_VARS_REQUIRED),$(_application_mk))
+
+# strip the 'lib' prefix in front of APP_MODULES modules
+APP_MODULES := $(call strip-lib-prefix,$(APP_MODULES))
+
+# check that APP_OPTIM, if defined, is either 'release' or 'debug'
+$(if $(filter-out release debug,$(APP_OPTIM)),\
+ $(call __ndk_info, The APP_OPTIM defined in $(_application_mk) must only be 'release' or 'debug')\
+ $(call __ndk_error,Aborting)\
+)
+
+_dir := $(patsubst %/,%,$(dir $(_application_mk)))
+_name := $(notdir $(_dir))
+_app := NDK_APP.$(_name)
+
+$(if $(strip $(APP.$(_app).defined)),\
+ $(call __ndk_info,Weird, the application $(_name) is already defined by $(APP.$(_app).defined))\
+ $(call __ndk_error,Aborting)\
+)
+
+APP.$(_app).defined := $(_application_mk)
+
+# Record all app-specific variable definitions
+$(foreach __name,$(NDK_APP_VARS),\
+ $(eval $(_app).$(__name) := $($(__name)))\
+)
+
+# Record the Application.mk for debugging
+$(_app).Application.mk := $(_application_mk)
+
+NDK_ALL_APPS += $(_name)
diff --git a/ndk/build/core/add-toolchain.mk b/ndk/build/core/add-toolchain.mk
new file mode 100644
index 000000000..498d62470
--- /dev/null
+++ b/ndk/build/core/add-toolchain.mk
@@ -0,0 +1,65 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this script is included repeatedly by main.mk to add a new toolchain
+# definition to the NDK build system.
+#
+# 'toolchain_config' must be defined as the path of a toolchain
+# configuration file (config.mk) that will be included here.
+#
+$(call assert-defined, _config_mk)
+
+# The list of variables that must or may be defined
+# by the toolchain configuration file
+#
+NDK_TOOLCHAIN_VARS_REQUIRED := TOOLCHAIN_ABIS
+NDK_TOOLCHAIN_VARS_OPTIONAL :=
+
+# Clear variables that are supposed to be defined by the config file
+$(call clear-vars,$(NDK_TOOLCHAIN_VARS_REQUIRED))
+$(call clear-vars,$(NDK_TOOLCHAIN_VARS_OPTIONAL))
+
+# Include the config file
+include $(_config_mk)
+
+# Check that the proper variables were defined
+$(call check-required-vars,$(NDK_TOOLCHAIN_VARS_REQUIRED),$(_config_mk))
+
+# Check that the file didn't do something stupid
+$(call assert-defined, _config_mk)
+
+# Now record the toolchain-specific informatio
+_dir := $(patsubst %/,%,$(dir $(_config_mk)))
+_name := $(notdir $(_dir))
+_abis := $(TOOLCHAIN_ABIS)
+
+_toolchain := NDK_TOOLCHAIN.$(_name)
+
+# check that the toolchain name is unique
+$(if $(strip $($(_toolchain).defined)),\
+ $(call __ndk_error,Toolchain $(_name) defined in $(_parent) is\
+ already defined in $(NDK_TOOLCHAIN.$(_name).defined)))
+
+$(_toolchain).defined := $(_toolchain_config)
+$(_toolchain).abis := $(_abis)
+$(_toolchain).setup := $(wildcard $(_dir)/setup.mk)
+
+$(if $(strip $($(_toolchain).setup)),,\
+ $(call __ndk_error, Toolchain $(_name) lacks a setup.mk in $(_dir)))
+
+NDK_ALL_TOOLCHAINS += $(_name)
+NDK_ALL_ABIS += $(_abis)
+
+# done
diff --git a/ndk/build/core/build-binary.mk b/ndk/build/core/build-binary.mk
new file mode 100644
index 000000000..6254302cf
--- /dev/null
+++ b/ndk/build/core/build-binary.mk
@@ -0,0 +1,124 @@
+# Copyright (C) 2008 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# we expect the 'my' variable to be defined, either to
+# 'HOST_' or 'TARGET_', and this allows us to call the
+# appropriate compiler with $($(my)CC)
+#
+$(call assert-defined,my)
+
+# LOCAL_MAKEFILE must also exist and name the Android.mk that
+# included the module build script.
+#
+$(call assert-defined,LOCAL_MAKEFILE)
+
+include $(BUILD_SYSTEM)/build-module.mk
+
+# list of generated object files
+LOCAL_OBJECTS :=
+
+#
+# Add the default system shared libraries to the build
+#
+ifndef LOCAL_IS_HOST_MODULE
+ ifeq ($(LOCAL_SYSTEM_SHARED_LIBRARIES),none)
+ LOCAL_SHARED_LIBRARIES += $(TARGET_DEFAULT_SYSTEM_SHARED_LIBRARIES)
+ else
+ LOCAL_SHARED_LIBRARIES += $(LOCAL_SYSTEM_SHARED_LIBRARIES)
+ endif
+endif
+
+
+#
+# Check LOCAL_CPP_EXTENSION, use '.cpp' by default
+#
+LOCAL_CPP_EXTENSION := $(strip $(LOCAL_CPP_EXTENSION))
+ifeq ($(LOCAL_CPP_EXTENSION),)
+ LOCAL_CPP_EXTENSION := .cpp
+else
+ ifneq ($(words $(LOCAL_CPP_EXTENSION)),1)
+ $(call __ndk_log, LOCAL_CPP_EXTENSION in $(LOCAL_MAKEFILE) must be one word only, not '$(LOCAL_CPP_EXTENSION)')
+ $(call __ndk_error, Aborting)
+ endif
+endif
+
+#
+# The original Android build system allows you to use the .arm prefix
+# to a source file name to indicate that it should be defined in either
+# 'thumb' or 'arm' mode, depending on the value of LOCAL_ARM_MODE
+#
+# First, check LOCAL_ARM_MODE, it should be empty, 'thumb' or 'arm'
+# We make the default 'thumb'
+#
+LOCAL_ARM_MODE := $(strip $(LOCAL_ARM_MODE))
+ifeq ($(LOCAL_ARM_MODE),)
+ LOCAL_ARM_MODE := thumb
+else
+ ifneq ($(words $(LOCAL_ARM_MODE)),1)
+ $(call __ndk_log, LOCAL_ARM_MODE in $(LOCAL_MAKEFILE) must be one word, not '$(LOCAL_ARM_MODE)')
+ $(call __ndk_error, Aborting)
+ endif
+ # check that LOCAL_ARM_MODE is defined to either 'arm' or 'thumb'
+ $(if $(filter-out thumb arm, $(LOCAL_ARM_MODE)),\
+ $(call __ndk_log, LOCAL_ARM_MODE must be defined to either 'arm' or 'thumb' in $(LOCAL_MAKEFILE), not '$(LOCAL_ARM_MODE)')\
+ $(call __ndk_error, Aborting)\
+ )
+endif
+
+LOCAL_ARM_TEXT_arm = arm$(space)$(space)
+LOCAL_ARM_TEXT_thumb = thumb
+
+LOCAL_ARM_CFLAGS := $(TARGET_$(LOCAL_ARM_MODE)_$(LOCAL_BUILD_MODE)_CFLAGS)
+LOCAL_ARM_TEXT := $(LOCAL_ARM_TEXT_$(LOCAL_ARM_MODE))
+
+# As a special case, the original Android build system
+# allows one to specify that certain source files can be
+# forced to build in ARM mode by using a '.arm' suffix
+# after the extension, e.g.
+#
+# LOCAL_SRC_FILES := foo.c.arm
+#
+# to build source file $(LOCAL_PATH)/foo.c as ARM
+#
+
+#
+# Build C source files into .o
+#
+
+# XXX: TODO: support LOCAL_ARM_MODE
+
+arm_sources := $(LOCAL_SRC_FILES:%.arm)
+
+c_sources := $(filter %.c, \
+ $(LOCAL_SRC_FILES) \
+ $(arm_sources:%.arm=%))
+
+s_sources := $(filter %.S, \
+ $(LOCAL_SRC_FILES) \
+ $(arm_sources:%.arm=%))
+
+cpp_sources := $(filter %$(LOCAL_CPP_EXTENSION), \
+ $(LOCAL_SRC_FILES) \
+ $(arm_sources:%.arm=%))
+
+#
+# The following will update LOCAL_OBJECTS and LOCAL_DEPENDENCY_DIRS
+#
+$(foreach src,$(c_sources), $(call compile-c-source,$(src)))
+$(foreach src,$(s_sources), $(call compile-s-source,$(src)))
+$(foreach src,$(cpp_sources), $(call compile-cpp-source,$(src)))
+
+LOCAL_DEPENDENCY_DIRS := $(sort $(LOCAL_DEPENDENCY_DIRS))
+CLEAN_OBJS_DIRS += $(LOCAL_OBJS_DIR)
diff --git a/ndk/build/core/build-executable.mk b/ndk/build/core/build-executable.mk
new file mode 100644
index 000000000..aedcabdef
--- /dev/null
+++ b/ndk/build/core/build-executable.mk
@@ -0,0 +1,72 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included from Android.mk files to build a target-specific
+# executable program
+#
+
+LOCAL_BUILD_SCRIPT := BUILD_EXECUTABLE
+LOCAL_MODULE_CLASS := EXECUTABLE
+LOCAL_MAKEFILE := $(local-makefile)
+
+$(call check-defined-LOCAL_MODULE,$(LOCAL_BUILD_SCRIPT))
+$(call check-LOCAL_MODULE,$(LOCAL_MAKEFILE))
+
+# only adjust the build if this module is needed by the current app
+ifneq ($(filter $(LOCAL_MODULE),$(NDK_APP_MODULES)),)
+
+# we are building target objects
+my := TARGET_
+
+LOCAL_BUILT_MODULE := $(call executable-path,$(LOCAL_MODULE))
+LOCAL_OBJS_DIR := $(TARGET_OBJS)/$(LOCAL_MODULE)
+
+include $(BUILD_SYSTEM)/build-binary.mk
+
+LOCAL_STATIC_LIBRARIES := $(call strip-lib-prefix,$(LOCAL_STATIC_LIBRARIES))
+LOCAL_SHARED_LIBRARIES := $(call strip-lib-prefix,$(LOCAL_SHARED_LIBRARIES))
+
+static_libraries := $(call map,static-library-path,$(LOCAL_STATIC_LIBRARIES))
+shared_libraries := $(call map,shared-library-path,$(LOCAL_SHARED_LIBRARIES)) \
+ $(TARGET_PREBUILT_SHARED_LIBRARIES)
+
+$(LOCAL_BUILT_MODULE): $(static_libraries) $(shared_libraries)
+
+LOCAL_LDLIBS := $(_module_libs) $(LOCAL_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_STATIC_LIBRARIES := $(static_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_SHARED_LIBRARIES := $(shared_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_OBJECTS := $(LOCAL_OBJECTS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_LDFLAGS := $(TARGET_LDFLAGS) $(LOCAL_LDFLAGS)
+$(LOCAL_BUILT_MODULE): PRIVATE_LDLIBS := $(LOCAL_LDLIBS) $(TARGET_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_NAME := $(notdir $(LOCAL_BUILT_MODULE))
+$(LOCAL_BUILT_MODULE): PRIVATE_DEST := $(NDK_APP_DEST)
+$(LOCAL_BUILT_MODULE): PRIVATE_SRC := $(LOCAL_BUILT_MODULE)
+$(LOCAL_BUILT_MODULE): PRIVATE_DST := $(PRIVATE_DEST)/$(PRIVATE_NAME)
+
+$(LOCAL_BUILT_MODULE): $(LOCAL_OBJECTS)
+ @ mkdir -p $(dir $@)
+ @ echo "Executable : $(PRIVATE_NAME)"
+ $(hide) $(cmd-build-executable)
+ @ echo "Install : $(PRIVATE_NAME) => $(PRIVATE_DEST)"
+ $(hide) mkdir -p $(PRIVATE_DEST)
+ $(hide) install -p $(PRIVATE_SRC) $(PRIVATE_DST)
+ $(hide) $(call cmd-strip, $(PRIVATE_DST))
+
+ALL_EXECUTABLES += $(LOCAL_BUILT_MODULE)
+
+endif # filter LOCAL_MODULE in NDK_APP_MODULES
diff --git a/ndk/build/core/build-module.mk b/ndk/build/core/build-module.mk
new file mode 100644
index 000000000..83cc38cca
--- /dev/null
+++ b/ndk/build/core/build-module.mk
@@ -0,0 +1,78 @@
+# Copyright (C) 2008 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+#
+# Base rules shared to control the build of all modules.
+# This should be included from build-binary.mk
+#
+
+$(call assert-defined,LOCAL_MODULE_CLASS LOCAL_BUILD_SCRIPT LOCAL_BUILT_MODULE)
+
+# Check LOCAL_IS_HOST_MODULE and define 'my' as either HOST_ or TARGET_
+#
+LOCAL_IS_HOST_MODULE := $(strip $(LOCAL_IS_HOST_MODULE))
+ifdef LOCAL_IS_HOST_MODULE
+ ifneq ($(LOCAL_IS_HOST_MODULE),true)
+ $(call __ndk_log,$(LOCAL_PATH): LOCAL_IS_HOST_MODULE must be "true" or empty, not "$(LOCAL_IS_HOST_MODULE)")
+ endif
+ my := HOST_
+else
+ my := TARGET_
+endif
+
+# Compute 'intermediates' which is the location where we're going to store
+# intermediate generated files like object (.o) files.
+#
+intermediates := $($(my)OBJS)
+
+# LOCAL_INTERMEDIATES lists the targets that are generated by this module
+#
+LOCAL_INTERMEDIATES := $(LOCAL_BUILT_MODULE)
+
+# LOCAL_BUILD_MODE will be either arm or thumb
+#
+ifneq ($(NDK_APP_OPTIM),)
+ LOCAL_BUILD_MODE := $(NDK_APP_OPTIM)
+else
+ LOCAL_BUILD_MODE := thumb
+endif
+
+#
+# Ensure that 'make ' and 'make clean-' work
+#
+.PHONY: $(LOCAL_MODULE)
+$(LOCAL_MODULE): $(LOCAL_BUILT_MODULE)
+
+cleantarget := clean-$(LOCAL_MODULE)
+.PHONY: $(cleantarget)
+clean: $(cleantarget)
+
+$(cleantarget): PRIVATE_MODULE := $(LOCAL_MODULE)
+$(cleantarget): PRIVATE_CLEAN_FILES := $(PRIVATE_CLEAN_FILES) \
+ $(LOCAL_BUILT_MODULE) \
+ $(LOCAL_INSTALLED_MODULE) \
+ $(intermediates)
+
+$(cleantarget)::
+ @echo "Clean: $(PRIVATE_MODULE)"
+ $(hide) rm -rf $(PRIVATE_CLEAN_FILES)
+
+#
+# Register module
+#
+
+ALL_MODULES += $(LOCAL_MODULE)
+
+
diff --git a/ndk/build/core/build-shared-library.mk b/ndk/build/core/build-shared-library.mk
new file mode 100644
index 000000000..f07ed80ba
--- /dev/null
+++ b/ndk/build/core/build-shared-library.mk
@@ -0,0 +1,72 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included from Android.mk files to build a target-specific
+# executable program
+#
+
+LOCAL_BUILD_SCRIPT := BUILD_SHARED_LIBRARY
+LOCAL_MODULE_CLASS := SHARED_LIBRARY
+LOCAL_MAKEFILE := $(local-makefile)
+
+$(call check-defined-LOCAL_MODULE,$(LOCAL_BUILD_SCRIPT))
+$(call check-LOCAL_MODULE,$(LOCAL_MAKEFILE))
+
+# only adjust the build if this module is needed by the current app
+ifneq ($(filter $(LOCAL_MODULE),$(NDK_APP_MODULES)),)
+
+# we are building target objects
+my := TARGET_
+
+LOCAL_BUILT_MODULE := $(call shared-library-path,$(LOCAL_MODULE))
+LOCAL_OBJS_DIR := $(TARGET_OBJS)/$(LOCAL_MODULE)
+
+include $(BUILD_SYSTEM)/build-binary.mk
+
+LOCAL_STATIC_LIBRARIES := $(call strip-lib-prefix,$(LOCAL_STATIC_LIBRARIES))
+LOCAL_SHARED_LIBRARIES := $(call strip-lib-prefix,$(LOCAL_SHARED_LIBRARIES))
+
+static_libraries := $(call map,static-library-path,$(LOCAL_STATIC_LIBRARIES))
+shared_libraries := $(call map,shared-library-path,$(LOCAL_SHARED_LIBRARIES)) \
+ $(TARGET_PREBUILT_SHARED_LIBRARIES)
+
+$(LOCAL_BUILT_MODULE): $(static_libraries) $(shared_libraries)
+
+LOCAL_LDLIBS := $(_module_libs) $(LOCAL_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_STATIC_LIBRARIES := $(static_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_SHARED_LIBRARIES := $(shared_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_OBJECTS := $(LOCAL_OBJECTS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_LDFLAGS := $(TARGET_LDFLAGS) $(LOCAL_LDFLAGS)
+$(LOCAL_BUILT_MODULE): PRIVATE_LDLIBS := $(LOCAL_LDLIBS) $(TARGET_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_NAME := $(notdir $(LOCAL_BUILT_MODULE))
+$(LOCAL_BUILT_MODULE): PRIVATE_DEST := $(NDK_APP_DEST)
+$(LOCAL_BUILT_MODULE): PRIVATE_SRC := $(LOCAL_BUILT_MODULE)
+$(LOCAL_BUILT_MODULE): PRIVATE_DST := $(PRIVATE_DEST)/$(PRIVATE_NAME)
+
+$(LOCAL_BUILT_MODULE): $(LOCAL_OBJECTS)
+ @ mkdir -p $(dir $@)
+ @ echo "SharedLibrary : $(PRIVATE_NAME)"
+ $(hide) $(cmd-build-shared-library)
+ @ echo "Install : $(PRIVATE_NAME) => $(PRIVATE_DEST)"
+ $(hide) mkdir -p $(PRIVATE_DEST)
+ $(hide) install -p $(PRIVATE_SRC) $(PRIVATE_DST)
+ $(hide) $(call cmd-strip, $(PRIVATE_DST))
+
+ALL_EXECUTABLES += $(LOCAL_BUILT_MODULE)
+
+endif # filter LOCAL_MODULE in NDK_APP_MODULES
diff --git a/ndk/build/core/build-static-library.mk b/ndk/build/core/build-static-library.mk
new file mode 100644
index 000000000..d36f00453
--- /dev/null
+++ b/ndk/build/core/build-static-library.mk
@@ -0,0 +1,64 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included from Android.mk files to build a target-specific
+# executable program
+#
+
+LOCAL_BUILD_SCRIPT := BUILD_STATIC_LIBRARY
+LOCAL_MODULE_CLASS := STATIC_LIBRARY
+LOCAL_MAKEFILE := $(local-makefile)
+
+$(call check-defined-LOCAL_MODULE,$(LOCAL_BUILD_SCRIPT))
+$(call check-LOCAL_MODULE,$(LOCAL_MAKEFILE))
+
+# only adjust the build if this module is needed by the current app
+ifneq ($(filter $(LOCAL_MODULE),$(NDK_APP_MODULES)),)
+
+# we are building target objects
+my := TARGET_
+
+LOCAL_BUILT_MODULE := $(call static-library-path,$(LOCAL_MODULE))
+LOCAL_OBJS_DIR := $(TARGET_OBJS)/$(LOCAL_MODULE)
+
+include $(BUILD_SYSTEM)/build-binary.mk
+
+static_libraries := $(call map,static-library-path,$(LOCAL_STATIC_LIBRARIES))
+shared_libraries := $(call map,shared-library-path,$(LOCAL_SHARED_LIBRARIES)) \
+ $(TARGET_PREBUILT_SHARED_LIBRARIES)
+
+$(LOCAL_BUILT_MODULE): $(static_libraries) $(shared_libraries)
+
+LOCAL_LDLIBS := $(_module_libs) $(LOCAL_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_STATIC_LIBRARIES := $(static_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_SHARED_LIBRARIES := $(shared_libraries)
+$(LOCAL_BUILT_MODULE): PRIVATE_OBJECTS := $(LOCAL_OBJECTS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_LDFLAGS := $(TARGET_LDFLAGS) $(LOCAL_LDFLAGS)
+$(LOCAL_BUILT_MODULE): PRIVATE_LDLIBS := $(LOCAL_LDLIBS) $(TARGET_LDLIBS)
+
+$(LOCAL_BUILT_MODULE): PRIVATE_NAME := $(notdir $(LOCAL_BUILT_MODULE))
+$(LOCAL_BUILT_MODULE): PRIVATE_SRC := $(LOCAL_BUILT_MODULE)
+
+$(LOCAL_BUILT_MODULE): $(LOCAL_OBJECTS)
+ @ mkdir -p $(dir $@)
+ @ echo "StaticLibrary : $(PRIVATE_NAME)"
+ $(hide) rm -rf $@
+ $(hide) $(cmd-build-static-library)
+
+ALL_EXECUTABLES += $(LOCAL_BUILT_MODULE)
+
+endif # filter LOCAL_MODULE in NDK_APP_MODULES
diff --git a/ndk/build/core/clear-vars.mk b/ndk/build/core/clear-vars.mk
new file mode 100644
index 000000000..c9461261b
--- /dev/null
+++ b/ndk/build/core/clear-vars.mk
@@ -0,0 +1,32 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included repeatedly from Android.mk files in order to clean
+# the module-specific variables from the environment,
+
+NDK_LOCAL_VARS := \
+ LOCAL_MODULE \
+ LOCAL_SRC_FILES \
+ LOCAL_CFLAGS \
+ LOCAL_LDFLAGS \
+ LOCAL_ARFLAGS \
+ LOCAL_CPP_EXTENSION \
+ LOCAL_STATIC_LIBRARIES \
+ LOCAL_STATIC_WHOLE_LIBRARIES \
+ LOCAL_SHARED_LIBRARIES \
+ LOCAL_MAKEFILE \
+
+$(call clear-vars, $(NDK_LOCAL_VARS))
+
diff --git a/ndk/build/core/definitions.mk b/ndk/build/core/definitions.mk
new file mode 100644
index 000000000..4d978979b
--- /dev/null
+++ b/ndk/build/core/definitions.mk
@@ -0,0 +1,485 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# Common definitions for the Android NDK build system
+#
+
+# We use the GNU Make Standard Library
+include build/gmsl/gmsl
+
+# This is the Android NDK version number as a list of three items:
+# major, minor, revision
+#
+ndk_version := 1 0 0
+
+# Used to output warnings and error from the library, it's possible to
+# disable any warnings or errors by overriding these definitions
+# manually or by setting GMSL_NO_WARNINGS or GMSL_NO_ERRORS
+
+__ndk_name := Android NDK
+__ndk_info = $(info $(__ndk_name): $1 $2 $3 $4 $5)
+__ndk_warning = $(warning $(__ndk_name): $1 $2 $3 $4 $5)
+__ndk_error = $(error $(__ndk_name): $1 $2 $3 $4 $5)
+
+ifdef NDK_NO_WARNINGS
+__ndk_warning :=
+endif
+ifdef NDK_NO_ERRORS
+__ndk_error :=
+endif
+
+# If NDK_TRACE is enabled then calls to the library functions are
+# traced to stdout using warning messages with their arguments
+
+ifdef NDK_TRACE
+__ndk_tr1 = $(warning $0('$1'))
+__ndk_tr2 = $(warning $0('$1','$2'))
+__ndk_tr3 = $(warning $0('$1','$2','$3'))
+else
+__ndk_tr1 :=
+__ndk_tr2 :=
+__ndk_tr3 :=
+endif
+
+# -----------------------------------------------------------------------------
+# Function : ndk_log
+# Arguments: 1: text to print when NDK_LOG is defined
+# Returns : None
+# Usage : $(call ndk_log,)
+# -----------------------------------------------------------------------------
+ifdef NDK_LOG
+ndk_log = $(info $(__ndk_name): $1)
+else
+ndk_log :=
+endif
+
+
+# -----------------------------------------------------------------------------
+# Macro : empty
+# Returns : an empty macro
+# Usage : $(empty)
+# -----------------------------------------------------------------------------
+empty :=
+
+# -----------------------------------------------------------------------------
+# Macro : space
+# Returns : a single space
+# Usage : $(space)
+# -----------------------------------------------------------------------------
+space := $(empty) $(empty)
+
+# -----------------------------------------------------------------------------
+# Function : last2
+# Arguments: a list
+# Returns : the penultimate (next-to-last) element of a list
+# Usage : $(call last2, )
+# -----------------------------------------------------------------------------
+last2 = $(word $(words $1), x $1)
+
+# -----------------------------------------------------------------------------
+# Function : last3
+# Arguments: a list
+# Returns : the antepenultimate (second-next-to-last) element of a list
+# Usage : $(call last3, )
+# -----------------------------------------------------------------------------
+last3 = $(word $(words $1), x x $1)
+
+# -----------------------------------------------------------------------------
+# Macro : this-makefile
+# Returns : the name of the current Makefile in the inclusion stack
+# Usage : $(this-makefile)
+# -----------------------------------------------------------------------------
+this-makefile = $(lastword $(MAKEFILE_LIST))
+
+# -----------------------------------------------------------------------------
+# Macro : local-makefile
+# Returns : the name of the last parsed Android.mk file
+# Usage : $(local-makefile)
+# -----------------------------------------------------------------------------
+local-makefile = $(lastword $(filter %Android.mk,$(MAKEFILE_LIST)))
+
+# -----------------------------------------------------------------------------
+# Function : assert-defined
+# Arguments: 1: list of variable names
+# Returns : None
+# Usage : $(call assert-defined, VAR1 VAR2 VAR3...)
+# Rationale: Checks that all variables listed in $1 are defined, or abort the
+# build
+# -----------------------------------------------------------------------------
+assert-defined = $(foreach __varname,$(strip $1),\
+ $(if $(strip $($(__varname))),,\
+ $(call __ndk_error, Assertion failure: $(__varname) is not defined)\
+ )\
+)
+
+# -----------------------------------------------------------------------------
+# Function : clear-vars
+# Arguments: 1: list of variable names
+# 2: file where the variable should be defined
+# Returns : None
+# Usage : $(call clear-vars, VAR1 VAR2 VAR3...)
+# Rationale: Clears/undefines all variables in argument list
+# -----------------------------------------------------------------------------
+clear-vars = $(foreach __varname,$1,$(eval $(__varname) := $(empty)))
+
+# -----------------------------------------------------------------------------
+# Function : check-required-vars
+# Arguments: 1: list of variable names
+# 2: file where the variable(s) should be defined
+# Returns : None
+# Usage : $(call check-required-vars, VAR1 VAR2 VAR3..., )
+# Rationale: Checks that all required vars listed in $1 were defined by $2
+# or abort the build with an error
+# -----------------------------------------------------------------------------
+check-required-vars = $(foreach __varname,$1,\
+ $(if $(strip $($(__varname))),,\
+ $(call __ndk_info, Required variable $(__varname) is not defined by $2)\
+ $(call __ndk_error,Aborting)\
+ )\
+)
+
+# -----------------------------------------------------------------------------
+# Function : modules-clear
+# Arguments: None
+# Returns : None
+# Usage : $(call modules-clear)
+# Rationale: clears the list of defined modules known by the build system
+# -----------------------------------------------------------------------------
+modules-clear = $(eval __ndk_modules := $(empty_set))
+
+# -----------------------------------------------------------------------------
+# Function : modules-add
+# Arguments: 1: module name
+# 2: path to Android.mk where the module is defined
+# Returns : None
+# Usage : $(call modules-add,,)
+# Rationale: add a new module. If it is already defined, print an error message
+# and abort.
+# -----------------------------------------------------------------------------
+modules-add = \
+ $(if $(call set_is_member,$(__ndk_modules),$1),\
+ $(call __ndk_info,Trying to define local module '$1' in $2.)\
+ $(call __ndk_info,But this module was already defined by $(__ndk_modules.$1).)\
+ $(call __ndk_error,Aborting.)\
+ )\
+ $(eval __ndk_modules := $(call set_insert,$(__ndk_modules),$1))\
+ $(eval __ndk_modules.$1 := $2)\
+
+# -----------------------------------------------------------------------------
+# Function : check-user-define
+# Arguments: 1: name of variable that must be defined by the user
+# 2: name of Makefile where the variable should be defined
+# 3: name/description of the Makefile where the check is done, which
+# must be included by $2
+# Returns : None
+# -----------------------------------------------------------------------------
+check-user-define = $(if $(strip $($1)),,\
+ $(call __ndk_error,Missing $1 before including $3 in $2))
+
+# -----------------------------------------------------------------------------
+# This is used to check that LOCAL_MODULE is properly defined by an Android.mk
+# file before including one of the $(BUILD_SHARED_LIBRARY), etc... files.
+#
+# Function : check-user-LOCAL_MODULE
+# Arguments: 1: name/description of the included build Makefile where the
+# check is done
+# Returns : None
+# Usage : $(call check-user-LOCAL_MODULE, BUILD_SHARED_LIBRARY)
+# -----------------------------------------------------------------------------
+check-defined-LOCAL_MODULE = \
+ $(call check-user-define,LOCAL_MODULE,$(local-makefile),$(1)) \
+ $(if $(call seq,$(words $(LOCAL_MODULE)),1),,\
+ $(call __ndk_info,LOCAL_MODULE definition in $(local-makefile) must not contain space)\
+ $(call __ndk_error,Please correct error. Aborting)\
+ )
+
+# -----------------------------------------------------------------------------
+# Strip any 'lib' prefix in front of a given string.
+#
+# Function : strip-lib-prefix
+# Arguments: 1: module name
+# Returns : module name, without any 'lib' prefix if any
+# Usage : $(call strip-lib-prefix,$(LOCAL_MODULE))
+# -----------------------------------------------------------------------------
+strip-lib-prefix = $(1:lib%=%)
+
+# -----------------------------------------------------------------------------
+# This is used to strip any lib prefix from LOCAL_MODULE, then check that
+# the corresponding module name is not already defined.
+#
+# Function : check-user-LOCAL_MODULE
+# Arguments: 1: path of Android.mk where this LOCAL_MODULE is defined
+# Returns : None
+# Usage : $(call check-LOCAL_MODULE,$(LOCAL_MAKEFILE))
+# -----------------------------------------------------------------------------
+check-LOCAL_MODULE = \
+ $(eval LOCAL_MODULE := $$(call strip-lib-prefix,$$(LOCAL_MODULE)))\
+ $(call modules-add,$(LOCAL_MODULE),$1)
+
+# -----------------------------------------------------------------------------
+# Macro : my-dir
+# Returns : the directory of the current Makefile
+# Usage : $(my-dir)
+# -----------------------------------------------------------------------------
+my-dir = $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST))))
+
+# -----------------------------------------------------------------------------
+# Function : all-makefiles-under
+# Arguments: 1: directory path
+# Returns : a list of all makefiles immediately below some directory
+# Usage : $(call all-makefiles-under, )
+# -----------------------------------------------------------------------------
+all-makefiles-under = $(wildcard $1/*/Android.mk)
+
+# -----------------------------------------------------------------------------
+# Macro : all-subdir-makefiles
+# Returns : list of all makefiles in subdirectories of the current Makefile's
+# location
+# Usage : $(all-subdir-makefiles)
+# -----------------------------------------------------------------------------
+all-subdir-makefiles = $(call all-makefiles-under,$(call my-dir))
+
+
+# =============================================================================
+#
+# Application.mk support
+#
+# =============================================================================
+
+# the list of variables that *must* be defined in Application.mk files
+NDK_APP_VARS_REQUIRED := APP_MODULES APP_PROJECT_PATH
+
+# the list of variables that *may* be defined in Application.mk files
+NDK_APP_VARS_OPTIONAL := APP_OPTIM APP_CPPFLAGS APP_CFLAGS APP_CXXFLAGS
+
+# the list of all variables that may appear in an Application.mk file
+NDK_APP_VARS := $(NDK_APP_VARS_REQUIRED) $(NDK_APPS_VARS_OPTIONAL)
+
+# =============================================================================
+#
+# Android.mk support
+#
+# =============================================================================
+
+
+# =============================================================================
+#
+# Generated files support
+#
+# =============================================================================
+
+
+# -----------------------------------------------------------------------------
+# Function : host-static-library-path
+# Arguments : 1: library module name (e.g. 'foo')
+# Returns : location of generated host library name (e.g. '..../libfoo.a)
+# Usage : $(call host-static-library-path,)
+# -----------------------------------------------------------------------------
+host-static-library-path = $(HOST_OUT)/lib$1.a
+
+# -----------------------------------------------------------------------------
+# Function : host-executable-path
+# Arguments : 1: executable module name (e.g. 'foo')
+# Returns : location of generated host executable name (e.g. '..../foo)
+# Usage : $(call host-executable-path,)
+# -----------------------------------------------------------------------------
+host-executable-path = $(HOST_OUT)/$1$(HOST_EXE)
+
+# -----------------------------------------------------------------------------
+# Function : static-library-path
+# Arguments : 1: library module name (e.g. 'foo')
+# Returns : location of generated static library name (e.g. '..../libfoo.a)
+# Usage : $(call static-library-path,)
+# -----------------------------------------------------------------------------
+static-library-path = $(TARGET_OUT)/lib$1.a
+
+# -----------------------------------------------------------------------------
+# Function : shared-library-path
+# Arguments : 1: library module name (e.g. 'foo')
+# Returns : location of generated shared library name (e.g. '..../libfoo.so)
+# Usage : $(call shared-library-path,)
+# -----------------------------------------------------------------------------
+shared-library-path = $(TARGET_OUT)/lib$1.so
+
+# -----------------------------------------------------------------------------
+# Function : executable-path
+# Arguments : 1: executable module name (e.g. 'foo')
+# Returns : location of generated exectuable name (e.g. '..../foo)
+# Usage : $(call executable-path,)
+# -----------------------------------------------------------------------------
+executable-path = $(TARGET_OUT)/$1
+
+# =============================================================================
+#
+# Build commands support
+#
+# =============================================================================
+
+# -----------------------------------------------------------------------------
+# Macro : hide
+# Returns : nothing
+# Usage : $(hide)
+# Rationale: To be used as a prefix for Make build commands to hide them
+# by default during the build. To show them, set V=1 in your
+# environment or command-line.
+#
+# For example:
+#
+# foo.o: foo.c
+# -->|$(hide)
+#
+# Where '-->|' stands for a single tab character.
+#
+# -----------------------------------------------------------------------------
+ifeq ($(V),1)
+hide = $(empty)
+else
+hide = @
+endif
+
+# -----------------------------------------------------------------------------
+# Template : ev-compile-c-source
+# Arguments : 1: single C source file name (relative to LOCAL_PATH)
+# 2: target object file (without path)
+# Returns : None
+# Usage : $(eval $(call ev-compile-c-source,,)
+# Rationale : Internal template evaluated by compile-c-source and
+# compile-s-source
+# -----------------------------------------------------------------------------
+define ev-compile-c-source
+_SRC:=$$(LOCAL_PATH)/$(1)
+_OBJ:=$$(LOCAL_OBJS_DIR)/$(2)
+
+$$(_OBJ): PRIVATE_SRC := $$(_SRC)
+$$(_OBJ): PRIVATE_OBJ := $$(_OBJ)
+$$(_OBJ): PRIVATE_MODULE := $$(LOCAL_MODULE)
+$$(_OBJ): PRIVATE_ARM_MODE := $$(LOCAL_ARM_MODE)
+$$(_OBJ): PRIVATE_ARM_TEXT := $$(LOCAL_ARM_TEXT)
+$$(_OBJ): PRIVATE_CC := $$($$(my)CC)
+$$(_OBJ): PRIVATE_CFLAGS := $$($$(my)CFLAGS) \
+ $$($$(my)_$(LOCAL_ARM_MODE)_$(LOCAL_BUILD_MODE)_CFLAGS) \
+ -I$$(LOCAL_PATH) \
+ -I$$(OBJS_DIR) \
+ $$(LOCAL_CFLAGS) \
+ $$(NDK_APP_CPPFLAGS) \
+ $$(NDK_APP_CFLAGS) \
+ $$(LOCAL_ARM_CFLAGS)
+
+$$(_OBJ): $$(_SRC) $$(LOCAL_MAKEFILE) $$(NDK_APP_APPLICATION_MK)
+ @mkdir -p $$(dir $$(PRIVATE_OBJ))
+ @echo "Compile $$(PRIVATE_ARM_TEXT) : $$(PRIVATE_MODULE) <= $$(PRIVATE_SRC)"
+ $(hide) $$(PRIVATE_CC) $$(PRIVATE_CFLAGS) -c \
+ -MMD -MP -MF $$(PRIVATE_OBJ).d.tmp \
+ $$(PRIVATE_SRC) \
+ -o $$(PRIVATE_OBJ)
+ $$(call cmd-process-deps,$$(PRIVATE_OBJ))
+
+LOCAL_OBJECTS += $$(_OBJ)
+LOCAL_DEPENDENCY_DIRS += $$(dir $$(_OBJ))
+endef
+
+# -----------------------------------------------------------------------------
+# Function : compile-c-source
+# Arguments : 1: single C source file name (relative to LOCAL_PATH)
+# Returns : None
+# Usage : $(call compile-c-source,)
+# Rationale : Setup everything required to build a single C source file
+# -----------------------------------------------------------------------------
+compile-c-source = $(eval $(call ev-compile-c-source,$1,$(1:%.c=%.o)))
+
+# -----------------------------------------------------------------------------
+# Function : compile-s-source
+# Arguments : 1: single Assembly source file name (relative to LOCAL_PATH)
+# Returns : None
+# Usage : $(call compile-s-source,)
+# Rationale : Setup everything required to build a single Assembly source file
+# -----------------------------------------------------------------------------
+compile-s-source = $(eval $(call ev-compile-s-source,$1,$(1:%.S=%.o)))
+
+
+# -----------------------------------------------------------------------------
+# Template : ev-compile-cpp-source
+# Arguments : 1: single C++ source file name (relative to LOCAL_PATH)
+# 2: target object file (without path)
+# Returns : None
+# Usage : $(eval $(call ev-compile-cpp-source,,)
+# Rationale : Internal template evaluated by compile-cpp-source
+# -----------------------------------------------------------------------------
+
+define ev-compile-cpp-source
+_SRC:=$$(LOCAL_PATH)/$(1)
+_OBJ:=$$(LOCAL_OBJS_DIR)/$(2)
+
+$$(_OBJ): PRIVATE_SRC := $$(_SRC)
+$$(_OBJ): PRIVATE_OBJ := $$(_OBJ)
+$$(_OBJ): PRIVATE_MODULE := $$(LOCAL_MODULE)
+$$(_OBJ): PRIVATE_ARM_MODE := $$(LOCAL_ARM_MODE)
+$$(_OBJ): PRIVATE_ARM_TEXT := $$(LOCAL_ARM_TEXT)
+$$(_OBJ): PRIVATE_CXX := $$($$(my)CXX)
+$$(_OBJ): PRIVATE_CXXFLAGS := $$($$(my)CXXFLAGS) \
+ $$($$(my)_$(LOCAL_ARM_MODE)_$(LOCAL_BUILD_MODE)_CFLAGS) \
+ -I$$(LOCAL_PATH) \
+ -I$$(OBJS_DIR) \
+ $$(LOCAL_CFLAGS) \
+ $$(NDK_APP_CPPFLAGS) \
+ $$(NDK_APP_CXXFLAGS) \
+ $$(LOCAL_ARM_CFLAGS)
+
+$$(_OBJ): $$(_SRC) $$(LOCAL_MAKEFILE) $$(NDK_APP_APPLICATION_MK)
+ @mkdir -p $$(dir $$(PRIVATE_OBJ))
+ @echo "Compile++ $$(PRIVATE_ARM_TEXT): $$(PRIVATE_MODULE) <= $$(PRIVATE_SRC)"
+ $(hide) $$(PRIVATE_CXX) $$(PRIVATE_CXXFLAGS) -c \
+ -MMD -MP -MF $$(PRIVATE_OBJ).d.tmp \
+ $$(PRIVATE_SRC) \
+ -o $$(PRIVATE_OBJ)
+ $$(call cmd-process-deps,$$(PRIVATE_OBJ))
+
+LOCAL_OBJECTS += $$(_OBJ)
+LOCAL_DEPENDENCY_DIRS += $$(dir $$(_OBJ))
+endef
+
+# -----------------------------------------------------------------------------
+# Function : compile-cpp-source
+# Arguments : 1: single C++ source file name (relative to LOCAL_PATH)
+# Returns : None
+# Usage : $(call compile-c-source,)
+# Rationale : Setup everything required to build a single C++ source file
+# -----------------------------------------------------------------------------
+compile-cpp-source = $(eval $(call ev-compile-cpp-source,$1,$(1:%$(LOCAL_CPP_EXTENSION)=%.o)))
+
+# -----------------------------------------------------------------------------
+# Command : cmd-process-deps
+# Arguments : 1: object file path
+# Returns : None
+# Usage : $(call cmd-process-deps,)
+# Rationale : To be used as a Make build command to process the dependencies
+# generated by the compiler (in .d.tmp) into ones suited
+# for our build system. See the comments in build/core/mkdeps.sh
+# for more details.
+# -----------------------------------------------------------------------------
+cmd-process-deps = $(hide) $(BUILD_SYSTEM)/mkdeps.sh $(1) $(1).d.tmp $(1).d
+
+# -----------------------------------------------------------------------------
+# Command : cmd-install-file
+# Arguments : 1: source file
+# 2: destination file
+# Returns : None
+# Usage : $(call cmd-install-file,,)
+# Rationale : To be used as a Make build command to copy/install a file to
+# a given location.
+# -----------------------------------------------------------------------------
+define cmd-install-file
+@mkdir -p $(dir $2)
+$(hide) cp -fp $1 $2
+endef
diff --git a/ndk/build/core/main.mk b/ndk/build/core/main.mk
new file mode 100644
index 000000000..a82e77ef3
--- /dev/null
+++ b/ndk/build/core/main.mk
@@ -0,0 +1,287 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# ====================================================================
+#
+# Define the main configuration variables, and read the host-specific
+# configuration file that is normally generated by build/host-setup.sh
+#
+# ====================================================================
+
+# Include common definitions
+include build/core/definitions.mk
+
+# The location of the build system files
+BUILD_SYSTEM := build/core
+
+# Where all generated files will be stored during a build
+NDK_OUT := out
+
+# Read the host-specific configuration file in $(NDK_OUT)
+#
+HOST_CONFIG_MAKE := $(NDK_OUT)/host/config.mk
+
+ifeq ($(strip $(wildcard $(HOST_CONFIG_MAKE))),)
+ $(call __ndk_info,\
+ The configuration file '$(HOST_CONFIG_MAKE)' doesnt' exist.)
+ $(call __ndk_info,\
+ Please run 'build/host-setup.sh' to generate it.)
+ $(call __ndk_error, Aborting)
+endif
+
+include $(HOST_CONFIG_MAKE)
+HOST_PREBUILT_TAG := $(HOST_TAG)
+
+# Location where all prebuilt binaries for a given host architectures
+# will be stored.
+HOST_PREBUILT := build/prebuilt/$(HOST_TAG)
+
+# Where all app-specific generated files will be stored
+NDK_APP_OUT := $(NDK_OUT)/apps
+
+# Where all host-specific generated files will be stored
+NDK_HOST_OUT := $(NDK_OUT)/host/$(HOST_TAG)
+
+# ====================================================================
+#
+# Read all toolchain-specific configuration files.
+#
+# Each toolchain must have a corresponding config.mk file located
+# in build/toolchains// that will be included here.
+#
+# Each one of these files should define the following variables:
+# TOOLCHAIN_NAME toolchain name (e.g. arm-eabi-4.2.1)
+# TOOLCHAIN_ABIS list of target ABIs supported by the toolchain.
+#
+# Then, it should include $(ADD_TOOLCHAIN) which will perform
+# book-keeping for the build system.
+#
+# ====================================================================
+
+# the build script to include in each toolchain config.mk
+ADD_TOOLCHAIN := $(BUILD_SYSTEM)/add-toolchain.mk
+
+# the list of all toolchains in this NDK
+NDK_ALL_TOOLCHAINS :=
+NDK_ALL_ABIS :=
+
+TOOLCHAIN_CONFIGS := $(wildcard build/toolchains/*/config.mk)
+$(foreach _config_mk,$(TOOLCHAIN_CONFIGS),\
+ $(eval include $(BUILD_SYSTEM)/add-toolchain.mk)\
+)
+
+#$(info ALL_TOOLCHAINS=$(ALL_TOOLCHAINS))
+NDK_TARGET_TOOLCHAIN := $(firstword $(NDK_ALL_TOOLCHAINS))
+$(call ndk_log, Default toolchain is $(NDK_TARGET_TOOLCHAIN))
+
+NDK_ALL_TOOLCHAINS := $(call uniq,$(NDK_ALL_TOOLCHAINS))
+NDK_ALL_ABIS := $(call uniq,$(NDK_ALL_ABIS))
+
+$(call ndk_log, This NDK supports the following toolchains and target ABIs:)
+$(foreach tc,$(NDK_ALL_TOOLCHAINS),\
+ $(call ndk_log, $(space)$(space)$(tc): $(NDK_TOOLCHAIN.$(tc).abis))\
+)
+
+# ====================================================================
+#
+# Read all application configuration files
+#
+# Each 'application' must have a corresponding Application.mk file
+# located in apps/ where is a liberal name that doesn't
+# contain any space in it, used to uniquely identify the
+#
+# Each one of these files should define the following required
+# variables:
+#
+# APP_MODULES the list of modules needed by this application
+#
+# APP_PROJECT_PATH
+# path to the Java project root directory where the
+# generated binaries will be copied to. The NDK will
+# place them in appropriate locations so they are
+# properly picked by aapt, the Android Packager tool,
+# when generating your applications.
+#
+# As well as the following *optional* variables:
+#
+# APP_OPTIM either 'release' or 'debug'
+#
+# APP_CPPFLAGS extra flags passed when building C and C++ sources
+# of application modules
+#
+# APP_CFLAGS extra flags passed when building C sources of
+# application's modules (not C++ ones)
+#
+# APP_CXXFLAGS extra flags passed when building C++ sources of
+# application's modules (not C ones)
+#
+# ====================================================================
+
+NDK_ALL_APPS :=
+
+NDK_APPLICATIONS := $(wildcard apps/*/Application.mk)
+$(foreach _application_mk, $(NDK_APPLICATIONS),\
+ $(eval include $(BUILD_SYSTEM)/add-application.mk)\
+)
+
+# clean up environment, just to be safe
+$(call clear-vars, $(NDK_APP_VARS))
+
+ifeq ($(strip $(NDK_ALL_APPS)),)
+ $(call __ndk_info,\
+ The NDK could not find a proper application description under apps/*/Application.mk)
+ $(call __ndk_info,\
+ Please follow the instructions in docs/NDK-APPS.TXT to write one.)
+ $(call __ndk_error, Aborting)
+endif
+
+ifeq ($(strip $(APP)),)
+ $(call __ndk_info,\
+ The APP variable is undefined or empty.)
+ $(call __ndk_info,\
+ Please define it to one of: $(NDK_ALL_APPS))
+ $(call __ndk_info,\
+ You can also add new applications by writing an Application.mk file.)
+ $(call __ndk_info,\
+ See docs/APPLICATION-MK.TXT for details.)
+ $(call __ndk_error, Aborting)
+endif
+
+# now check that APP doesn't contain an unknown app name
+# if it does, we ignore them if there is at least one known
+# app name in the list. Otherwise, abort with an error message
+#
+_unknown_apps := $(filter-out $(NDK_ALL_APPS),$(APP))
+_known_apps := $(filter $(NDK_ALL_APPS),$(APP))
+
+NDK_APPS := $(APP)
+
+$(if $(_unknown_apps),\
+ $(if $(_known_apps),\
+ $(call __ndk_info,WARNING:\
+ Removing unknown names from APP variable: $(_unknown_apps))\
+ $(eval NDK_APPS := $(_known_apps))\
+ ,\
+ $(call __ndk_info,\
+ The APP variable contains unknown app names: $(_unknown_apps))\
+ $(call __ndk_info,\
+ Please use one of: $(NDK_ALL_APPS))\
+ $(call __ndk_error, Aborting)\
+ )\
+)
+
+$(call __ndk_info,Building for application '$(NDK_APPS)')
+
+# ====================================================================
+#
+# Prepare the build for parsing Android.mk files
+#
+# ====================================================================
+
+# These phony targets are used to control various stages of the build
+.PHONY: all \
+ host_libraries host_executables \
+ executables libraries static_libraries shared_libraries \
+ clean clean-config clean-objs-dir \
+ clean-executables clean-libraries
+
+# These macros are used in Android.mk to include the corresponding
+# build script that will parse the LOCAL_XXX variable definitions.
+#
+CLEAR_VARS := $(BUILD_SYSTEM)/clear-vars.mk
+BUILD_HOST_EXECUTABLE := $(BUILD_SYSTEM)/build-host-executable.mk
+BUILD_HOST_STATIC_LIBRARY := $(BUILD_SYSTEM)/build-host-static-library.mk
+BUILD_STATIC_LIBRARY := $(BUILD_SYSTEM)/build-static-library.mk
+BUILD_SHARED_LIBRARY := $(BUILD_SYSTEM)/build-shared-library.mk
+BUILD_EXECUTABLE := $(BUILD_SYSTEM)/build-executable.mk
+
+ANDROID_MK_INCLUDED := \
+ $(CLEAR_VARS) \
+ $(BUILD_HOST_EXECUTABLE) \
+ $(BUILD_HOST_STATIC_LIBRARY) \
+ $(BUILD_STATIC_LIBRARY) \
+ $(BUILD_SHARED_LIBRARY) \
+ $(BUILD_EXECUTABLE) \
+
+
+# this is the list of directories containing dependency information
+# generated during the build. It will be updated by build scripts
+# when module definitions are parsed.
+#
+DEPENDENCY_DIRS :=
+
+# this is the list of all generated files that we would need to clean
+ALL_HOST_EXECUTABLES :=
+ALL_HOST_STATIC_LIBRARIES :=
+ALL_STATIC_LIBRARIES :=
+ALL_SHARED_LIBRARIES :=
+ALL_EXECUTABLES :=
+
+# the first rule
+all: libraries executables
+
+# ====================================================================
+#
+# For each platform/abi combo supported by the application, we should
+# setup the toolchain and parse all module definitions files again
+# to build the right dependency tree.
+#
+# All this work is performed by build/core/setup-toolchain.mk
+#
+# ====================================================================
+
+
+# XXX: For now, only support one platform and one target ABI with
+# only one toolchain.
+#
+TARGET_PLATFORM := android-1.5
+TARGET_ARCH_ABI := arm
+TARGET_ARCH := arm
+TARGET_TOOLCHAIN := $(NDK_TARGET_TOOLCHAIN)
+
+include build/core/setup-toolchain.mk
+
+# ====================================================================
+#
+# Now finish the build preparation with a few rules that depend on
+# what has been effectively parsed and recorded previously
+#
+# ====================================================================
+
+clean: clean-intermediates
+
+distclean: clean clean-config
+
+host_libraries: $(HOST_STATIC_LIBRARIES)
+host_executables: $(HOST_EXECUTABLES)
+
+static_libraries: $(STATIC_LIBRARIES)
+shared_libraries: $(SHARED_LIBRARIES)
+executables: $(EXECUTABLES)
+
+libraries: static_libraries shared_libraries
+
+clean-host-intermediates:
+ $(hide) rm -rf $(NDK_HOST_OUT)/objs $(HOST_EXECUTABLES) $(HOST_STATIC_LIBRARIES)
+
+clean-intermediates: clean-host-intermediates
+ $(hide) rm -rf $(NDK_HOST_OUT)/objs $(EXECUTABLES) $(STATIC_LIBRARIES) $(SHARED_LIBRARIES)
+
+clean-config:
+ $(hide) rm -f $(CONFIG_MAKE) $(CONFIG_H)
+
+# include dependency information
+DEPENDENCY_DIRS := $(sort $(DEPENDENCY_DIRS))
+-include $(wildcard $(DEPENDENCY_DIRS:%=%/*.d))
diff --git a/ndk/build/core/mkdeps.sh b/ndk/build/core/mkdeps.sh
new file mode 100755
index 000000000..abecec74a
--- /dev/null
+++ b/ndk/build/core/mkdeps.sh
@@ -0,0 +1,51 @@
+#!/bin/sh
+#
+# Copyright (C) 2008 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# This script is used to transform the dependency files generated by GCC
+# For example, a typical .d file will have a line like:
+#
+# source.o: /full/path/to/source.c other.h headers.h
+# ...
+#
+# the script is used to replace 'source.o' to a full path, as in
+#
+# objs/intermediates/emulator/source.o: /full/path/to/source.c other.h headers.h
+#
+# parameters
+#
+# $1: object file (full path)
+# $2: source dependency file to modify (erased on success)
+# $3: target source dependency file
+#
+
+# quote the object path. we change a single '.' into
+# a '\.' since this will be parsed by sed.
+#
+OBJECT=`echo $1 | sed -e s/\\\\./\\\\\\\\./g`
+#echo OBJECT=$OBJECT
+
+OBJ_NAME=`basename $OBJECT`
+#echo OBJ_NAME=$OBJ_NAME
+
+# we replace $OBJ_NAME with $OBJECT only if $OBJ_NAME starts the line
+# that's because some versions of GCC (e.g. 4.2.3) already produce
+# a correct dependency line with the full path to the object file.
+# In this case, we don't want to touch anything
+#
+cat $2 | sed -e s%^$OBJ_NAME%$OBJECT%g > $3 && rm -f $2
+
+
+
diff --git a/ndk/build/core/ndk-common.sh b/ndk/build/core/ndk-common.sh
new file mode 100644
index 000000000..c89ffd958
--- /dev/null
+++ b/ndk/build/core/ndk-common.sh
@@ -0,0 +1,396 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# A collection of shell function definitions used by various build scripts
+# in the Android NDK (Native Development Kit)
+#
+
+# Get current script name into PROGNAME
+PROGNAME=`basename $0`
+
+# Put location of Android NDK into ANDROID_NDK_ROOT and
+# perform a tiny amount of sanity check
+#
+if [ -z "$ANDROID_NDK_ROOT" ] ; then
+ if [ ! -f build/core/ndk-common.sh ] ; then
+ echo "Please define ANDROID_NDK_ROOT to point to the root of your"
+ echo "Android NDK installation."
+ exit 1
+ fi
+ ANDROID_NDK_ROOT=.
+fi
+
+if [ ! -d $ANDROID_NDK_ROOT ] ; then
+ echo "ERROR: Your ANDROID_NDK_ROOT variable does not point to a directory."
+ exit 1
+fi
+
+if [ ! -f $ANDROID_NDK_ROOT/build/core/ndk-common.sh ] ; then
+ echo "ERROR: Your ANDROID_NDK_ROOT variable does not point to a valid directory."
+ exit 1
+fi
+
+## Logging support
+##
+VERBOSE=${VERBOSE-yes}
+VERBOSE2=${VERBOSE2-no}
+
+log ()
+{
+ if [ "$VERBOSE" = "yes" ] ; then
+ echo "$1"
+ fi
+}
+
+log2 ()
+{
+ if [ "$VERBOSE2" = "yes" ] ; then
+ echo "$1"
+ fi
+}
+
+## Utilities
+##
+
+# return the value of a given named variable
+# $1: variable name
+#
+# example:
+# FOO=BAR
+# BAR=ZOO
+# echo `var_value $FOO`
+# will print 'ZOO'
+#
+var_value ()
+{
+ # find a better way to do that ?
+ eval echo "$`echo $1`"
+}
+
+# convert to uppercase
+# assumes tr is installed on the platform ?
+#
+to_uppercase ()
+{
+ echo $1 | tr "[:lower:]" "[:upper:]"
+}
+
+## Normalize OS and CPU
+##
+HOST_ARCH=`uname -m`
+case "$HOST_ARCH" in
+ i?86) HOST_ARCH=x86
+ ;;
+ amd64) HOST_ARCH=x86_64
+ ;;
+ powerpc) HOST_ARCH=ppc
+ ;;
+esac
+
+log2 "HOST_ARCH=$HOST_ARCH"
+
+# at this point, the supported values for CPU are:
+# x86
+# x86_64
+# ppc
+#
+# other values may be possible but haven't been tested
+#
+HOST_EXE=""
+HOST_OS=`uname -s`
+case "$HOST_OS" in
+ Darwin)
+ HOST_OS=darwin
+ ;;
+ Linux)
+ # note that building 32-bit binaries on x86_64 is handled later
+ HOST_OS=linux
+ ;;
+ FreeBsd) # note: this is not tested
+ HOST_OS=freebsd
+ ;;
+ CYGWIN*|*_NT-*)
+ HOST_OS=windows
+ HOST_EXE=.exe
+ if [ "x$OSTYPE" = xcygwin ] ; then
+ HOST_OS=cygwin
+ HOST_CFLAGS="$CFLAGS -mno-cygwin"
+ HOST_LDFLAGS="$LDFLAGS -mno-cygwin"
+ fi
+ ;;
+esac
+
+log2 "HOST_OS=$HOST_OS"
+log2 "HOST_EXE=$HOST_EXE"
+
+# at this point, the value of HOST_OS should be one of the following:
+# linux
+# darwin
+# windows (MSys)
+# cygwin
+#
+# Note that cygwin is treated as a special case because it behaves very differently
+# for a few things. Other values may be possible but have not been tested
+#
+
+# define HOST_TAG as a unique tag used to identify both the host OS and CPU
+# supported values are:
+#
+# linux-x86
+# linux-x86_64
+# darwin-x86
+# darwin-ppc
+# windows
+#
+# other values are possible but were not tested.
+#
+compute_host_tag ()
+{
+ case "$HOST_OS" in
+ windows|cygwin)
+ HOST_TAG="windows"
+ ;;
+ *) HOST_TAG="${HOST_OS}-${HOST_ARCH}"
+ esac
+ log2 "HOST_TAG=$HOST_TAG"
+}
+
+compute_host_tag
+
+# Compute the number of host CPU cores an HOST_NUM_CPUS
+#
+case "$HOST_OS" in
+ linux)
+ HOST_NUM_CPUS=`cat /proc/cpuinfo | grep processor | wc -l`
+ ;;
+ darwin|freebsd)
+ HOST_NUM_CPUS=`sysctl -n hw.ncpu`
+ ;;
+ windows|cygwin)
+ HOST_NUM_CPUS=$NUMBER_OF_PROCESSORS
+ ;;
+ *) # let's play safe here
+ HOST_NUM_CPUS=1
+esac
+
+log2 "HOST_NUM_CPUS=$HOST_NUM_CPUS"
+
+# If BUILD_NUM_CPUS is not already defined in your environment,
+# define it as the double of HOST_NUM_CPUS. This is used to
+# run Make commends in parralles, as in 'make -j$BUILD_NUM_CPUS'
+#
+if [ -z "$BUILD_NUM_CPUS" ] ; then
+ BUILD_NUM_CPUS=`expr $HOST_NUM_CPUS \* 2`
+fi
+
+log2 "BUILD_NUM_CPUS=$BUILD_NUM_CPUS"
+
+
+## HOST TOOLCHAIN SUPPORT
+##
+
+# force the generation of 32-bit binaries on 64-bit systems
+#
+FORCE_32BIT=no
+force_32bit_binaries ()
+{
+ if [ "$HOST_ARCH" = x86_64 ] ; then
+ log2 "Forcing generation of 32-bit host binaries on $HOST_ARCH"
+ FORCE_32BIT=yes
+ HOST_ARCH=x86
+ log2 "HOST_ARCH=$HOST_ARCH"
+ compute_host_tag
+ fi
+}
+
+# On Windows, cygwin binaries will be generated by default, but
+# you can force mingw ones that do not link to cygwin.dll if you
+# call this function.
+#
+disable_cygwin ()
+{
+ if [ $OS = cygwin ] ; then
+ log2 "Disabling cygwin binaries generation"
+ CFLAGS="$CFLAGS -mno-cygwin"
+ LDFLAGS="$LDFLAGS -mno-cygwin"
+ OS=windows
+ HOST_OS=windows
+ compute_host_tag
+ fi
+}
+
+# Various probes are going to need to run a small C program
+TMPC=/tmp/android-$$-test.c
+TMPO=/tmp/android-$$-test.o
+TMPE=/tmp/android-$$-test$EXE
+TMPL=/tmp/android-$$-test.log
+
+# cleanup temporary files
+clean_temp ()
+{
+ rm -f $TMPC $TMPO $TMPL $TMPE
+}
+
+# cleanup temp files then exit with an error
+clean_exit ()
+{
+ clean_temp
+ exit 1
+}
+
+# this function will setup the compiler and linker and check that they work as advertised
+# note that you should call 'force_32bit_binaries' before this one if you want it to
+# generate 32-bit binaries on 64-bit systems (that support it).
+#
+setup_toolchain ()
+{
+ if [ -z "$CC" ] ; then
+ CC=gcc
+ fi
+
+ log2 "Using '$CC' as the C compiler"
+
+ # check that we can compile a trivial C program with this compiler
+ cat > $TMPC < $TMPC <
+using namespace std;
+int main()
+{
+ cout << "Hello World!" << endl;
+ return 0;
+}
+EOF
+
+ compile_cpp
+ if [ $? != 0 ] ; then
+ echo "your C++ compiler doesn't seem to work"
+ cat $TMPL
+ clean_exit
+ fi
+
+ log "CXX : C++ compiler check ok ($CXX)"
+
+ # XXX: TODO perform AR checks
+ AR=ar
+ ARFLAGS=
+}
+
+# try to compile the current source file in $TMPC into an object
+# stores the error log into $TMPL
+#
+compile ()
+{
+ log2 "Object : $CC -o $TMPO -c $CFLAGS $TMPC"
+ $CC -o $TMPO -c $CFLAGS $TMPC 2> $TMPL
+}
+
+compile_cpp ()
+{
+ log2 "Object : $CXX -o $TMPO -c $CXXFLAGS $TMPC"
+ $CXX -o $TMPO -c $CXXFLAGS $TMPC 2> $TMPL
+}
+
+# try to link the recently built file into an executable. error log in $TMPL
+#
+link()
+{
+ log2 "Link : $LD -o $TMPE $TMPO $LDFLAGS"
+ $LD -o $TMPE $TMPO $LDFLAGS 2> $TMPL
+}
+
+# run a command
+#
+execute()
+{
+ log2 "Running: $*"
+ $*
+}
+
+# perform a simple compile / link / run of the source file in $TMPC
+compile_exec_run()
+{
+ log2 "RunExec : $CC -o $TMPE $CFLAGS $TMPC"
+ compile
+ if [ $? != 0 ] ; then
+ echo "Failure to compile test program"
+ cat $TMPC
+ cat $TMPL
+ clean_exit
+ fi
+ link
+ if [ $? != 0 ] ; then
+ echo "Failure to link test program"
+ cat $TMPC
+ echo "------"
+ cat $TMPL
+ clean_exit
+ fi
+ $TMPE
+}
diff --git a/ndk/build/core/setup-app.mk b/ndk/build/core/setup-app.mk
new file mode 100644
index 000000000..7f7e8b467
--- /dev/null
+++ b/ndk/build/core/setup-app.mk
@@ -0,0 +1,68 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included repeatedly from build/core/setup-toolchain.mk
+# and is used to prepare for app-specific build rules.
+#
+
+$(call assert-defined,_app)
+
+# the location of generated files for this app
+HOST_OUT := $(NDK_APP_OUT)/$(_app)/$(HOST_TAG)
+HOST_OBJS := $(HOST_OUT)/objs
+
+TARGET_OUT := $(NDK_APP_OUT)/$(_app)/$(TARGET_ABI)
+TARGET_OBJS := $(TARGET_OUT)/objs
+
+TARGET_GDB_SETUP := $(TARGET_OUT)/setup.gdb
+
+# ok, let's parse all Android.mk source files in order to build
+# the modules for this app.
+#
+
+# Restore the APP_XXX variables just for this pass as NDK_APP_XXX
+#
+NDK_APP_NAME := $(_app)
+NDK_APP_APPLICATION_MK := $(NDK_APP.$(_app).Application.mk)
+
+$(foreach __name,$(NDK_APP_VARS),\
+ $(eval NDK_$(__name) := $(NDK_APP.$(_app).$(__name)))\
+)
+
+# set release/debug build flags
+#
+ifeq ($(NDK_APP_OPTIM),debug)
+ NDK_APP_CPPFLAGS := -O0 -g $(NDK_APP_CPPFLAGS)
+else
+ NDK_APP_CPPFLAGS := -O2 -DNDEBUG -g $(NDK_APP_CPPFLAGS)
+endif
+
+# compute NDK_APP_DEST as the destination directory for the generated files
+NDK_APP_DEST := $(NDK_APP_PROJECT_PATH)/libs/$(TARGET_ABI_SUBDIR)
+
+# make the application depend on the modules it requires
+.PHONY: ndk-app-$(_app)
+ndk-app-$(_app): $(NDK_APP_MODULES)
+all: ndk-app-$(_app)
+
+# free the dictionary of LOCAL_MODULE definitions
+$(call modules-clear)
+
+# now parse all Android.mk build files
+#
+# this will include stuff like build/core/static-library.mk and others
+# for each module to be defined.
+#
+include sources/*/Android.mk
diff --git a/ndk/build/core/setup-toolchain.mk b/ndk/build/core/setup-toolchain.mk
new file mode 100644
index 000000000..12cebce73
--- /dev/null
+++ b/ndk/build/core/setup-toolchain.mk
@@ -0,0 +1,45 @@
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+# this file is included repeatedly from build/core/main.mk and is used
+# to setup the target toolchain for a given platform/abi combination.
+#
+
+$(call assert-defined,TARGET_TOOLCHAIN TARGET_PLATFORM TARGET_ARCH TARGET_ARCH_ABI)
+$(call assert-defined,NDK_APPS)
+
+TARGET_ABI := $(TARGET_PLATFORM)-$(TARGET_ARCH_ABI)
+
+# setup sysroot-related variables. The SYSROOT point to a directory
+# that contains all public header files for a given platform, plus
+# some libraries and object files used for linking the generated
+# target files properly.
+#
+SYSROOT := build/platforms/$(TARGET_PLATFORM)/arch-$(TARGET_ARCH_ABI)
+
+TARGET_CRTBEGIN_STATIC_O := $(SYSROOT)/usr/lib/crtbegin_static.o
+TARGET_CRTBEGIN_DYNAMIC_O := $(SYSROOT)/usr/lib/crtbegin_dynamic.o
+TARGET_CRTEND_O := $(SYSROOT)/usr/lib/crtend_android.o
+
+TARGET_PREBUILT_SHARED_LIBRARIES := libc libstdc++ libm
+TARGET_PREBUILT_SHARED_LIBRARIES := $(TARGET_PREBUILT_SHARED_LIBRARIES:%=$(SYSROOT)/usr/lib/%.so)
+
+# now call the toolchain-specific setup script
+include $(NDK_TOOLCHAIN.$(TARGET_TOOLCHAIN).setup)
+
+# For each app, compute intermediate directories and parse module sources
+$(foreach _app,$(NDK_APPS),\
+ $(eval include $(BUILD_SYSTEM)/setup-app.mk)\
+)
diff --git a/ndk/build/gmsl/README b/ndk/build/gmsl/README
new file mode 100644
index 000000000..152ada660
--- /dev/null
+++ b/ndk/build/gmsl/README
@@ -0,0 +1,27 @@
+GNU Make Standard Library
+-------------------------
+
+1. Visit http://gmsl.sf.net for more details
+
+2. To use the GMSL in your Makefile make sure that you have the files
+
+ gmsl
+ __gmsl
+
+ Add
+
+ include gmsl
+
+ to your Makefile(s).
+
+3. To run the GMSL test suite have
+
+ gmsl
+ __gmsl
+ gmsl-tests
+
+ And then run
+
+ make -f gmsl-tests
+
+
\ No newline at end of file
diff --git a/ndk/build/gmsl/__gmsl b/ndk/build/gmsl/__gmsl
new file mode 100644
index 000000000..596ff1911
--- /dev/null
+++ b/ndk/build/gmsl/__gmsl
@@ -0,0 +1,854 @@
+# ----------------------------------------------------------------------------
+#
+# GNU Make Standard Library (GMSL)
+#
+# A library of functions to be used with GNU Make's $(call) that
+# provides functionality not available in standard GNU Make.
+#
+# Copyright (c) 2005-2007 John Graham-Cumming
+#
+# This file is part of GMSL
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# Neither the name of the John Graham-Cumming nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+# POSSIBILITY OF SUCH DAMAGE.
+#
+# ----------------------------------------------------------------------------
+
+# This is the GNU Make Standard Library version number as a list with
+# three items: major, minor, revision
+
+gmsl_version := 1 0 11
+
+# Used to output warnings and error from the library, it's possible to
+# disable any warnings or errors by overriding these definitions
+# manually or by setting GMSL_NO_WARNINGS or GMSL_NO_ERRORS
+
+__gmsl_name := GNU Make Standard Library
+__gmsl_warning = $(warning $(__gmsl_name): $1)
+__gmsl_error = $(error $(__gmsl_name): $1)
+
+ifdef GMSL_NO_WARNINGS
+__gmsl_warning :=
+endif
+ifdef GMSL_NO_ERRORS
+__gmsl_error :=
+endif
+
+# If GMSL_TRACE is enabled then calls to the library functions are
+# traced to stdout using warning messages with their arguments
+
+ifdef GMSL_TRACE
+__gmsl_tr1 = $(warning $0('$1'))
+__gmsl_tr2 = $(warning $0('$1','$2'))
+__gmsl_tr3 = $(warning $0('$1','$2','$3'))
+else
+__gmsl_tr1 :=
+__gmsl_tr2 :=
+__gmsl_tr3 :=
+endif
+
+# Figure out whether we have $(eval) or not (GNU Make 3.80 and above)
+# if we do not then output a warning message, if we do then some
+# functions will be enabled.
+
+__gmsl_have_eval := $(false)
+__gmsl_ignore := $(eval __gmsl_have_eval := $(true))
+
+# If this is being run with Electric Cloud's emake then warn that
+# their $(eval) support is incomplete.
+
+ifdef ECLOUD_BUILD_ID
+$(warning You are using Electric Cloud's emake which has incomplete $$(eval) support)
+__gmsl_have_eval := $(false)
+endif
+
+# See if we have $(lastword) (GNU Make 3.81 and above)
+
+__gmsl_have_lastword := $(lastword $(false) $(true))
+
+# See if we have native or and and (GNU Make 3.81 and above)
+
+__gmsl_have_or := $(if $(filter-out undefined, \
+ $(origin or)),$(call or,$(true),$(false)))
+__gmsl_have_and := $(if $(filter-out undefined, \
+ $(origin and)),$(call and,$(true),$(true)))
+
+ifneq ($(__gmsl_have_eval),$(true))
+$(call __gmsl_warning,GNU Make $(MAKE_VERSION) does not support $$$$(eval): some functions disabled)
+endif
+
+# ----------------------------------------------------------------------------
+# Function: gmsl_compatible
+# Arguments: List containing the desired library version number (maj min rev)
+# Returns: $(true) if this version of the library is compatible
+# with the requested version number, otherwise $(false)
+# ----------------------------------------------------------------------------
+gmsl_compatible = $(strip \
+ $(if $(call gt,$(word 1,$1),$(word 1,$(gmsl_version))), \
+ $(false), \
+ $(if $(call lt,$(word 1,$1),$(word 1,$(gmsl_version))), \
+ $(true), \
+ $(if $(call gt,$(word 2,$1),$(word 2,$(gmsl_version))), \
+ $(false), \
+ $(if $(call lt,$(word 2,$1),$(word 2,$(gmsl_version))), \
+ $(true), \
+ $(call lte,$(word 3,$1),$(word 3,$(gmsl_version))))))))
+
+# ###########################################################################
+# LOGICAL OPERATORS
+# ###########################################################################
+
+# not is defined in gmsl
+
+# ----------------------------------------------------------------------------
+# Function: and
+# Arguments: Two boolean values
+# Returns: Returns $(true) if both of the booleans are true
+# ----------------------------------------------------------------------------
+ifneq ($(__gmsl_have_and),$(true))
+and = $(__gmsl_tr2)$(if $1,$(if $2,$(true),$(false)),$(false))
+endif
+
+# ----------------------------------------------------------------------------
+# Function: or
+# Arguments: Two boolean values
+# Returns: Returns $(true) if either of the booleans is true
+# ----------------------------------------------------------------------------
+ifneq ($(__gmsl_have_or),$(true))
+or = $(__gmsl_tr2)$(if $1$2,$(true),$(false))
+endif
+
+# ----------------------------------------------------------------------------
+# Function: xor
+# Arguments: Two boolean values
+# Returns: Returns $(true) if exactly one of the booleans is true
+# ----------------------------------------------------------------------------
+xor = $(__gmsl_tr2)$(if $1,$(if $2,$(false),$(true)),$(if $2,$(true),$(false)))
+
+# ----------------------------------------------------------------------------
+# Function: nand
+# Arguments: Two boolean values
+# Returns: Returns value of 'not and'
+# ----------------------------------------------------------------------------
+nand = $(__gmsl_tr2)$(if $1,$(if $2,$(false),$(true)),$(true))
+
+# ----------------------------------------------------------------------------
+# Function: nor
+# Arguments: Two boolean values
+# Returns: Returns value of 'not or'
+# ----------------------------------------------------------------------------
+nor = $(__gmsl_tr2)$(if $1$2,$(false),$(true))
+
+# ----------------------------------------------------------------------------
+# Function: xnor
+# Arguments: Two boolean values
+# Returns: Returns value of 'not xor'
+# ----------------------------------------------------------------------------
+xnor =$(__gmsl_tr2)$(if $1,$(if $2,$(true),$(false)),$(if $2,$(false),$(true)))
+
+# ###########################################################################
+# LIST MANIPULATION FUNCTIONS
+# ###########################################################################
+
+# ----------------------------------------------------------------------------
+# Function: first (same as LISP's car, or head)
+# Arguments: 1: A list
+# Returns: Returns the first element of a list
+# ----------------------------------------------------------------------------
+first = $(__gmsl_tr1)$(firstword $1)
+
+# ----------------------------------------------------------------------------
+# Function: last
+# Arguments: 1: A list
+# Returns: Returns the last element of a list
+# ----------------------------------------------------------------------------
+ifeq ($(__gmsl_have_lastword),$(true))
+last = $(__gmsl_tr1)$(lastword $1)
+else
+last = $(__gmsl_tr1)$(if $1,$(word $(words $1),$1))
+endif
+
+# ----------------------------------------------------------------------------
+# Function: rest (same as LISP's cdr, or tail)
+# Arguments: 1: A list
+# Returns: Returns the list with the first element removed
+# ----------------------------------------------------------------------------
+rest = $(__gmsl_tr1)$(wordlist 2,$(words $1),$1)
+
+# ----------------------------------------------------------------------------
+# Function: chop
+# Arguments: 1: A list
+# Returns: Returns the list with the last element removed
+# ----------------------------------------------------------------------------
+chop = $(__gmsl_tr1)$(wordlist 2,$(words $1),x $1)
+
+# ----------------------------------------------------------------------------
+# Function: map
+# Arguments: 1: Name of function to $(call) for each element of list
+# 2: List to iterate over calling the function in 1
+# Returns: The list after calling the function on each element
+# ----------------------------------------------------------------------------
+map = $(__gmsl_tr2)$(strip $(foreach a,$2,$(call $1,$a)))
+
+# ----------------------------------------------------------------------------
+# Function: pairmap
+# Arguments: 1: Name of function to $(call) for each pair of elements
+# 2: List to iterate over calling the function in 1
+# 3: Second list to iterate over calling the function in 1
+# Returns: The list after calling the function on each pair of elements
+# ----------------------------------------------------------------------------
+pairmap = $(strip $(__gmsl_tr3)\
+ $(if $2$3,$(call $1,$(call first,$2),$(call first,$3)) \
+ $(call pairmap,$1,$(call rest,$2),$(call rest,$3))))
+
+# ----------------------------------------------------------------------------
+# Function: leq
+# Arguments: 1: A list to compare against...
+# 2: ...this list
+# Returns: Returns $(true) if the two lists are identical
+# ----------------------------------------------------------------------------
+leq = $(__gmsl_tr2)$(strip $(if $(call seq,$(words $1),$(words $2)), \
+ $(call __gmsl_list_equal,$1,$2),$(false)))
+
+__gmsl_list_equal = $(if $(strip $1), \
+ $(if $(call seq,$(call first,$1),$(call first,$2)), \
+ $(call __gmsl_list_equal, \
+ $(call rest,$1), \
+ $(call rest,$2)), \
+ $(false)), \
+ $(true))
+
+# ----------------------------------------------------------------------------
+# Function: lne
+# Arguments: 1: A list to compare against...
+# 2: ...this list
+# Returns: Returns $(true) if the two lists are different
+# ----------------------------------------------------------------------------
+lne = $(__gmsl_tr2)$(call not,$(call leq,$1,$2))
+
+# ----------------------------------------------------------------------------
+# Function: reverse
+# Arguments: 1: A list to reverse
+# Returns: The list with its elements in reverse order
+# ----------------------------------------------------------------------------
+reverse =$(__gmsl_tr1)$(strip $(if $1,$(call reverse,$(call rest,$1)) \
+ $(call first,$1)))
+
+# ----------------------------------------------------------------------------
+# Function: uniq
+# Arguments: 1: A list from which to remove repeated elements
+# Returns: The list with duplicate elements removed without reordering
+# ----------------------------------------------------------------------------
+uniq = $(strip $(__gmsl_tr1)$(if $1,$(call uniq,$(call chop,$1)) \
+ $(if $(filter $(call last,$1),$(call chop,$1)),,$(call last,$1))))
+
+# ----------------------------------------------------------------------------
+# Function: length
+# Arguments: 1: A list
+# Returns: The number of elements in the list
+# ----------------------------------------------------------------------------
+length = $(__gmsl_tr1)$(words $1)
+
+# ###########################################################################
+# STRING MANIPULATION FUNCTIONS
+# ###########################################################################
+
+# Helper function that translates any GNU Make 'true' value (i.e. a
+# non-empty string) to our $(true)
+
+__gmsl_make_bool = $(if $(strip $1),$(true),$(false))
+
+# ----------------------------------------------------------------------------
+# Function: seq
+# Arguments: 1: A string to compare against...
+# 2: ...this string
+# Returns: Returns $(true) if the two strings are identical
+# ----------------------------------------------------------------------------
+seq = $(__gmsl_tr2)$(if $(filter-out xx,x$(subst $1,,$2)$(subst $2,,$1)x),$(false),$(true))
+
+# ----------------------------------------------------------------------------
+# Function: sne
+# Arguments: 1: A string to compare against...
+# 2: ...this string
+# Returns: Returns $(true) if the two strings are not the same
+# ----------------------------------------------------------------------------
+sne = $(__gmsl_tr2)$(call not,$(call seq,$1,$2))
+
+# ----------------------------------------------------------------------------
+# Function: split
+# Arguments: 1: The character to split on
+# 2: A string to split
+# Returns: Splits a string into a list separated by spaces at the split
+# character in the first argument
+# ----------------------------------------------------------------------------
+split = $(__gmsl_tr2)$(strip $(subst $1, ,$2))
+
+# ----------------------------------------------------------------------------
+# Function: merge
+# Arguments: 1: The character to put between fields
+# 2: A list to merge into a string
+# Returns: Merges a list into a single string, list elements are separated
+# by the character in the first argument
+# ----------------------------------------------------------------------------
+merge = $(__gmsl_tr2)$(strip $(if $2, \
+ $(if $(call seq,1,$(words $2)), \
+ $2,$(call first,$2)$1$(call merge,$1,$(call rest,$2)))))
+
+ifdef __gmsl_have_eval
+# ----------------------------------------------------------------------------
+# Function: tr
+# Arguments: 1: The list of characters to translate from
+# 2: The list of characters to translate to
+# 3: The text to translate
+# Returns: Returns the text after translating characters
+# ----------------------------------------------------------------------------
+tr = $(strip $(__gmsl_tr3)$(call assert_no_dollar,$0,$1$2$3) \
+ $(eval __gmsl_t := $3) \
+ $(foreach c, \
+ $(join $(addsuffix :,$1),$2), \
+ $(eval __gmsl_t := \
+ $(subst $(word 1,$(subst :, ,$c)),$(word 2,$(subst :, ,$c)), \
+ $(__gmsl_t))))$(__gmsl_t))
+
+# Common character classes for use with the tr function. Each of
+# these is actually a variable declaration and must be wrapped with
+# $() or ${} to be used.
+
+[A-Z] := A B C D E F G H I J K L M N O P Q R S T U V W X Y Z #
+[a-z] := a b c d e f g h i j k l m n o p q r s t u v w x y z #
+[0-9] := 0 1 2 3 4 5 6 7 8 9 #
+[A-F] := A B C D E F #
+
+# ----------------------------------------------------------------------------
+# Function: uc
+# Arguments: 1: Text to upper case
+# Returns: Returns the text in upper case
+# ----------------------------------------------------------------------------
+uc = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(call tr,$([a-z]),$([A-Z]),$1)
+
+# ----------------------------------------------------------------------------
+# Function: lc
+# Arguments: 1: Text to lower case
+# Returns: Returns the text in lower case
+# ----------------------------------------------------------------------------
+lc = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(call tr,$([A-Z]),$([a-z]),$1)
+
+# ----------------------------------------------------------------------------
+# Function: strlen
+# Arguments: 1: A string
+# Returns: Returns the length of the string
+# ----------------------------------------------------------------------------
+__gmsl_characters := A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
+__gmsl_characters += a b c d e f g h i j k l m n o p q r s t u v w x y z
+__gmsl_characters += 0 1 2 3 4 5 6 7 8 9
+__gmsl_characters += ` ~ ! @ \# $$ % ^ & * ( ) - _ = +
+__gmsl_characters += { } [ ] \ : ; ' " < > , . / ? |
+
+# Aside: if you read the above you might think that the lower-case
+# letter x is missing, and that that's an error. It is missing, but
+# it's not an error. __gmsl_characters is used by the strlen
+# function. strlen works by transforming every character and space
+# into the letter x and then counting the x's. Since there's no need
+# to transform x into x I omitted it.
+
+# This results in __gmsl_space containing just a space
+
+__gmsl_space :=
+__gmsl_space +=
+
+strlen = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(strip $(eval __temp := $(subst $(__gmsl_space),x,$1))$(foreach a,$(__gmsl_characters),$(eval __temp := $$(subst $$a,x,$(__temp))))$(eval __temp := $(subst x,x ,$(__temp)))$(words $(__temp)))
+
+# This results in __gmsl_newline containing just a newline
+
+define __gmsl_newline
+
+
+endef
+
+# This results in __gmsl_tab containing a tab
+
+__gmsl_tab := #
+
+# ----------------------------------------------------------------------------
+# Function: substr
+# Arguments: 1: A string
+# 2: Start position (first character is 1)
+# 3: End position (inclusive)
+# Returns: A substring.
+# Note: The string in $1 must not contain a §
+# ----------------------------------------------------------------------------
+
+substr = $(__gmsl_tr3)$(call assert_no_dollar,$0,$1$2$3)$(strip $(eval __temp := $$(subst $$(__gmsl_space),§ ,$$1))$(foreach a,$(__gmsl_characters),$(eval __temp := $$(subst $$a,$$a$$(__gmsl_space),$(__temp))))$(eval __temp := $(wordlist $2,$3,$(__temp))))$(subst §,$(__gmsl_space),$(subst $(__gmsl_space),,$(__temp)))
+
+endif # __gmsl_have_eval
+
+# ###########################################################################
+# SET MANIPULATION FUNCTIONS
+# ###########################################################################
+
+# Sets are represented by sorted, deduplicated lists. To create a set
+# from a list use set_create, or start with the empty_set and
+# set_insert individual elements
+
+# This is the empty set
+empty_set :=
+
+# ----------------------------------------------------------------------------
+# Function: set_create
+# Arguments: 1: A list of set elements
+# Returns: Returns the newly created set
+# ----------------------------------------------------------------------------
+set_create = $(__gmsl_tr1)$(sort $1)
+
+# ----------------------------------------------------------------------------
+# Function: set_insert
+# Arguments: 1: A single element to add to a set
+# 2: A set
+# Returns: Returns the set with the element added
+# ----------------------------------------------------------------------------
+set_insert = $(__gmsl_tr2)$(sort $1 $2)
+
+# ----------------------------------------------------------------------------
+# Function: set_remove
+# Arguments: 1: A single element to remove from a set
+# 2: A set
+# Returns: Returns the set with the element removed
+# ----------------------------------------------------------------------------
+set_remove = $(__gmsl_tr2)$(filter-out $1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: set_is_member
+# Arguments: 1: A single element
+# 2: A set
+# Returns: Returns $(true) if the element is in the set
+# ----------------------------------------------------------------------------
+set_is_member = $(__gmsl_tr2)$(if $(filter $1,$2),$(true),$(false))
+
+# ----------------------------------------------------------------------------
+# Function: set_union
+# Arguments: 1: A set
+# 2: Another set
+# Returns: Returns the union of the two sets
+# ----------------------------------------------------------------------------
+set_union = $(__gmsl_tr2)$(sort $1 $2)
+
+# ----------------------------------------------------------------------------
+# Function: set_intersection
+# Arguments: 1: A set
+# 2: Another set
+# Returns: Returns the intersection of the two sets
+# ----------------------------------------------------------------------------
+set_intersection = $(__gmsl_tr2)$(filter $1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: set_is_subset
+# Arguments: 1: A set
+# 2: Another set
+# Returns: Returns $(true) if the first set is a subset of the second
+# ----------------------------------------------------------------------------
+set_is_subset = $(__gmsl_tr2)$(call set_equal,$(call set_intersection,$1,$2),$1)
+
+# ----------------------------------------------------------------------------
+# Function: set_equal
+# Arguments: 1: A set
+# 2: Another set
+# Returns: Returns $(true) if the two sets are identical
+# ----------------------------------------------------------------------------
+set_equal = $(__gmsl_tr2)$(call seq,$1,$2)
+
+# ###########################################################################
+# ARITHMETIC LIBRARY
+# ###########################################################################
+
+# Integers a represented by lists with the equivalent number of x's.
+# For example the number 4 is x x x x. The maximum integer that the
+# library can handle as _input_ is __gmsl_input_int which is defined
+# here as 65536
+
+__gmsl_sixteen := x x x x x x x x x x x x x x x x
+__gmsl_input_int := $(foreach a,$(__gmsl_sixteen), \
+ $(foreach b,$(__gmsl_sixteen), \
+ $(foreach c,$(__gmsl_sixteen), \
+ $(__gmsl_sixteen)))))
+
+# ----------------------------------------------------------------------------
+# Function: int_decode
+# Arguments: 1: A number of x's representation
+# Returns: Returns the integer for human consumption that is represented
+# by the string of x's
+# ----------------------------------------------------------------------------
+int_decode = $(__gmsl_tr1)$(words $1)
+
+# ----------------------------------------------------------------------------
+# Function: int_encode
+# Arguments: 1: A number in human-readable integer form
+# Returns: Returns the integer encoded as a string of x's
+# ----------------------------------------------------------------------------
+int_encode = $(__gmsl_tr1)$(wordlist 1,$1,$(__gmsl_input_int))
+
+# The arithmetic library functions come in two forms: one form of each
+# function takes integers as arguments and the other form takes the
+# encoded form (x's created by a call to int_encode). For example,
+# there are two plus functions:
+#
+# plus Called with integer arguments and returns an integer
+# int_plus Called with encoded arguments and returns an encoded result
+#
+# plus will be slower than int_plus because its arguments and result
+# have to be translated between the x's format and integers. If doing
+# a complex calculation use the int_* forms with a single encoding of
+# inputs and single decoding of the output. For simple calculations
+# the direct forms can be used.
+
+# Helper function used to wrap an int_* function into a function that
+# takes a pair of integers, perhaps a function and returns an integer
+# result
+__gmsl_int_wrap = $(call int_decode,$(call $1,$(call int_encode,$2),$(call int_encode,$3)))
+__gmsl_int_wrap1 = $(call int_decode,$(call $1,$(call int_encode,$2)))
+__gmsl_int_wrap2 = $(call $1,$(call int_encode,$2),$(call int_encode,$3))
+
+# ----------------------------------------------------------------------------
+# Function: int_plus
+# Arguments: 1: A number in x's representation
+# 2: Another number in x's represntation
+# Returns: Returns the sum of the two numbers in x's representation
+# ----------------------------------------------------------------------------
+int_plus = $(strip $(__gmsl_tr2)$1 $2)
+
+# ----------------------------------------------------------------------------
+# Function: plus (wrapped version of int_plus)
+# Arguments: 1: An integer
+# 2: Another integer
+# Returns: Returns the sum of the two integers
+# ----------------------------------------------------------------------------
+plus = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_plus,$1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: int_subtract
+# Arguments: 1: A number in x's representation
+# 2: Another number in x's represntation
+# Returns: Returns the difference of the two numbers in x's representation,
+# or outputs an error on a numeric underflow
+# ----------------------------------------------------------------------------
+int_subtract = $(strip $(__gmsl_tr2)$(if $(call int_gte,$1,$2), \
+ $(filter-out xx,$(join $1,$2)), \
+ $(call __gmsl_warning,Subtraction underflow)))
+
+# ----------------------------------------------------------------------------
+# Function: subtract (wrapped version of int_subtract)
+# Arguments: 1: An integer
+# 2: Another integer
+# Returns: Returns the difference of the two integers,
+# or outputs an error on a numeric underflow
+# ----------------------------------------------------------------------------
+subtract = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_subtract,$1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: int_multiply
+# Arguments: 1: A number in x's representation
+# 2: Another number in x's represntation
+# Returns: Returns the product of the two numbers in x's representation
+# ----------------------------------------------------------------------------
+int_multiply = $(strip $(__gmsl_tr2)$(foreach a,$1,$2))
+
+# ----------------------------------------------------------------------------
+# Function: multiply (wrapped version of int_multiply)
+# Arguments: 1: An integer
+# 2: Another integer
+# Returns: Returns the product of the two integers
+# ----------------------------------------------------------------------------
+multiply = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_multiply,$1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: int_divide
+# Arguments: 1: A number in x's representation
+# 2: Another number in x's represntation
+# Returns: Returns the result of integer division of argument 1 divided
+# by argument 2 in x's representation
+# ----------------------------------------------------------------------------
+int_divide = $(__gmsl_tr2)$(strip $(if $2, \
+ $(if $(call int_gte,$1,$2), \
+ x $(call int_divide,$(call int_subtract,$1,$2),$2),), \
+ $(call __gmsl_error,Division by zero)))
+
+# ----------------------------------------------------------------------------
+# Function: divide (wrapped version of int_divide)
+# Arguments: 1: An integer
+# 2: Another integer
+# Returns: Returns the integer division of the first argument by the second
+# ----------------------------------------------------------------------------
+divide = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_divide,$1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: int_max, int_min
+# Arguments: 1: A number in x's representation
+# 2: Another number in x's represntation
+# Returns: Returns the maximum or minimum of its arguments in x's
+# representation
+# ----------------------------------------------------------------------------
+int_max = $(__gmsl_tr2)$(subst xx,x,$(join $1,$2))
+int_min = $(__gmsl_tr2)$(subst xx,x,$(filter xx,$(join $1,$2)))
+
+# ----------------------------------------------------------------------------
+# Function: max, min
+# Arguments: 1: An integer
+# 2: Another integer
+# Returns: Returns the maximum or minimum of its integer arguments
+# ----------------------------------------------------------------------------
+max = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_max,$1,$2)
+min = $(__gmsl_tr2)$(call __gmsl_int_wrap,int_min,$1,$2)
+
+# ----------------------------------------------------------------------------
+# Function: int_gt, int_gte, int_lt, int_lte, int_eq, int_ne
+# Arguments: Two x's representation numbers to be compared
+# Returns: $(true) or $(false)
+#
+# int_gt First argument greater than second argument
+# int_gte First argument greater than or equal to second argument
+# int_lt First argument less than second argument
+# int_lte First argument less than or equal to second argument
+# int_eq First argument is numerically equal to the second argument
+# int_ne First argument is not numerically equal to the second argument
+# ----------------------------------------------------------------------------
+int_gt = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(filter-out $(words $2), \
+ $(words $(call int_max,$1,$2))))
+int_gte = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(call int_gt,$1,$2)$(call int_eq,$1,$2))
+int_lt = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(filter-out $(words $1), \
+ $(words $(call int_max,$1,$2))))
+int_lte = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(call int_lt,$1,$2)$(call int_eq,$1,$2))
+int_eq = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(filter $(words $1),$(words $2)))
+int_ne = $(__gmsl_tr2)$(call __gmsl_make_bool, \
+ $(filter-out $(words $1),$(words $2)))
+
+# ----------------------------------------------------------------------------
+# Function: gt, gte, lt, lte, eq, ne
+# Arguments: Two integers to be compared
+# Returns: $(true) or $(false)
+#
+# gt First argument greater than second argument
+# gte First argument greater than or equal to second argument
+# lt First argument less than second argument
+# lte First argument less than or equal to second argument
+# eq First argument is numerically equal to the second argument
+# ne First argument is not numerically equal to the second argument
+# ----------------------------------------------------------------------------
+gt = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_gt,$1,$2)
+gte = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_gte,$1,$2)
+lt = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_lt,$1,$2)
+lte = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_lte,$1,$2)
+eq = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_eq,$1,$2)
+ne = $(__gmsl_tr2)$(call __gmsl_int_wrap2,int_ne,$1,$2)
+
+# increment adds 1 to its argument, decrement subtracts 1. Note that
+# decrement does not range check and hence will not underflow, but
+# will incorrectly say that 0 - 1 = 0
+
+# ----------------------------------------------------------------------------
+# Function: int_inc
+# Arguments: 1: A number in x's representation
+# Returns: The number incremented by 1 in x's representation
+# ----------------------------------------------------------------------------
+int_inc = $(strip $(__gmsl_tr1)$1 x)
+
+# ----------------------------------------------------------------------------
+# Function: inc
+# Arguments: 1: An integer
+# Returns: The argument incremented by 1
+# ----------------------------------------------------------------------------
+inc = $(__gmsl_tr1)$(call __gmsl_int_wrap1,int_inc,$1)
+
+# ----------------------------------------------------------------------------
+# Function: int_dec
+# Arguments: 1: A number in x's representation
+# Returns: The number decremented by 1 in x's representation
+# ----------------------------------------------------------------------------
+int_dec = $(__gmsl_tr1)$(strip $(if $(call sne,0,$(words $1)), \
+ $(wordlist 2,$(words $1),$1), \
+ $(call __gmsl_warning,Decrement underflow)))
+
+# ----------------------------------------------------------------------------
+# Function: dec
+# Arguments: 1: An integer
+# Returns: The argument decremented by 1
+# ----------------------------------------------------------------------------
+dec = $(__gmsl_tr1)$(call __gmsl_int_wrap1,int_dec,$1)
+
+# double doubles its argument, and halve halves it
+
+# ----------------------------------------------------------------------------
+# Function: int_double
+# Arguments: 1: A number in x's representation
+# Returns: The number doubled (i.e. * 2) and returned in x's representation
+# ----------------------------------------------------------------------------
+int_double = $(strip $(__gmsl_tr1)$1 $1)
+
+# ----------------------------------------------------------------------------
+# Function: double
+# Arguments: 1: An integer
+# Returns: The integer times 2
+# ----------------------------------------------------------------------------
+double = $(__gmsl_tr1)$(call __gmsl_int_wrap1,int_double,$1)
+
+# ----------------------------------------------------------------------------
+# Function: int_halve
+# Arguments: 1: A number in x's representation
+# Returns: The number halved (i.e. / 2) and returned in x's representation
+# ----------------------------------------------------------------------------
+int_halve = $(__gmsl_tr1)$(strip $(subst xx,x,$(filter-out xy x y, \
+ $(join $1,$(foreach a,$1,y x)))))
+
+# ----------------------------------------------------------------------------
+# Function: halve
+# Arguments: 1: An integer
+# Returns: The integer divided by 2
+# ----------------------------------------------------------------------------
+halve = $(__gmsl_tr1)$(call __gmsl_int_wrap1,int_halve,$1)
+
+ifdef __gmsl_have_eval
+# ###########################################################################
+# ASSOCIATIVE ARRAYS
+# ###########################################################################
+
+# ----------------------------------------------------------------------------
+# Function: set
+# Arguments: 1: Name of associative array
+# 2: The key value to associate
+# 3: The value associated with the key
+# Returns: None
+# ----------------------------------------------------------------------------
+set = $(__gmsl_tr3)$(call assert_no_dollar,$0,$1$2$3)$(eval __gmsl_aa_$1_$2 = $3)
+
+# ----------------------------------------------------------------------------
+# Function: get
+# Arguments: 1: Name of associative array
+# 2: The key to retrieve
+# Returns: The value stored in the array for that key
+# ----------------------------------------------------------------------------
+get = $(strip $(__gmsl_tr2)$(call assert_no_dollar,$0,$1$2)$(if $(filter-out undefined,$(origin __gmsl_aa_$1_$2)), \
+ $(__gmsl_aa_$1_$2)))
+
+# ----------------------------------------------------------------------------
+# Function: keys
+# Arguments: 1: Name of associative array
+# Returns: Returns a list of all defined keys in the array
+# ----------------------------------------------------------------------------
+keys = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(sort $(patsubst __gmsl_aa_$1_%,%, \
+ $(filter __gmsl_aa_$1_%,$(.VARIABLES))))
+
+# ----------------------------------------------------------------------------
+# Function: defined
+# Arguments: 1: Name of associative array
+# 2: The key to test
+# Returns: Returns true if the key is defined (i.e. not empty)
+# ----------------------------------------------------------------------------
+defined = $(__gmsl_tr2)$(call assert_no_dollar,$0,$1$2)$(call sne,$(call get,$1,$2),)
+
+endif # __gmsl_have_eval
+
+ifdef __gmsl_have_eval
+# ###########################################################################
+# NAMED STACKS
+# ###########################################################################
+
+# ----------------------------------------------------------------------------
+# Function: push
+# Arguments: 1: Name of stack
+# 2: Value to push onto the top of the stack (must not contain
+# a space)
+# Returns: None
+# ----------------------------------------------------------------------------
+push = $(__gmsl_tr2)$(call assert_no_dollar,$0,$1$2)$(eval __gmsl_stack_$1 := $2 $(if $(filter-out undefined,\
+ $(origin __gmsl_stack_$1)),$(__gmsl_stack_$1)))
+
+# ----------------------------------------------------------------------------
+# Function: pop
+# Arguments: 1: Name of stack
+# Returns: Top element from the stack after removing it
+# ----------------------------------------------------------------------------
+pop = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(strip $(if $(filter-out undefined,$(origin __gmsl_stack_$1)), \
+ $(call first,$(__gmsl_stack_$1)) \
+ $(eval __gmsl_stack_$1 := $(call rest,$(__gmsl_stack_$1)))))
+
+# ----------------------------------------------------------------------------
+# Function: peek
+# Arguments: 1: Name of stack
+# Returns: Top element from the stack without removing it
+# ----------------------------------------------------------------------------
+peek = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(call first,$(__gmsl_stack_$1))
+
+# ----------------------------------------------------------------------------
+# Function: depth
+# Arguments: 1: Name of stack
+# Returns: Number of items on the stack
+# ----------------------------------------------------------------------------
+depth = $(__gmsl_tr1)$(call assert_no_dollar,$0,$1)$(words $(__gmsl_stack_$1))
+
+endif # __gmsl_have_eval
+
+# ###########################################################################
+# DEBUGGING FACILITIES
+# ###########################################################################
+
+# ----------------------------------------------------------------------------
+# Target: gmsl-print-%
+# Arguments: The % should be replaced by the name of a variable that you
+# wish to print out.
+# Action: Echos the name of the variable that matches the % and its value.
+# For example, 'make gmsl-print-SHELL' will output the value of
+# the SHELL variable
+# ----------------------------------------------------------------------------
+gmsl-print-%: ; @echo $* = $($*)
+
+# ----------------------------------------------------------------------------
+# Function: assert
+# Arguments: 1: A boolean that must be true or the assertion will fail
+# 2: The message to print with the assertion
+# Returns: None
+# ----------------------------------------------------------------------------
+assert = $(if $1,,$(call __gmsl_error,Assertion failure: $2))
+
+# ----------------------------------------------------------------------------
+# Function: assert_exists
+# Arguments: 1: Name of file that must exist, if it is missing an assertion
+# will be generated
+# Returns: None
+# ----------------------------------------------------------------------------
+assert_exists = $(call assert,$(wildcard $1),file '$1' missing)
+
+# ----------------------------------------------------------------------------
+# Function: assert_no_dollar
+# Arguments: 1: Name of a function being executd
+# 2: Arguments to check
+# Returns: None
+# ----------------------------------------------------------------------------
+assert_no_dollar = $(call assert,$(call not,$(findstring $$,$2)),$1 called with a dollar sign in argument)
diff --git a/ndk/build/gmsl/gmsl b/ndk/build/gmsl/gmsl
new file mode 100644
index 000000000..2ff28972d
--- /dev/null
+++ b/ndk/build/gmsl/gmsl
@@ -0,0 +1,89 @@
+# ----------------------------------------------------------------------------
+#
+# GNU Make Standard Library (GMSL)
+#
+# A library of functions to be used with GNU Make's $(call) that
+# provides functionality not available in standard GNU Make.
+#
+# Copyright (c) 2005-2008 John Graham-Cumming
+#
+# This file is part of GMSL
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# Neither the name of the John Graham-Cumming nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+# POSSIBILITY OF SUCH DAMAGE.
+#
+# ----------------------------------------------------------------------------
+
+# Determine if the library has already been included and if so don't
+# bother including it again
+
+ifndef __gmsl_included
+
+# Standard definitions for true and false. true is any non-empty
+# string, false is an empty string. These are intended for use with
+# $(if).
+
+true := T
+false :=
+
+# ----------------------------------------------------------------------------
+# Function: not
+# Arguments: 1: A boolean value
+# Returns: Returns the opposite of the arg. (true -> false, false -> true)
+# ----------------------------------------------------------------------------
+not = $(if $1,$(false),$(true))
+
+# Prevent reinclusion of the library
+
+__gmsl_included := $(true)
+
+# Try to determine where this file is located. If the caller did
+# include /foo/gmsl then extract the /foo/ so that __gmsl gets
+# included transparently
+
+ifneq ($(MAKEFILE_LIST),)
+__gmsl_root := $(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
+
+# If there are any spaces in the path in __gmsl_root then give up
+
+ifeq (1,$(words $(__gmsl_root)))
+__gmsl_root := $(patsubst %gmsl,%,$(__gmsl_root))
+else
+__gmsl_root :=
+endif
+
+include $(__gmsl_root)__gmsl
+
+else
+
+include __gmsl
+
+endif
+
+endif # __gmsl_included
+
diff --git a/ndk/build/gmsl/gmsl-tests b/ndk/build/gmsl/gmsl-tests
new file mode 100644
index 000000000..b205be622
--- /dev/null
+++ b/ndk/build/gmsl/gmsl-tests
@@ -0,0 +1,647 @@
+# ----------------------------------------------------------------------------
+#
+# GNU Make Standard Library (GMSL) Test Suite
+#
+# Test suite for the GMSL
+#
+# Copyright (c) 2005-2007 John Graham-Cumming
+#
+# This file is part of GMSL
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+# Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# Neither the name of the John Graham-Cumming nor the names of its
+# contributors may be used to endorse or promote products derived from
+# this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+# POSSIBILITY OF SUCH DAMAGE.
+#
+# ----------------------------------------------------------------------------
+
+.PHONY: all
+all:
+ @echo
+ @echo Test Summary
+ @echo ------------
+ @echo "$(call int_decode,$(passed)) tests passed; $(call int_decode,$(failed)) tests failed"
+
+include gmsl
+
+passed :=
+failed :=
+
+ECHO := /bin/echo
+
+start_test = $(shell $(ECHO) -n "Testing '$1': " >&2)$(eval current_test := OK)
+stop_test = $(shell $(ECHO) " $(current_test)" >&2)
+test_pass = .$(eval passed := $(call int_inc,$(passed)))
+test_fail = X$(eval failed := $(call int_inc,$(failed)))$(eval current_test := ERROR '$1' != '$2')
+test_assert = $(if $(filter undefined,$(origin 2)),$(eval 2 :=))$(shell $(ECHO) -n $(if $(call seq,$1,$2),$(call test_pass,$1,$2),$(call test_fail,$1,$2)) >&2)
+
+$(call start_test,not)
+$(call test_assert,$(call not,$(true)),$(false))
+$(call test_assert,$(call not,$(false)),$(true))
+$(call stop_test)
+
+$(call start_test,or)
+$(call test_assert,$(call or,$(true),$(true)),$(true))
+$(call test_assert,$(call or,$(true),$(false)),$(true))
+$(call test_assert,$(call or,$(false),$(true)),$(true))
+$(call test_assert,$(call or,$(false),$(false)),$(false))
+$(call stop_test)
+
+$(call start_test,and)
+$(call test_assert,$(call and,$(true),$(true)),$(true))
+$(call test_assert,$(call and,$(true),$(false)),$(false))
+$(call test_assert,$(call and,$(false),$(true)),$(false))
+$(call test_assert,$(call and,$(false),$(false)),$(false))
+$(call stop_test)
+
+$(call start_test,xor)
+$(call test_assert,$(call xor,$(true),$(true)),$(false))
+$(call test_assert,$(call xor,$(true),$(false)),$(true))
+$(call test_assert,$(call xor,$(false),$(true)),$(true))
+$(call test_assert,$(call xor,$(false),$(false)),$(false))
+$(call stop_test)
+
+$(call start_test,nand)
+$(call test_assert,$(call nand,$(true),$(true)),$(false))
+$(call test_assert,$(call nand,$(true),$(false)),$(true))
+$(call test_assert,$(call nand,$(false),$(true)),$(true))
+$(call test_assert,$(call nand,$(false),$(false)),$(true))
+$(call stop_test)
+
+$(call start_test,nor)
+$(call test_assert,$(call nor,$(true),$(true)),$(false))
+$(call test_assert,$(call nor,$(true),$(false)),$(false))
+$(call test_assert,$(call nor,$(false),$(true)),$(false))
+$(call test_assert,$(call nor,$(false),$(false)),$(true))
+$(call stop_test)
+
+$(call start_test,xnor)
+$(call test_assert,$(call xnor,$(true),$(true)),$(true))
+$(call test_assert,$(call xnor,$(true),$(false)),$(false))
+$(call test_assert,$(call xnor,$(false),$(true)),$(false))
+$(call test_assert,$(call xnor,$(false),$(false)),$(true))
+$(call stop_test)
+
+$(call start_test,first)
+$(call test_assert,$(call first,1 2 3),1)
+$(call test_assert,$(call first,1),1)
+$(call test_assert,$(call first,),)
+$(call stop_test)
+
+$(call start_test,last)
+$(call test_assert,$(call last,1 2 3),3)
+$(call test_assert,$(call last,1),1)
+$(call test_assert,$(call last,),)
+$(call stop_test)
+
+$(call start_test,rest)
+$(call test_assert,$(call rest,1 2 3),2 3)
+$(call test_assert,$(call rest,1),)
+$(call test_assert,$(call rest,),)
+$(call stop_test)
+
+$(call start_test,chop)
+$(call test_assert,$(call chop,1 2 3),1 2)
+$(call test_assert,$(call chop,1 2 3 4),1 2 3)
+$(call test_assert,$(call chop,1),)
+$(call test_assert,$(call chop,),)
+$(call stop_test)
+
+$(call start_test,length)
+$(call test_assert,$(call length,1 2 3),3)
+$(call test_assert,$(call length,1 2 3 4),4)
+$(call test_assert,$(call length,1),1)
+$(call test_assert,$(call length,),0)
+$(call stop_test)
+
+$(call start_test,map)
+$(call test_assert,$(call map,origin,__undefined map MAKE),undefined file default)
+$(call test_assert,$(call map,origin,),)
+$(call stop_test)
+
+joinem = $1$2
+$(call start_test,pairmap)
+$(call test_assert,$(call pairmap,addsuffix,2 1 3,a b c),a2 b1 c3)
+$(call test_assert,$(call pairmap,addprefix,2 1 3,a b c d),2a 1b 3c d)
+$(call test_assert,$(call pairmap,addprefix,2 1 3 4,a b c),2a 1b 3c)
+$(call test_assert,$(call pairmap,joinem,2 1 3 4,a b c),2a 1b 3c 4)
+$(call stop_test)
+
+$(call start_test,seq)
+$(call test_assert,$(call seq,abc,abc),T)
+$(call test_assert,$(call seq,x,),)
+$(call test_assert,$(call seq,,x),)
+$(call test_assert,$(call seq,x,x),T)
+$(call test_assert,$(call seq,a%c,abc),)
+$(call test_assert,$(call seq,abc,a%c),)
+$(call test_assert,$(call seq,abc,ABC),)
+$(call test_assert,$(call seq,abc,),)
+$(call test_assert,$(call seq,,),T)
+$(call test_assert,$(call seq,a b c,a b c),T)
+$(call test_assert,$(call seq,aa% bb% cc,aa% bb% cc),T)
+$(call test_assert,$(call seq,aa% bb% cc,aa% bb cc),)
+$(call test_assert,$(call seq,aa% bb% cc,xx yy zz),)
+$(call stop_test)
+
+$(call start_test,sne)
+$(call test_assert,$(call sne,abc,abc),)
+$(call test_assert,$(call sne,x,),T)
+$(call test_assert,$(call sne,,x),T)
+$(call test_assert,$(call sne,x,x),)
+$(call test_assert,$(call sne,abc,ABC),T)
+$(call test_assert,$(call sne,abc,),T)
+$(call test_assert,$(call sne,,),)
+$(call test_assert,$(call sne,a b c,a b c),)
+$(call test_assert,$(call sne,aa% bb% cc,aa% bb% cc),)
+$(call test_assert,$(call sne,aa% bb% cc,aa% bb cc),T)
+$(call stop_test)
+
+$(call start_test,strlen)
+$(call test_assert,$(call strlen,),0)
+$(call test_assert,$(call strlen,a),1)
+$(call test_assert,$(call strlen,a b),3)
+$(call test_assert,$(call strlen,a ),2)
+$(call test_assert,$(call strlen, a),2)
+$(call test_assert,$(call strlen, ),2)
+$(call test_assert,$(call strlen, ),3)
+$(call test_assert,$(call strlen, ),4)
+$(call stop_test)
+
+$(call start_test,substr)
+$(call test_assert,$(call substr,xyz,1,1),x)
+$(call test_assert,$(call substr,xyz,1,2),xy)
+$(call test_assert,$(call substr,xyz,2,3),yz)
+$(call test_assert,$(call substr,some string,1,1),s)
+$(call test_assert,$(call substr,some string,1,2),so)
+$(call test_assert,$(call substr,some string,1,3),som)
+$(call test_assert,$(call substr,some string,1,4),some)
+$(call test_assert,$(call substr,some string,1,5),some )
+$(call test_assert,$(call substr,some string,1,6),some s)
+$(call test_assert,$(call substr,some string,5,5), )
+$(call test_assert,$(call substr,some string,5,6), s)
+$(call test_assert,$(call substr,some string,5,7), st)
+$(call test_assert,$(call substr,some string,5,8), str)
+$(call test_assert,$(call substr,some string,1,100),some string)
+$(call stop_test)
+
+$(call start_test,lc)
+$(call test_assert,$(call lc,The Quick Brown Fox),the quick brown fox)
+$(call test_assert,$(call lc,the1 quick2 brown3 fox4),the1 quick2 brown3 fox4)
+$(call test_assert,$(call lc,The_),the_)
+$(call test_assert,$(call lc,),)
+$(call stop_test)
+
+$(call start_test,uc)
+$(call test_assert,$(call uc,The Quick Brown Fox),THE QUICK BROWN FOX)
+$(call test_assert,$(call uc,the1 quick2 brown3 fox4),THE1 QUICK2 BROWN3 FOX4)
+$(call test_assert,$(call uc,The_),THE_)
+$(call test_assert,$(call uc,),)
+$(call stop_test)
+
+$(call start_test,tr)
+$(call test_assert,$(call tr,A B C,1 2 3,CAPITAL),31PIT1L)
+$(call test_assert,$(call tr,a b c,1 2 3,CAPITAL),CAPITAL)
+$(call test_assert,$(call tr,E L I,3 1 1,I AM ELITE),1 AM 311T3)
+$(call stop_test)
+
+$(call start_test,leq)
+$(call test_assert,$(call leq,1 2 3,1 2 3),T)
+$(call test_assert,$(call leq,1 2 3,1 2 3 4),)
+$(call test_assert,$(call leq,1 2 3 4,1 2 3),)
+$(call test_assert,$(call leq,1,1),T)
+$(call test_assert,$(call leq,,),T)
+$(call stop_test)
+
+$(call start_test,lne)
+$(call test_assert,$(call lne,1 2 3,1 2 3),)
+$(call test_assert,$(call lne,1 2 3,1 2 3 4),T)
+$(call test_assert,$(call lne,1 2 3 4,1 2 3),T)
+$(call test_assert,$(call lne,1,1),)
+$(call test_assert,$(call lne,,),)
+$(call stop_test)
+
+$(call start_test,empty_set)
+$(call test_assert,$(empty_set),)
+$(call test_assert,$(empty_set),$(call set_create,))
+$(call stop_test)
+
+$(call start_test,set_create)
+$(call test_assert,$(call set_create,),)
+$(call test_assert,$(call set_create,1 2 2 3),1 2 3)
+$(call test_assert,$(call set_create,2 1 1 2 2 3),1 2 3)
+$(call test_assert,$(call set_create,1),1)
+$(call stop_test)
+
+$(call start_test,set_insert)
+$(call test_assert,$(call set_insert,1,$(empty_set)),1)
+$(call test_assert,$(call set_insert,1,$(call set_create,1)),1)
+$(call test_assert,$(call set_insert,1,$(call set_create,1 2)),1 2)
+$(call test_assert,$(call set_insert,0,$(call set_create,1 2)),0 1 2)
+$(call stop_test)
+
+$(call start_test,set_remove)
+$(call test_assert,$(call set_remove,1,$(empty_set)),$(empty_set))
+$(call test_assert,$(call set_remove,1,$(call set_create,1 2)),2)
+$(call test_assert,$(call set_remove,1,$(call set_create,1 11 2)),11 2)
+$(call test_assert,$(call set_remove,0,$(call set_create,1 2)),1 2)
+$(call stop_test)
+
+$(call start_test,set_is_member)
+$(call test_assert,$(call set_is_member,1,$(empty_set)),)
+$(call test_assert,$(call set_is_member,1,$(call set_create,2 3)),)
+$(call test_assert,$(call set_is_member,1,$(call set_create,1 2 3)),T)
+$(call test_assert,$(call set_is_member,1,$(call set_create,1)),T)
+$(call stop_test)
+
+$(call start_test,set_union)
+$(call test_assert,$(call set_union,,),)
+$(call test_assert,$(call set_union,1 2,),1 2)
+$(call test_assert,$(call set_union,,3 4),3 4)
+$(call test_assert,$(call set_union,1 2,3 4),1 2 3 4)
+$(call test_assert,$(call set_union,1 2 3,3 4 5),1 2 3 4 5)
+$(call stop_test)
+
+$(call start_test,set_intersection)
+$(call test_assert,$(call set_intersection,,),)
+$(call test_assert,$(call set_intersection,1 2,),)
+$(call test_assert,$(call set_intersection,,3 4),)
+$(call test_assert,$(call set_intersection,1 2,3 4),)
+$(call test_assert,$(call set_intersection,1 2 3 4,3 4 5),3 4)
+$(call stop_test)
+
+$(call start_test,set_is_subset)
+$(call test_assert,$(call set_is_subset,,),T)
+$(call test_assert,$(call set_is_subset,1 2,),)
+$(call test_assert,$(call set_is_subset,,3 4),T)
+$(call test_assert,$(call set_is_subset,1 2,3 4),)
+$(call test_assert,$(call set_is_subset,1 2,1 2 3 4 5),T)
+$(call test_assert,$(call set_is_subset,1 2,1 2),T)
+$(call test_assert,$(call set_is_subset,1 2,1 3 4 5),)
+$(call stop_test)
+
+$(call start_test,set_equal)
+$(call test_assert,$(call set_equal,,),T)
+$(call test_assert,$(call set_equal,1,),)
+$(call test_assert,$(call set_equal,,1),)
+$(call test_assert,$(call set_equal,1,1),T)
+$(call test_assert,$(call set_equal,1 2,),)
+$(call test_assert,$(call set_equal,,1 2),)
+$(call test_assert,$(call set_equal,1 2,1 2 3),)
+$(call stop_test)
+
+$(call start_test,int_encode)
+$(call test_assert,$(call int_encode,0),)
+$(call test_assert,$(call int_encode,1),x)
+$(call test_assert,$(call int_encode,2),x x)
+$(call test_assert,$(call int_encode,10),x x x x x x x x x x)
+$(call stop_test)
+
+$(call start_test,int_decode)
+$(call test_assert,$(call int_decode,),0)
+$(call test_assert,$(call int_decode,x),1)
+$(call test_assert,$(call int_decode,x x),2)
+$(call test_assert,$(call int_decode,x x x x x x x x x x),10)
+$(call stop_test)
+
+$(call start_test,int_plus)
+$(call test_assert,$(call int_plus,$(call int_encode,3),$(call int_encode,4)),$(call int_encode,7))
+$(call test_assert,$(call int_plus,$(call int_encode,0),$(call int_encode,4)),$(call int_encode,4))
+$(call test_assert,$(call int_plus,$(call int_encode,3),$(call int_encode,0)),$(call int_encode,3))
+$(call test_assert,$(call int_plus,$(call int_encode,0),$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_plus,$(call int_encode,1),$(call int_encode,0)),$(call int_encode,1))
+$(call stop_test)
+
+$(call start_test,plus)
+$(call test_assert,$(call plus,3,4),7)
+$(call test_assert,$(call plus,4,3),7)
+$(call test_assert,$(call plus,0,4),4)
+$(call test_assert,$(call plus,3,0),3)
+$(call test_assert,$(call plus,0,0),0)
+$(call stop_test)
+
+__gmsl_warning = $1
+$(call start_test,int_subtract)
+$(call test_assert,$(call int_subtract,$(call int_encode,3),$(call int_encode,4)),Subtraction underflow)
+$(call test_assert,$(call int_subtract,$(call int_encode,4),$(call int_encode,3)),$(call int_encode,1))
+$(call test_assert,$(call int_subtract,$(call int_encode,3),$(call int_encode,0)),$(call int_encode,3))
+$(call test_assert,$(call int_subtract,$(call int_encode,0),$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_subtract,$(call int_encode,1),$(call int_encode,0)),$(call int_encode,1))
+$(call stop_test)
+
+__gmsl_warning = x x x x x x x x x x
+$(call start_test,subtract)
+$(call test_assert,$(call subtract,3,4),10)
+$(call test_assert,$(call subtract,4,3),1)
+$(call test_assert,$(call subtract,3,0),3)
+$(call test_assert,$(call subtract,0,0),0)
+$(call stop_test)
+
+$(call start_test,int_multiply)
+$(call test_assert,$(call int_multiply,$(call int_encode,3),$(call int_encode,4)),$(call int_encode,12))
+$(call test_assert,$(call int_multiply,$(call int_encode,4),$(call int_encode,3)),$(call int_encode,12))
+$(call test_assert,$(call int_multiply,$(call int_encode,3),$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_multiply,$(call int_encode,0),$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_multiply,$(call int_encode,1),$(call int_encode,0)),$(call int_encode,0))
+$(call stop_test)
+
+$(call start_test,multiply)
+$(call test_assert,$(call multiply,3,4),12)
+$(call test_assert,$(call multiply,4,3),12)
+$(call test_assert,$(call multiply,3,0),0)
+$(call test_assert,$(call multiply,0,3),0)
+$(call test_assert,$(call multiply,0,0),0)
+$(call stop_test)
+
+__gmsl_error = $1
+$(call start_test,int_divide)
+$(call test_assert,$(call int_divide,$(call int_encode,3),$(call int_encode,4)),$(call int_encode,0))
+$(call test_assert,$(call int_divide,$(call int_encode,4),$(call int_encode,3)),$(call int_encode,1))
+$(call test_assert,$(call int_divide,$(call int_encode,31),$(call int_encode,3)),$(call int_encode,10))
+$(call test_assert,$(call int_divide,$(call int_encode,30),$(call int_encode,3)),$(call int_encode,10))
+$(call test_assert,$(call int_divide,$(call int_encode,29),$(call int_encode,3)),$(call int_encode,9))
+$(call test_assert,$(call int_divide,$(call int_encode,0),$(call int_encode,1)),$(call int_encode,0))
+$(call test_assert,$(call int_divide,$(call int_encode,1),$(call int_encode,0)),Division by zero)
+$(call stop_test)
+
+__gmsl_error = x x x x x x x x x x
+$(call start_test,divide)
+$(call test_assert,$(call divide,3,4),0)
+$(call test_assert,$(call divide,4,3),1)
+$(call test_assert,$(call divide,21,2),10)
+$(call test_assert,$(call divide,20,2),10)
+$(call test_assert,$(call divide,19,2),9)
+$(call test_assert,$(call divide,1,0),10)
+$(call stop_test)
+
+$(call start_test,associative array)
+$(call test_assert,$(call get,myarray,key1),)
+$(call set,myarray,key1,value1)
+$(call test_assert,$(call get,myarray,key1),value1)
+$(call test_assert,$(call get,myarray,key2),)
+$(call test_assert,$(call get,myarray1,key1),)
+$(call test_assert,$(call defined,myarray,key1),T)
+$(call test_assert,$(call defined,myarray,key2),)
+$(call test_assert,$(call defined,myarray1,key1),)
+$(call set,myarray,key2,value2)
+$(call test_assert,$(call keys,myarray),key1 key2)
+$(call test_assert,$(call keys,myarray1),)
+$(call stop_test)
+
+$(call start_test,named stack)
+$(call test_assert,$(call pop,mystack),)
+$(call test_assert,$(call push,mystack,e2))
+$(call push,mystack,e1)
+$(call test_assert,$(call pop,mystack),e1)
+$(call test_assert,$(call pop,mystack),e2)
+$(call push,mystack,f3)
+$(call push,mystack,f1)
+$(call test_assert,$(call pop,mystack),f1)
+$(call push,mystack,f2)
+$(call test_assert,$(call peek,mystack),f2)
+$(call test_assert,$(call depth,mystack),2)
+$(call test_assert,$(call pop,mystack),f2)
+$(call test_assert,$(call depth,mystack),1)
+$(call test_assert,$(call pop,myotherstack),)
+$(call stop_test)
+
+$(call start_test,reverse)
+$(call test_assert,$(call reverse,),)
+$(call test_assert,$(call reverse,1),1)
+$(call test_assert,$(call reverse,1 2),2 1)
+$(call test_assert,$(call reverse,1 2 3),3 2 1)
+$(call stop_test)
+
+$(call start_test,uniq)
+$(call test_assert,$(call uniq,),)
+$(call test_assert,$(call uniq,a),a)
+$(call test_assert,$(call uniq,a a),a)
+$(call test_assert,$(call uniq,a aa),a aa)
+$(call test_assert,$(call uniq,a aa a),a aa)
+$(call test_assert,$(call uniq,a b ba ab b a a ba a),a b ba ab)
+$(call stop_test)
+
+c:=,
+$(call start_test,split)
+$(call test_assert,$(call split,$c,comma$cseparated$cstring),comma separated string)
+$(call test_assert,$(call split,*,star*field*record),star field record)
+$(call test_assert,$(call split,*,star*),star)
+$(call test_assert,$(call split,*,star*field),star field)
+$(call test_assert,$(call split,*,star****field),star field)
+$(call test_assert,$(call split,*,),)
+$(call stop_test)
+
+$(call start_test,merge)
+$(call test_assert,$(call merge,$c,list of things),list$cof$cthings)
+$(call test_assert,$(call merge,*,list of things),list*of*things)
+$(call test_assert,$(call merge,*,list),list)
+$(call test_assert,$(call merge,*,),)
+$(call stop_test)
+
+$(call start_test,int_max)
+$(call test_assert,$(call int_max,$(call int_encode,2),$(call int_encode,1)),$(call int_encode,2))
+$(call test_assert,$(call int_max,$(call int_encode,1),$(call int_encode,2)),$(call int_encode,2))
+$(call test_assert,$(call int_max,$(call int_encode,2),$(call int_encode,0)),$(call int_encode,2))
+$(call test_assert,$(call int_max,$(call int_encode,0),$(call int_encode,2)),$(call int_encode,2))
+$(call test_assert,$(call int_max,$(call int_encode,2),$(call int_encode,2)),$(call int_encode,2))
+$(call test_assert,$(call int_max,$(call int_encode,0),$(call int_encode,0)),$(call int_encode,0))
+$(call stop_test)
+
+$(call start_test,max)
+$(call test_assert,$(call max,2,1),2)
+$(call test_assert,$(call max,1,2),2)
+$(call test_assert,$(call max,2,0),2)
+$(call test_assert,$(call max,0,2),2)
+$(call test_assert,$(call max,2,2),2)
+$(call test_assert,$(call max,0,0),0)
+$(call stop_test)
+
+$(call start_test,int_min)
+$(call test_assert,$(call int_min,$(call int_encode,2),$(call int_encode,1)),$(call int_encode,1))
+$(call test_assert,$(call int_min,$(call int_encode,1),$(call int_encode,2)),$(call int_encode,1))
+$(call test_assert,$(call int_min,$(call int_encode,2),$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_min,$(call int_encode,0),$(call int_encode,2)),$(call int_encode,0))
+$(call test_assert,$(call int_min,$(call int_encode,2),$(call int_encode,2)),$(call int_encode,2))
+$(call test_assert,$(call int_min,$(call int_encode,0),$(call int_encode,0)),$(call int_encode,0))
+$(call stop_test)
+
+$(call start_test,min)
+$(call test_assert,$(call min,2,1),1)
+$(call test_assert,$(call min,1,2),1)
+$(call test_assert,$(call min,2,0),0)
+$(call test_assert,$(call min,0,2),0)
+$(call test_assert,$(call min,2,2),2)
+$(call test_assert,$(call min,0,0),0)
+$(call stop_test)
+
+__gmsl_error = $1
+$(call start_test,assert functions)
+$(call test_assert,$(call assert,$(true),ignore),)
+$(call test_assert,$(call assert,$(false),failed),Assertion failure: failed)
+$(call test_assert,$(call assert_exists,gmsl-tests),)
+$(call test_assert,$(call assert_exists,MISSING-gmsl-tests),Assertion failure: file 'MISSING-gmsl-tests' missing)
+$(call stop_test)
+
+$(call start_test,int_inc)
+$(call test_assert,$(call int_inc,$(call int_encode,0)),$(call int_encode,1))
+$(call test_assert,$(call int_inc,$(call int_encode,1)),$(call int_encode,2))
+$(call test_assert,$(call int_inc,$(call int_encode,4)),$(call int_encode,5))
+$(call test_assert,$(call int_inc,$(call int_encode,10)),$(call int_encode,11))
+$(call stop_test)
+
+$(call start_test,inc)
+$(call test_assert,$(call inc,0),1)
+$(call test_assert,$(call inc,1),2)
+$(call test_assert,$(call inc,4),5)
+$(call test_assert,$(call inc,10),11)
+$(call stop_test)
+
+__gmsl_warning = $1
+$(call start_test,int_dec)
+$(call test_assert,$(call int_dec,$(call int_encode,0)),Decrement underflow)
+$(call test_assert,$(call int_dec,$(call int_encode,1)),$(call int_encode,0))
+$(call test_assert,$(call int_dec,$(call int_encode,4)),$(call int_encode,3))
+$(call test_assert,$(call int_dec,$(call int_encode,10)),$(call int_encode,9))
+$(call stop_test)
+
+__gmsl_warning = x x x x x x x x x x
+$(call start_test,dec)
+$(call test_assert,$(call dec,0),10)
+$(call test_assert,$(call dec,1),0)
+$(call test_assert,$(call dec,4),3)
+$(call test_assert,$(call dec,10),9)
+$(call stop_test)
+
+$(call start_test,int_double)
+$(call test_assert,$(call int_double,$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_double,$(call int_encode,1)),$(call int_encode,2))
+$(call test_assert,$(call int_double,$(call int_encode,4)),$(call int_encode,8))
+$(call stop_test)
+
+$(call start_test,double)
+$(call test_assert,$(call double,0),0)
+$(call test_assert,$(call double,1),2)
+$(call test_assert,$(call double,4),8)
+$(call stop_test)
+
+$(call start_test,int_halve)
+$(call test_assert,$(call int_halve,$(call int_encode,0)),$(call int_encode,0))
+$(call test_assert,$(call int_halve,$(call int_encode,2)),$(call int_encode,1))
+$(call test_assert,$(call int_halve,$(call int_encode,8)),$(call int_encode,4))
+$(call test_assert,$(call int_halve,$(call int_encode,7)),$(call int_encode,3))
+$(call stop_test)
+
+$(call start_test,halve)
+$(call test_assert,$(call halve,0),0)
+$(call test_assert,$(call halve,2),1)
+$(call test_assert,$(call halve,8),4)
+$(call test_assert,$(call halve,7),3)
+$(call stop_test)
+
+$(call start_test,gt)
+$(call test_assert,$(call gt,2,3),)
+$(call test_assert,$(call gt,3,2),$(true))
+$(call test_assert,$(call gt,2,2),)
+$(call stop_test)
+
+$(call start_test,gte)
+$(call test_assert,$(call gte,2,3),)
+$(call test_assert,$(call gte,3,2),$(true))
+$(call test_assert,$(call gte,2,2),$(true))
+$(call stop_test)
+
+$(call start_test,lt)
+$(call test_assert,$(call lt,2,3),$(true))
+$(call test_assert,$(call lt,3,2),)
+$(call test_assert,$(call lt,2,2),)
+$(call stop_test)
+
+$(call start_test,lte)
+$(call test_assert,$(call lte,2,3),$(true))
+$(call test_assert,$(call lte,3,2),)
+$(call test_assert,$(call lte,2,2),$(true))
+$(call stop_test)
+
+$(call start_test,eq)
+$(call test_assert,$(call eq,2,3),)
+$(call test_assert,$(call eq,3,2),)
+$(call test_assert,$(call eq,2,2),$(true))
+$(call stop_test)
+
+$(call start_test,ne)
+$(call test_assert,$(call ne,2,3),$(true))
+$(call test_assert,$(call ne,3,2),$(true))
+$(call test_assert,$(call ne,2,2),)
+$(call stop_test)
+
+$(call start_test,int_gt)
+$(call test_assert,$(call int_gt,$(call int_encode,2),$(call int_encode,3)),)
+$(call test_assert,$(call int_gt,$(call int_encode,3),$(call int_encode,2)),$(true))
+$(call test_assert,$(call int_gt,$(call int_encode,2),$(call int_encode,2)),)
+$(call stop_test)
+
+$(call start_test,int_gte)
+$(call test_assert,$(call int_gte,$(call int_encode,2),$(call int_encode,3)),)
+$(call test_assert,$(call int_gte,$(call int_encode,3),$(call int_encode,2)),$(true))
+$(call test_assert,$(call int_gte,$(call int_encode,2),$(call int_encode,2)),$(true))
+$(call stop_test)
+
+$(call start_test,int_lt)
+$(call test_assert,$(call int_lt,$(call int_encode,2),$(call int_encode,3)),$(true))
+$(call test_assert,$(call int_lt,$(call int_encode,3),$(call int_encode,2)),)
+$(call test_assert,$(call int_lt,$(call int_encode,2),$(call int_encode,2)),)
+$(call stop_test)
+
+$(call start_test,int_lte)
+$(call test_assert,$(call int_lte,$(call int_encode,2),$(call int_encode,3)),$(true))
+$(call test_assert,$(call int_lte,$(call int_encode,3),$(call int_encode,2)),)
+$(call test_assert,$(call int_lte,$(call int_encode,2),$(call int_encode,2)),$(true))
+$(call stop_test)
+
+$(call start_test,int_eq)
+$(call test_assert,$(call int_eq,$(call int_encode,2),$(call int_encode,3)),)
+$(call test_assert,$(call int_eq,$(call int_encode,3),$(call int_encode,2)),)
+$(call test_assert,$(call int_eq,$(call int_encode,2),$(call int_encode,2)),$(true))
+$(call stop_test)
+
+$(call start_test,int_ne)
+$(call test_assert,$(call int_ne,$(call int_encode,2),$(call int_encode,3)),$(true))
+$(call test_assert,$(call int_ne,$(call int_encode,3),$(call int_encode,2)),$(true))
+$(call test_assert,$(call int_ne,$(call int_encode,2),$(call int_encode,2)),)
+$(call stop_test)
+
+$(call start_test,gmsl_compatible)
+$(call test_assert,$(call gmsl_compatible,$(gmsl_version)),$(true))
+$(call test_assert,$(call gmsl_compatible,0 9 0),$(true))
+$(call test_assert,$(call gmsl_compatible,0 0 1),$(true))
+$(call test_assert,$(call gmsl_compatible,0 0 0),$(true))
+$(call test_assert,$(call gmsl_compatible,2 0 0),)
+$(call test_assert,$(call gmsl_compatible,1 1 0),)
+$(call test_assert,$(call gmsl_compatible,1 0 8),$(true))
+$(call test_assert,$(call gmsl_compatible,1 0 8),$(true))
+$(call test_assert,$(call gmsl_compatible,1 0 10),$(true))
+$(call test_assert,$(call gmsl_compatible,1 0 11),$(true))
+$(call test_assert,$(call gmsl_compatible,1 0 12),)
+$(call stop_test)
diff --git a/ndk/build/gmsl/index.html b/ndk/build/gmsl/index.html
new file mode 100644
index 000000000..8cc93ae37
--- /dev/null
+++ b/ndk/build/gmsl/index.html
@@ -0,0 +1,687 @@
+
+
+
+ GNU Make Standard Library
+
+
+GNU Make Standard Library
+The GNU Make Standard Library (GMSL) is a collection of functions
+implemented using native GNU Make functionality that provide list and
+string manipulation, integer arithmetic, associative arrays, stacks,
+and debugging facilities. The GMSL is released under the BSD License.
+
+[Project Page] [Download]
+[Discussion
+Forum]
+Using GMSL
+The two files needed are gmsl
+and __gmsl. To
+include the GMSL in your Makefile do
+include gmsl
+gmsl automatically includes __gmsl. To check that
+you have the right version of gmsl
+use the gmsl_compatible
+function (see
+below). The current version is 1
+0 11.
+
+The GMSL package also includes a test suite for GMSL. Just run make -f gmsl-tests.
+Logical Operators
GMSL has boolean $(true) (a non-empty string)
+and $(false) (an empty string). The following operators can be
+used with those variables.
+
+
not
+
+
+
+Arguments: A boolean value
+
+Returns: Returns $(true) if the boolean is $(false) and vice versa
+
+
and
+
+Arguments: Two boolean values
+Returns: Returns $(true) if both of the booleans are true
+
or
+
+Arguments: Two boolean values
+Returns: Returns $(true) if either of the booleans is true
+
xor
+
+Arguments: Two boolean values
+Returns: Returns $(true) if exactly one of the booleans is true
+
nand
+
+Arguments: Two boolean values
+Returns: Returns value of 'not and'
+
nor
+
+Arguments: Two boolean values
+Returns: Returns value of 'not or'
+
xnor
+
+Arguments: Two boolean values
+Returns: Returns value of 'not xor'
+
+List Manipulation Functions
+ A list is a string of characters; the list separator is a space.
+
+
+
first
+
+Arguments: 1: A list
+Returns: Returns the first element of a list
+
+
last
+
+Arguments: 1: A list
+Returns: Returns the last element of a list
+
+
rest
+
+Arguments: 1: A list
+Returns: Returns the list with the first element
+removed
+
+
chop
+
+Arguments: 1: A list
+Returns: Returns the list with the last element removed
+
+
map
+
+Arguments: 1: Name of function to
+$(call) for each element of list
+ 2: List to
+iterate over calling the function in 1
+Returns: The list after calling the function on each
+element
+
+
pairmap
+
+Arguments: 1: Name of function to
+$(call) for each pair of elements
+ 2: List to
+iterate over calling the function in 1
+ 3: Second
+list to iterate over calling the function in 1
+Returns: The list after calling the function on each
+pair of elements
+
+
leq
+
+Arguments: 1: A list to compare
+against...
+ 2: ...this
+list
+Returns: Returns $(true) if the two lists are identical
+
+
lne
+
+Arguments: 1: A list to compare
+against...
+ 2: ...this
+list
+Returns: Returns $(true) if the two lists are different
+
+
reverse
+
+Arguments: 1: A list to reverse
+Returns: The list with its elements in reverse order
+
+
uniq
+
+Arguments: 1: A list to deduplicate
+Returns: The list with elements in order without duplicates
+
+
length
+
+Arguments: 1: A list
+Returns: The number of elements in the list
+
+
+String Manipulation Functions
+A string is any sequence of characters.
+
+
seq
+
+Arguments: 1: A string to compare
+against...
+ 2: ...this
+string
+Returns: Returns $(true) if the two strings are
+identical
+
+
sne
+
+Arguments: 1: A string to compare
+against...
+ 2: ...this
+string
+Returns: Returns $(true) if the two strings are not
+the same
+
+
strlen
+
+Arguments: 1: A string
+Returns: Returns the length of the string
+
+
substr
+
+Arguments: 1: A string
+ 2: Start offset (first character is 1)
+ 3: Ending offset (inclusive)
Returns: Returns a substring
+
+
split
+
+Arguments: 1: The character to
+split on
+ 2: A
+string to split
+Returns: Splits a string into a list separated by
+spaces at the split
+ character
+in the first argument
+
+
merge
+
+Arguments: 1: The character to
+put between fields
+ 2: A list
+to merge into a string
+Returns: Merges a list into a single string, list
+elements are separated
+ by the
+character in the first argument
+
+
tr
+
+Arguments: 1: The list of
+characters to translate from
+ 2: The
+list of characters to translate to
+ 3: The
+text to translate
+Returns: Returns the text after translating characters
+
+
uc
+
+Arguments: 1: Text to upper case
+Returns: Returns the text in upper case
+
+
lc
+
+Arguments: 1: Text to lower case
+Returns: Returns the text in lower case
+
+
+Set Manipulation Functions
+Sets are represented by sorted, deduplicated lists. To create a set
+from a list use set_create, or start with the empty_set and set_insert individual elements.
+The empty set is defined as empty_set.
+
+
set_create
+
+Arguments: 1: A list of set elements
+Returns: Returns the newly created set
+
+
+
set_insert
+
+Arguments: 1: A single element to add to a set
+ 2: A set
+Returns: Returns the set with the element added
+
+
+
set_remove
+
+Arguments: 1: A single element to remove from a set
+ 2: A set
+Returns: Returns the set with the element removed
+
+
+
set_is_member
+
+Arguments: 1: A single element
+ 2: A set
+Returns: Returns $(true) if the element is in the set
+
+
+
set_union
+
+Arguments: 1: A set
+ 2: Another set
+Returns: Returns the union of the two sets
+
+
+
set_intersection
+
+Arguments: 1: A set
+ 2: Another set
+Returns: Returns the intersection of the two sets
+
+
+
set_is_subset
+
+Arguments: 1: A set
+ 2: Another set
+Returns: Returns $(true) if the first set is a subset of the second
+
+
+
set_equal
+
+Arguments: 1: A set
+ 2: Another set
+Returns: Returns $(true) if the two sets are identical
+
+
+
+Integer Arithmetic Functions
+Integers are represented by lists with the equivalent number of
+x's. For example the number 4 is x x x x. The maximum
+integer that the library can handle as input (i.e. as the argument to a
+call to int_encode) is
+65536. There is no limit on integer size for internal computations or
+output.
+
+The arithmetic library functions come in two forms: one form of each
+function takes integers as arguments and the other form takes the
+encoded form (x's created by a call to int_encode). For example,
+there are two plus functions: plus
+(called with integer arguments and returns an integer) and int_plus (called with encoded
+arguments and returns an encoded result).
+
+plus will be slower than int_plus because its arguments
+and result have to be translated between the x's format and
+integers. If doing a complex calculation use the int_* forms with a single
+encoding of inputs and single decoding of the output. For simple
+calculations the direct forms can be used.
+
+
int_decode
+
+Arguments: 1: A number of x's
+representation
+Returns: Returns the integer for human consumption
+that is represented
+ by the
+string of x's
+
+
int_encode
+
+Arguments: 1: A number in
+human-readable integer form
+Returns: Returns the integer encoded as a string of x's
+
+
int_plus
+
+Arguments: 1: A number in x's
+representation
+ 2: Another
+number in x's represntation
+Returns: Returns the sum of the two numbers in x's
+representation
+
+
plus (wrapped version of int_plus)
+
+Arguments: 1: An integer
+ 2: Another
+integer
+Returns: Returns the sum of the two integers
+
+
int_subtract
+
+Arguments: 1: A number in x's
+representation
+ 2: Another
+number in x's represntation
+Returns: Returns the difference of the two numbers in
+x's representation,
+ or outputs
+an error on a numeric underflow
+
+
subtract (wrapped version of int_subtract)
+
+Arguments: 1: An integer
+ 2: Another
+integer
+Returns: Returns the difference of the two integers,
+ or outputs
+an error on a numeric underflow
+
+
int_multiply
+
+Arguments: 1: A number in x's
+representation
+ 2: Another
+number in x's represntation
+Returns: Returns the product of the two numbers in x's
+representation
+
+
multiply (wrapped version of int_multiply)
+
+Arguments: 1: An integer
+ 2: Another
+integer
+Returns: Returns the product of the two integers
+
+
int_divide
+
+Arguments: 1: A number in x's
+representation
+ 2: Another
+number in x's represntation
+Returns: Returns the result of integer division of
+argument 1 divided
+ by
+argument 2 in x's representation
+
+
divide (wrapped version of int_divide)
+
+Arguments: 1: An integer
+ 2: Another
+integer
+Returns: Returns the integer division of the first
+argument by the second
+
+
int_max, int_min
+
+Arguments: 1: A number in x's
+representation
+ 2: Another
+number in x's represntation
+Returns: Returns the maximum or minimum of its
+arguments in x's
+
+representation
+
+
max, min
+
+Arguments: 1: An integer
+ 2: Another
+integer
+Returns: Returns the maximum or minimum of its integer
+arguments
+
+
int_gt, int_gte, int_lt, int_lte, int_eq, int_ne
+
+Arguments: Two x's representation
+numbers to be compared
+Returns: $(true) or $(false)
+
+int_gt First argument greater than second argument
+int_gte First argument greater than or equal to second argument
+int_lt First argument less than second argument
+int_lte First argument less than or equal to second argument
+int_eq First argument is numerically equal to the second argument
+int_ne First argument is not numerically equal to the second argument
+
+
gt, gte, lt, lte, eq, ne
+
+Arguments: Two integers to be
+compared
+Returns: $(true) or $(false)
+
+gt First argument greater than second argument
+gte First argument greater than or equal to second argument
+lt First argument less than second argument
+lte First argument less than or equal to second argument
+eq First argument is numerically equal to the second argument
+ne First argument is not numerically equal to the second argument
+
+increment adds 1 to its argument, decrement subtracts 1. Note that
+decrement does not range check and hence will not underflow, but
+will incorrectly say that 0 - 1 = 0
+
int_inc
+
+Arguments: 1: A number in x's
+representation
+Returns: The number incremented by 1 in x's
+representation
+
+
inc
+
+Arguments: 1: An integer
+Returns: The argument incremented by 1
+
+
int_dec
+
+Arguments: 1: A number in x's
+representation
+Returns: The number decremented by 1 in x's
+representation
+
+
dec
+
+Arguments: 1: An integer
+Returns: The argument decremented by 1
+
+
int_double
+
+Arguments: 1: A number in x's
+representation
+Returns: The number doubled (i.e. * 2) and returned in
+x's representation
+
+
double
+
+Arguments: 1: An integer
+Returns: The integer times 2
+
+
int_halve
+
+Arguments: 1: A number in x's
+representation
+Returns: The number halved (i.e. / 2) and returned in
+x's representation
+
+
halve
+
+Arguments: 1: An integer
+Returns: The integer divided by 2
+
+
+Associative Arrays
+An associate array maps a key value (a string with no spaces in it) to
+a single value (any string).
+
+
+
set
+
+Arguments: 1: Name of associative
+array
+ 2: The key
+value to associate
+ 3: The
+value associated with the key
+Returns: None
+
+
get
+
+Arguments: 1: Name of associative
+array
+ 2: The key
+to retrieve
+Returns: The value stored in the array for that key
+
+
keys
+
+Arguments: 1: Name of associative
+array
+Returns: Returns a list of all defined keys in the
+array
+
+
defined
+
+Arguments: 1: Name of associative
+array
+ 2: The key
+to test
+Returns: Returns true if the key is defined (i.e. not
+empty)
+
+
+Named Stacks
+A stack is an ordered list of strings (with no spaces in them).
+
+
push
+
+Arguments: 1: Name of stack
+ 2: Value
+to push onto the top of the stack (must not contain
+ a space)
+Returns: None
+
+
pop
+
+Arguments: 1: Name of stack
+Returns: Top element from the stack after removing it
+
+
peek
+
+Arguments: 1: Name of stack
+Returns: Top element from the stack without removing it
+
+
depth
+
+Arguments: 1: Name of stack
+Returns: Number of items on the stack
+
+
+Miscellaneous and Debugging Facilities
+GMSL defines the following constants; all are accessed as normal GNU
+Make variables by wrapping them in $() or ${}.
+
+
+
+
+ Constant
+ |
+ Value
+ |
+ Purpose
+ |
+
+
+ true
+ |
+ T
+ |
+ Boolean for $(if)
+and return from GMSL functions
+ |
+
+
+ false
+ |
+
+ |
+ Boolean for $(if)
+and return from GMSL functions
+ |
+
+
+ gmsl_version
+ |
+ 1 0 0
+ |
+ GMSL version number as list: major minor revision
+ |
+
+
+
+
+gmsl_compatible
+
+Arguments: List containing the desired library version number (maj min
+rev)
+Returns:
+$(true) if this version of the library is compatible
+
+with the requested version number, otherwise $(false)
+
gmsl-print-% (target not a function)
+
+Arguments: The % should be
+replaced by the name of a variable that you
+ wish to
+print out.
+Action: Echos the name of the variable that matches
+the % and its value.
+ For
+example, 'make gmsl-print-SHELL' will output the value of
+ the SHELL
+variable
+
+
assert
+
+Arguments: 1: A boolean that must
+be true or the assertion will fail
+ 2: The
+message to print with the assertion
+Returns: None
+
+
assert_exists
+
+Arguments: 1: Name of file that
+must exist, if it is missing an assertion
+ will be
+generated
+Returns: None
+
+
+GMSL has a number of environment variables (or command-line overrides)
+that control various bits of functionality:
+
+
+
+
+ Variable
+ |
+ Purpose
+ |
+
+
+ GMSL_NO_WARNINGS
+ |
+ If set prevents GMSL from outputting warning messages:
+artithmetic functions generate underflow warnings.
+ |
+
+
+ GMSL_NO_ERRORS
+ |
+ If set prevents GMSL from generating fatal errors: division
+by zero or failed assertions are fatal.
+ |
+
+
+ GMSL_TRACE
+ |
+ Enables function tracing. Calls to GMSL functions will
+result in name and arguments being traced.
+ |
+
+
+
+
+
+Copyright (c) 2005-2006 John Graham-Cumming.
+
+
+
+
+ John Graham-Cumming's work on this
+project was sponsored by Electric
+Cloud, Inc.
+ 
+ |
+
+ 
+ |
+
+
+
+
diff --git a/ndk/build/host-setup.sh b/ndk/build/host-setup.sh
new file mode 100755
index 000000000..f3d80989f
--- /dev/null
+++ b/ndk/build/host-setup.sh
@@ -0,0 +1,99 @@
+#!/bin/sh
+#
+# Copyright (C) 2009 The Android Open Source Project
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+# A shell script used to configure the host-specific parts of the NDK
+# build system. This will create out/host/config-host.make based on
+# your host system and additionnal command-line options.
+#
+
+# include common function and variable definitions
+source `dirname $0`/core/ndk-common.sh
+
+OUT_DIR=out
+HOST_CONFIG=$OUT_DIR/host/config.mk
+
+## Build configuration file support
+## you must define $config_mk before calling this function
+##
+create_config_mk ()
+{
+ # create the directory if needed
+ local config_dir
+ config_mk=${config_mk:-$HOST_CONFIG}
+ config_dir=`dirname $config_mk`
+ mkdir -p $config_dir 2> $TMPL
+ if [ $? != 0 ] ; then
+ echo "Can't create directory for host config file: $config_dir"
+ exit 1
+ fi
+
+ # re-create the start of the configuration file
+ log "Generate : $config_mk"
+
+ echo "# This file was autogenerated by $PROGNAME. Do not edit !" > $config_mk
+}
+
+add_config ()
+{
+ echo "$1" >> $config_mk
+}
+
+echo "Detecting host toolchain."
+echo ""
+
+setup_toolchain
+
+create_config_mk
+
+add_config "HOST_OS := $HOST_OS"
+add_config "HOST_ARCH := $HOST_ARCH"
+add_config "HOST_TAG := $HOST_TAG"
+add_config "HOST_CC := $CC"
+add_config "HOST_CFLAGS := $CFLAGS"
+add_config "HOST_CXX := $CXX"
+add_config "HOST_CXXFLAGS := $CXXFLAGS"
+add_config "HOST_LD := $LD"
+add_config "HOST_LDFLAGS := $LDFLAGS"
+add_config "HOST_AR := $AR"
+add_config "HOST_ARFLAGS := $ARFLAGS"
+
+## Check that the toolchains we need are installed
+## Otherwise, instruct the user to download them from the web site
+
+TOOLCHAINS=arm-eabi-4.2.1
+
+
+for tc in $TOOLCHAINS; do
+ echo "Toolchain : Checking for $tc prebuilt binaries"
+ COMPILER_PATTERN=$ANDROID_NDK_ROOT/build/prebuilt/$HOST_TAG/$tc/bin/*-gcc
+ COMPILERS=`ls $COMPILER_PATTERN 2> /dev/null`
+ if [ -z $COMPILERS ] ; then
+ echo ""
+ echo "ERROR:"
+ echo "It seems you do not have the prebuilt $tc toolchain binaries."
+ echo "Please go to the official Android NDK web site and download the"
+ echo "appropriate toolchain package for your platform ($HOST_TAG)."
+ echo "See http://developer.android.com/ndk/1.5/index.html"
+ echo ""
+ echo "ABORTING."
+ echo ""
+ exit 1
+ fi
+done
+
+echo ""
+echo "Host setup complete. Please read docs/OVERVIEW.TXT if you don't know what to do."
+echo ""
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/alloca.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/alloca.h
new file mode 120000
index 000000000..ac859df9a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/alloca.h
@@ -0,0 +1 @@
+../../../common/include/alloca.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/arm/fenv.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arm/fenv.h
new file mode 100644
index 000000000..e7a88604b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arm/fenv.h
@@ -0,0 +1,217 @@
+/*-
+ * Copyright (c) 2004-2005 David Schultz
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * $FreeBSD: src/lib/msun/arm/fenv.h,v 1.5 2005/03/16 19:03:45 das Exp $
+ */
+
+#ifndef _FENV_H_
+#define _FENV_H_
+
+#include
+
+typedef __uint32_t fenv_t;
+typedef __uint32_t fexcept_t;
+
+/* Exception flags */
+#define FE_INVALID 0x0001
+#define FE_DIVBYZERO 0x0002
+#define FE_OVERFLOW 0x0004
+#define FE_UNDERFLOW 0x0008
+#define FE_INEXACT 0x0010
+#define FE_ALL_EXCEPT (FE_DIVBYZERO | FE_INEXACT | \
+ FE_INVALID | FE_OVERFLOW | FE_UNDERFLOW)
+
+/* Rounding modes */
+#define FE_TONEAREST 0x0000
+#define FE_TOWARDZERO 0x0001
+#define FE_UPWARD 0x0002
+#define FE_DOWNWARD 0x0003
+#define _ROUND_MASK (FE_TONEAREST | FE_DOWNWARD | \
+ FE_UPWARD | FE_TOWARDZERO)
+__BEGIN_DECLS
+
+/* Default floating-point environment */
+extern const fenv_t __fe_dfl_env;
+#define FE_DFL_ENV (&__fe_dfl_env)
+
+/* We need to be able to map status flag positions to mask flag positions */
+#define _FPUSW_SHIFT 16
+#define _ENABLE_MASK (FE_ALL_EXCEPT << _FPUSW_SHIFT)
+
+#ifdef ARM_HARD_FLOAT
+#define __rfs(__fpsr) __asm __volatile("rfs %0" : "=r" (*(__fpsr)))
+#define __wfs(__fpsr) __asm __volatile("wfs %0" : : "r" (__fpsr))
+#else
+#define __rfs(__fpsr)
+#define __wfs(__fpsr)
+#endif
+
+static __inline int
+feclearexcept(int __excepts)
+{
+ fexcept_t __fpsr;
+
+ __rfs(&__fpsr);
+ __fpsr &= ~__excepts;
+ __wfs(__fpsr);
+ return (0);
+}
+
+static __inline int
+fegetexceptflag(fexcept_t *__flagp, int __excepts)
+{
+ fexcept_t __fpsr;
+
+ __rfs(&__fpsr);
+ *__flagp = __fpsr & __excepts;
+ return (0);
+}
+
+static __inline int
+fesetexceptflag(const fexcept_t *__flagp, int __excepts)
+{
+ fexcept_t __fpsr;
+
+ __rfs(&__fpsr);
+ __fpsr &= ~__excepts;
+ __fpsr |= *__flagp & __excepts;
+ __wfs(__fpsr);
+ return (0);
+}
+
+static __inline int
+feraiseexcept(int __excepts)
+{
+ fexcept_t __ex = __excepts;
+
+ fesetexceptflag(&__ex, __excepts); /* XXX */
+ return (0);
+}
+
+static __inline int
+fetestexcept(int __excepts)
+{
+ fexcept_t __fpsr;
+
+ __rfs(&__fpsr);
+ return (__fpsr & __excepts);
+}
+
+static __inline int
+fegetround(void)
+{
+
+ /*
+ * Apparently, the rounding mode is specified as part of the
+ * instruction format on ARM, so the dynamic rounding mode is
+ * indeterminate. Some FPUs may differ.
+ */
+ return (-1);
+}
+
+static __inline int
+fesetround(int __round)
+{
+
+ return (-1);
+}
+
+static __inline int
+fegetenv(fenv_t *__envp)
+{
+
+ __rfs(__envp);
+ return (0);
+}
+
+static __inline int
+feholdexcept(fenv_t *__envp)
+{
+ fenv_t __env;
+
+ __rfs(&__env);
+ *__envp = __env;
+ __env &= ~(FE_ALL_EXCEPT | _ENABLE_MASK);
+ __wfs(__env);
+ return (0);
+}
+
+static __inline int
+fesetenv(const fenv_t *__envp)
+{
+
+ __wfs(*__envp);
+ return (0);
+}
+
+static __inline int
+feupdateenv(const fenv_t *__envp)
+{
+ fexcept_t __fpsr;
+
+ __rfs(&__fpsr);
+ __wfs(*__envp);
+ feraiseexcept(__fpsr & FE_ALL_EXCEPT);
+ return (0);
+}
+
+#if __BSD_VISIBLE
+
+static __inline int
+feenableexcept(int __mask)
+{
+ fenv_t __old_fpsr, __new_fpsr;
+
+ __rfs(&__old_fpsr);
+ __new_fpsr = __old_fpsr | (__mask & FE_ALL_EXCEPT) << _FPUSW_SHIFT;
+ __wfs(__new_fpsr);
+ return ((__old_fpsr >> _FPUSW_SHIFT) & FE_ALL_EXCEPT);
+}
+
+static __inline int
+fedisableexcept(int __mask)
+{
+ fenv_t __old_fpsr, __new_fpsr;
+
+ __rfs(&__old_fpsr);
+ __new_fpsr = __old_fpsr & ~((__mask & FE_ALL_EXCEPT) << _FPUSW_SHIFT);
+ __wfs(__new_fpsr);
+ return ((__old_fpsr >> _FPUSW_SHIFT) & FE_ALL_EXCEPT);
+}
+
+static __inline int
+fegetexcept(void)
+{
+ fenv_t __fpsr;
+
+ __rfs(&__fpsr);
+ return ((__fpsr & _ENABLE_MASK) >> _FPUSW_SHIFT);
+}
+
+#endif /* __BSD_VISIBLE */
+
+__END_DECLS
+
+#endif /* !_FENV_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/inet.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/inet.h
new file mode 120000
index 000000000..760a19d9e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/inet.h
@@ -0,0 +1 @@
+../../../../common/include/arpa/inet.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/nameser.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/nameser.h
new file mode 120000
index 000000000..73f9311a8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/arpa/nameser.h
@@ -0,0 +1 @@
+../../../../common/include/arpa/nameser.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/4level-fixup.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/4level-fixup.h
new file mode 120000
index 000000000..4493a92e2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/4level-fixup.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/4level-fixup.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/audit_dir_write.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/audit_dir_write.h
new file mode 120000
index 000000000..6576f52a9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/audit_dir_write.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/audit_dir_write.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/__ffs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/__ffs.h
new file mode 120000
index 000000000..9a68edc32
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/__ffs.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/__ffs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/atomic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/atomic.h
new file mode 120000
index 000000000..32afeb41b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/atomic.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/atomic.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/ffz.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/ffz.h
new file mode 120000
index 000000000..50c52144c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/ffz.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/ffz.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/find.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/find.h
new file mode 120000
index 000000000..9b40acd3d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/find.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/find.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls.h
new file mode 120000
index 000000000..517188731
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/fls.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls64.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls64.h
new file mode 120000
index 000000000..8728e6a34
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/fls64.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/fls64.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/le.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/le.h
new file mode 120000
index 000000000..91b46c781
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/le.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/le.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/non-atomic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/non-atomic.h
new file mode 120000
index 000000000..177973e25
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bitops/non-atomic.h
@@ -0,0 +1 @@
+../../../../../common/include/asm-generic/bitops/non-atomic.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bug.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bug.h
new file mode 120000
index 000000000..d898f3a49
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/bug.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/bug.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/cputime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/cputime.h
new file mode 120000
index 000000000..7892fb4ba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/cputime.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/cputime.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/emergency-restart.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/emergency-restart.h
new file mode 120000
index 000000000..3005c7489
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/emergency-restart.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/emergency-restart.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno-base.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno-base.h
new file mode 120000
index 000000000..7b7d9bd30
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno-base.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/errno-base.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno.h
new file mode 120000
index 000000000..bdd6dd4a1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/errno.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/errno.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/fcntl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/fcntl.h
new file mode 120000
index 000000000..3506aa8f1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/fcntl.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/fcntl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/futex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/futex.h
new file mode 120000
index 000000000..cbd47bf64
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/futex.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/futex.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ioctl.h
new file mode 120000
index 000000000..7a1162396
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ioctl.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/ioctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ipc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ipc.h
new file mode 120000
index 000000000..339894eba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/ipc.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/ipc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/local.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/local.h
new file mode 120000
index 000000000..0e9344dbd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/local.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/local.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/memory_model.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/memory_model.h
new file mode 120000
index 000000000..3bbc82b9c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/memory_model.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/memory_model.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mman.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mman.h
new file mode 120000
index 000000000..fbab1252d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mman.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/mman.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mutex-xchg.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mutex-xchg.h
new file mode 120000
index 000000000..c7bc238fb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/mutex-xchg.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/mutex-xchg.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/percpu.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/percpu.h
new file mode 120000
index 000000000..2d899dbc9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/percpu.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/percpu.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable-nopud.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable-nopud.h
new file mode 120000
index 000000000..ac2157e57
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable-nopud.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/pgtable-nopud.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable.h
new file mode 120000
index 000000000..4c70646bf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/pgtable.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/pgtable.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/poll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/poll.h
new file mode 120000
index 000000000..2bd359a25
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/poll.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/poll.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/resource.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/resource.h
new file mode 120000
index 000000000..28f331a74
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/resource.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/resource.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/sections.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/sections.h
new file mode 120000
index 000000000..c6885f3da
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/sections.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/sections.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/siginfo.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/siginfo.h
new file mode 120000
index 000000000..d38f2115f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/siginfo.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/siginfo.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/signal.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/signal.h
new file mode 120000
index 000000000..05ca3527e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/signal.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/signal.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/tlb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/tlb.h
new file mode 120000
index 000000000..94baa9563
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/tlb.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/tlb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/topology.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/topology.h
new file mode 120000
index 000000000..e85b48f5e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/topology.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/topology.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/xor.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/xor.h
new file mode 120000
index 000000000..baf211847
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm-generic/xor.h
@@ -0,0 +1 @@
+../../../../common/include/asm-generic/xor.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/a.out.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/a.out.h
new file mode 100644
index 000000000..e8f17dc1c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/a.out.h
@@ -0,0 +1,42 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARM_A_OUT_H__
+#define __ARM_A_OUT_H__
+
+#include
+#include
+
+struct exec
+{
+ __u32 a_info;
+ __u32 a_text;
+ __u32 a_data;
+ __u32 a_bss;
+ __u32 a_syms;
+ __u32 a_entry;
+ __u32 a_trsize;
+ __u32 a_drsize;
+};
+
+#define N_TXTADDR(a) (0x00008000)
+
+#define N_TRSIZE(a) ((a).a_trsize)
+#define N_DRSIZE(a) ((a).a_drsize)
+#define N_SYMSIZE(a) ((a).a_syms)
+
+#define M_ARM 103
+
+#ifndef LIBRARY_START_TEXT
+#define LIBRARY_START_TEXT (0x00c00000)
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board-perseus2.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board-perseus2.h
new file mode 100644
index 000000000..c6c5413fd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board-perseus2.h
@@ -0,0 +1,27 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_PERSEUS2_H
+#define __ASM_ARCH_OMAP_PERSEUS2_H
+
+#include
+
+#ifndef OMAP_SDRAM_DEVICE
+#define OMAP_SDRAM_DEVICE D256M_1X16_4B
+#endif
+
+#define MAXIRQNUM IH_BOARD_BASE
+#define MAXFIQNUM MAXIRQNUM
+#define MAXSWINUM MAXIRQNUM
+
+#define NR_IRQS (MAXIRQNUM + 1)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board.h
new file mode 100644
index 000000000..a7a4c669a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/board.h
@@ -0,0 +1,163 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _OMAP_BOARD_H
+#define _OMAP_BOARD_H
+
+#include
+
+#include
+
+#define OMAP_TAG_CLOCK 0x4f01
+#define OMAP_TAG_MMC 0x4f02
+#define OMAP_TAG_SERIAL_CONSOLE 0x4f03
+#define OMAP_TAG_USB 0x4f04
+#define OMAP_TAG_LCD 0x4f05
+#define OMAP_TAG_GPIO_SWITCH 0x4f06
+#define OMAP_TAG_UART 0x4f07
+#define OMAP_TAG_FBMEM 0x4f08
+#define OMAP_TAG_STI_CONSOLE 0x4f09
+#define OMAP_TAG_CAMERA_SENSOR 0x4f0a
+#define OMAP_TAG_BT 0x4f0b
+
+#define OMAP_TAG_BOOT_REASON 0x4f80
+#define OMAP_TAG_FLASH_PART 0x4f81
+#define OMAP_TAG_VERSION_STR 0x4f82
+
+struct omap_clock_config {
+
+ u8 system_clock_type;
+};
+
+struct omap_mmc_conf {
+ unsigned enabled:1;
+
+ unsigned nomux:1;
+
+ unsigned cover:1;
+
+ unsigned wire4:1;
+ s16 power_pin;
+ s16 switch_pin;
+ s16 wp_pin;
+};
+
+struct omap_mmc_config {
+ struct omap_mmc_conf mmc[2];
+};
+
+struct omap_serial_console_config {
+ u8 console_uart;
+ u32 console_speed;
+};
+
+struct omap_sti_console_config {
+ unsigned enable:1;
+ u8 channel;
+};
+
+struct omap_camera_sensor_config {
+ u16 reset_gpio;
+ int (*power_on)(void * data);
+ int (*power_off)(void * data);
+};
+
+struct omap_usb_config {
+
+ unsigned register_host:1;
+ unsigned register_dev:1;
+ u8 otg;
+
+ u8 hmc_mode;
+
+ u8 rwc;
+
+ u8 pins[3];
+};
+
+struct omap_lcd_config {
+ char panel_name[16];
+ char ctrl_name[16];
+ s16 nreset_gpio;
+ u8 data_lines;
+};
+
+struct device;
+struct fb_info;
+struct omap_backlight_config {
+ int default_intensity;
+ int (*set_power)(struct device *dev, int state);
+ int (*check_fb)(struct fb_info *fb);
+};
+
+struct omap_fbmem_config {
+ u32 start;
+ u32 size;
+};
+
+struct omap_pwm_led_platform_data {
+ const char *name;
+ int intensity_timer;
+ int blink_timer;
+ void (*set_power)(struct omap_pwm_led_platform_data *self, int on_off);
+};
+
+struct omap_gpio_switch_config {
+ char name[12];
+ u16 gpio;
+ int flags:4;
+ int type:4;
+ int key_code:24;
+};
+
+struct omap_uart_config {
+
+ unsigned int enabled_uarts;
+};
+
+struct omap_flash_part_config {
+ char part_table[0];
+};
+
+struct omap_boot_reason_config {
+ char reason_str[12];
+};
+
+struct omap_version_config {
+ char component[12];
+ char version[12];
+};
+
+struct omap_board_config_entry {
+ u16 tag;
+ u16 len;
+ u8 data[0];
+};
+
+struct omap_board_config_kernel {
+ u16 tag;
+ const void *data;
+};
+
+struct omap_bluetooth_config {
+ u8 chip_type;
+ u8 bt_uart;
+ u8 bd_addr[6];
+ u8 bt_sysclk;
+ int bt_wakeup_gpio;
+ int host_wakeup_gpio;
+ int reset_gpio;
+};
+
+#define omap_get_config(tag, type) ((const type *) __omap_get_config((tag), sizeof(type), 0))
+#define omap_get_nr_config(tag, type, nr) ((const type *) __omap_get_config((tag), sizeof(type), (nr)))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/cpu.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/cpu.h
new file mode 100644
index 000000000..fa7a40861
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/cpu.h
@@ -0,0 +1,57 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_CPU_H
+#define __ASM_ARCH_OMAP_CPU_H
+
+#define omap2_cpu_rev() ((system_rev >> 8) & 0x0f)
+
+#undef MULTI_OMAP1
+#undef MULTI_OMAP2
+#undef OMAP_NAME
+
+#define GET_OMAP_CLASS (system_rev & 0xff)
+
+#define IS_OMAP_CLASS(class, id) static inline int is_omap ##class (void) { return (GET_OMAP_CLASS == (id)) ? 1 : 0; }
+
+#define GET_OMAP_SUBCLASS ((system_rev >> 20) & 0x0fff)
+
+#define IS_OMAP_SUBCLASS(subclass, id) static inline int is_omap ##subclass (void) { return (GET_OMAP_SUBCLASS == (id)) ? 1 : 0; }
+
+#define cpu_is_omap7xx() 0
+#define cpu_is_omap15xx() 0
+#define cpu_is_omap16xx() 0
+#define cpu_is_omap24xx() 0
+#define cpu_is_omap242x() 0
+#define cpu_is_omap243x() 0
+#ifdef MULTI_OMAP1
+#else
+#endif
+#define GET_OMAP_TYPE ((system_rev >> 16) & 0xffff)
+#define IS_OMAP_TYPE(type, id) static inline int is_omap ##type (void) { return (GET_OMAP_TYPE == (id)) ? 1 : 0; }
+#define cpu_is_omap310() 0
+#define cpu_is_omap730() 0
+#define cpu_is_omap1510() 0
+#define cpu_is_omap1610() 0
+#define cpu_is_omap5912() 0
+#define cpu_is_omap1611() 0
+#define cpu_is_omap1621() 0
+#define cpu_is_omap1710() 0
+#define cpu_is_omap2420() 0
+#define cpu_is_omap2422() 0
+#define cpu_is_omap2423() 0
+#define cpu_is_omap2430() 0
+#ifdef MULTI_OMAP1
+#else
+#endif
+#define cpu_class_is_omap1() (cpu_is_omap730() || cpu_is_omap15xx() || cpu_is_omap16xx())
+#define cpu_class_is_omap2() cpu_is_omap24xx()
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/dma.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/dma.h
new file mode 100644
index 000000000..5e5be7652
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/dma.h
@@ -0,0 +1,318 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_DMA_H
+#define __ASM_ARCH_DMA_H
+
+#define OMAP_DMA_BASE (0xfffed800)
+#define OMAP_DMA_GCR (OMAP_DMA_BASE + 0x400)
+#define OMAP_DMA_GSCR (OMAP_DMA_BASE + 0x404)
+#define OMAP_DMA_GRST (OMAP_DMA_BASE + 0x408)
+#define OMAP_DMA_HW_ID (OMAP_DMA_BASE + 0x442)
+#define OMAP_DMA_PCH2_ID (OMAP_DMA_BASE + 0x444)
+#define OMAP_DMA_PCH0_ID (OMAP_DMA_BASE + 0x446)
+#define OMAP_DMA_PCH1_ID (OMAP_DMA_BASE + 0x448)
+#define OMAP_DMA_PCHG_ID (OMAP_DMA_BASE + 0x44a)
+#define OMAP_DMA_PCHD_ID (OMAP_DMA_BASE + 0x44c)
+#define OMAP_DMA_CAPS_0_U (OMAP_DMA_BASE + 0x44e)
+#define OMAP_DMA_CAPS_0_L (OMAP_DMA_BASE + 0x450)
+#define OMAP_DMA_CAPS_1_U (OMAP_DMA_BASE + 0x452)
+#define OMAP_DMA_CAPS_1_L (OMAP_DMA_BASE + 0x454)
+#define OMAP_DMA_CAPS_2 (OMAP_DMA_BASE + 0x456)
+#define OMAP_DMA_CAPS_3 (OMAP_DMA_BASE + 0x458)
+#define OMAP_DMA_CAPS_4 (OMAP_DMA_BASE + 0x45a)
+#define OMAP_DMA_PCH2_SR (OMAP_DMA_BASE + 0x460)
+#define OMAP_DMA_PCH0_SR (OMAP_DMA_BASE + 0x480)
+#define OMAP_DMA_PCH1_SR (OMAP_DMA_BASE + 0x482)
+#define OMAP_DMA_PCHD_SR (OMAP_DMA_BASE + 0x4c0)
+
+#define OMAP24XX_DMA_BASE (L4_24XX_BASE + 0x56000)
+#define OMAP_DMA4_REVISION (OMAP24XX_DMA_BASE + 0x00)
+#define OMAP_DMA4_GCR_REG (OMAP24XX_DMA_BASE + 0x78)
+#define OMAP_DMA4_IRQSTATUS_L0 (OMAP24XX_DMA_BASE + 0x08)
+#define OMAP_DMA4_IRQSTATUS_L1 (OMAP24XX_DMA_BASE + 0x0c)
+#define OMAP_DMA4_IRQSTATUS_L2 (OMAP24XX_DMA_BASE + 0x10)
+#define OMAP_DMA4_IRQSTATUS_L3 (OMAP24XX_DMA_BASE + 0x14)
+#define OMAP_DMA4_IRQENABLE_L0 (OMAP24XX_DMA_BASE + 0x18)
+#define OMAP_DMA4_IRQENABLE_L1 (OMAP24XX_DMA_BASE + 0x1c)
+#define OMAP_DMA4_IRQENABLE_L2 (OMAP24XX_DMA_BASE + 0x20)
+#define OMAP_DMA4_IRQENABLE_L3 (OMAP24XX_DMA_BASE + 0x24)
+#define OMAP_DMA4_SYSSTATUS (OMAP24XX_DMA_BASE + 0x28)
+#define OMAP_DMA4_CAPS_0 (OMAP24XX_DMA_BASE + 0x64)
+#define OMAP_DMA4_CAPS_2 (OMAP24XX_DMA_BASE + 0x6c)
+#define OMAP_DMA4_CAPS_3 (OMAP24XX_DMA_BASE + 0x70)
+#define OMAP_DMA4_CAPS_4 (OMAP24XX_DMA_BASE + 0x74)
+
+#define OMAP_LOGICAL_DMA_CH_COUNT 32
+
+#define OMAP_DMA_CCR_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x80)
+#define OMAP_DMA_CLNK_CTRL_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x84)
+#define OMAP_DMA_CICR_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x88)
+#define OMAP_DMA_CSR_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x8c)
+#define OMAP_DMA_CSDP_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x90)
+#define OMAP_DMA_CEN_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x94)
+#define OMAP_DMA_CFN_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x98)
+#define OMAP_DMA_CSEI_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xa4)
+#define OMAP_DMA_CSFI_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xa8)
+#define OMAP_DMA_CDEI_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xac)
+#define OMAP_DMA_CDFI_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xb0)
+#define OMAP_DMA_CSAC_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xb4)
+#define OMAP_DMA_CDAC_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xb8)
+
+#define OMAP1_DMA_CSSA_L_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x08)
+#define OMAP1_DMA_CSSA_U_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x0a)
+#define OMAP1_DMA_CDSA_L_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x0c)
+#define OMAP1_DMA_CDSA_U_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x0e)
+#define OMAP1_DMA_COLOR_L_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x20)
+#define OMAP1_DMA_CCR2_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x24)
+#define OMAP1_DMA_COLOR_U_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x22)
+#define OMAP1_DMA_LCH_CTRL_REG(n) __REG16(OMAP_DMA_BASE + 0x40 * (n) + 0x2a)
+
+#define OMAP2_DMA_CSSA_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0x9c)
+#define OMAP2_DMA_CDSA_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xa0)
+#define OMAP2_DMA_CCEN_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xbc)
+#define OMAP2_DMA_CCFN_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xc0)
+#define OMAP2_DMA_COLOR_REG(n) __REG32(OMAP24XX_DMA_BASE + 0x60 * (n) + 0xc4)
+
+#define OMAP_DMA_NO_DEVICE 0
+#define OMAP_DMA_MCSI1_TX 1
+#define OMAP_DMA_MCSI1_RX 2
+#define OMAP_DMA_I2C_RX 3
+#define OMAP_DMA_I2C_TX 4
+#define OMAP_DMA_EXT_NDMA_REQ 5
+#define OMAP_DMA_EXT_NDMA_REQ2 6
+#define OMAP_DMA_UWIRE_TX 7
+#define OMAP_DMA_MCBSP1_TX 8
+#define OMAP_DMA_MCBSP1_RX 9
+#define OMAP_DMA_MCBSP3_TX 10
+#define OMAP_DMA_MCBSP3_RX 11
+#define OMAP_DMA_UART1_TX 12
+#define OMAP_DMA_UART1_RX 13
+#define OMAP_DMA_UART2_TX 14
+#define OMAP_DMA_UART2_RX 15
+#define OMAP_DMA_MCBSP2_TX 16
+#define OMAP_DMA_MCBSP2_RX 17
+#define OMAP_DMA_UART3_TX 18
+#define OMAP_DMA_UART3_RX 19
+#define OMAP_DMA_CAMERA_IF_RX 20
+#define OMAP_DMA_MMC_TX 21
+#define OMAP_DMA_MMC_RX 22
+#define OMAP_DMA_NAND 23
+#define OMAP_DMA_IRQ_LCD_LINE 24
+#define OMAP_DMA_MEMORY_STICK 25
+#define OMAP_DMA_USB_W2FC_RX0 26
+#define OMAP_DMA_USB_W2FC_RX1 27
+#define OMAP_DMA_USB_W2FC_RX2 28
+#define OMAP_DMA_USB_W2FC_TX0 29
+#define OMAP_DMA_USB_W2FC_TX1 30
+#define OMAP_DMA_USB_W2FC_TX2 31
+
+#define OMAP_DMA_CRYPTO_DES_IN 32
+#define OMAP_DMA_SPI_TX 33
+#define OMAP_DMA_SPI_RX 34
+#define OMAP_DMA_CRYPTO_HASH 35
+#define OMAP_DMA_CCP_ATTN 36
+#define OMAP_DMA_CCP_FIFO_NOT_EMPTY 37
+#define OMAP_DMA_CMT_APE_TX_CHAN_0 38
+#define OMAP_DMA_CMT_APE_RV_CHAN_0 39
+#define OMAP_DMA_CMT_APE_TX_CHAN_1 40
+#define OMAP_DMA_CMT_APE_RV_CHAN_1 41
+#define OMAP_DMA_CMT_APE_TX_CHAN_2 42
+#define OMAP_DMA_CMT_APE_RV_CHAN_2 43
+#define OMAP_DMA_CMT_APE_TX_CHAN_3 44
+#define OMAP_DMA_CMT_APE_RV_CHAN_3 45
+#define OMAP_DMA_CMT_APE_TX_CHAN_4 46
+#define OMAP_DMA_CMT_APE_RV_CHAN_4 47
+#define OMAP_DMA_CMT_APE_TX_CHAN_5 48
+#define OMAP_DMA_CMT_APE_RV_CHAN_5 49
+#define OMAP_DMA_CMT_APE_TX_CHAN_6 50
+#define OMAP_DMA_CMT_APE_RV_CHAN_6 51
+#define OMAP_DMA_CMT_APE_TX_CHAN_7 52
+#define OMAP_DMA_CMT_APE_RV_CHAN_7 53
+#define OMAP_DMA_MMC2_TX 54
+#define OMAP_DMA_MMC2_RX 55
+#define OMAP_DMA_CRYPTO_DES_OUT 56
+
+#define OMAP24XX_DMA_NO_DEVICE 0
+#define OMAP24XX_DMA_XTI_DMA 1
+#define OMAP24XX_DMA_EXT_DMAREQ0 2
+#define OMAP24XX_DMA_EXT_DMAREQ1 3
+#define OMAP24XX_DMA_GPMC 4
+#define OMAP24XX_DMA_GFX 5
+#define OMAP24XX_DMA_DSS 6
+#define OMAP24XX_DMA_VLYNQ_TX 7
+#define OMAP24XX_DMA_CWT 8
+#define OMAP24XX_DMA_AES_TX 9
+#define OMAP24XX_DMA_AES_RX 10
+#define OMAP24XX_DMA_DES_TX 11
+#define OMAP24XX_DMA_DES_RX 12
+#define OMAP24XX_DMA_SHA1MD5_RX 13
+#define OMAP24XX_DMA_EXT_DMAREQ2 14
+#define OMAP24XX_DMA_EXT_DMAREQ3 15
+#define OMAP24XX_DMA_EXT_DMAREQ4 16
+#define OMAP24XX_DMA_EAC_AC_RD 17
+#define OMAP24XX_DMA_EAC_AC_WR 18
+#define OMAP24XX_DMA_EAC_MD_UL_RD 19
+#define OMAP24XX_DMA_EAC_MD_UL_WR 20
+#define OMAP24XX_DMA_EAC_MD_DL_RD 21
+#define OMAP24XX_DMA_EAC_MD_DL_WR 22
+#define OMAP24XX_DMA_EAC_BT_UL_RD 23
+#define OMAP24XX_DMA_EAC_BT_UL_WR 24
+#define OMAP24XX_DMA_EAC_BT_DL_RD 25
+#define OMAP24XX_DMA_EAC_BT_DL_WR 26
+#define OMAP24XX_DMA_I2C1_TX 27
+#define OMAP24XX_DMA_I2C1_RX 28
+#define OMAP24XX_DMA_I2C2_TX 29
+#define OMAP24XX_DMA_I2C2_RX 30
+#define OMAP24XX_DMA_MCBSP1_TX 31
+#define OMAP24XX_DMA_MCBSP1_RX 32
+#define OMAP24XX_DMA_MCBSP2_TX 33
+#define OMAP24XX_DMA_MCBSP2_RX 34
+#define OMAP24XX_DMA_SPI1_TX0 35
+#define OMAP24XX_DMA_SPI1_RX0 36
+#define OMAP24XX_DMA_SPI1_TX1 37
+#define OMAP24XX_DMA_SPI1_RX1 38
+#define OMAP24XX_DMA_SPI1_TX2 39
+#define OMAP24XX_DMA_SPI1_RX2 40
+#define OMAP24XX_DMA_SPI1_TX3 41
+#define OMAP24XX_DMA_SPI1_RX3 42
+#define OMAP24XX_DMA_SPI2_TX0 43
+#define OMAP24XX_DMA_SPI2_RX0 44
+#define OMAP24XX_DMA_SPI2_TX1 45
+#define OMAP24XX_DMA_SPI2_RX1 46
+
+#define OMAP24XX_DMA_UART1_TX 49
+#define OMAP24XX_DMA_UART1_RX 50
+#define OMAP24XX_DMA_UART2_TX 51
+#define OMAP24XX_DMA_UART2_RX 52
+#define OMAP24XX_DMA_UART3_TX 53
+#define OMAP24XX_DMA_UART3_RX 54
+#define OMAP24XX_DMA_USB_W2FC_TX0 55
+#define OMAP24XX_DMA_USB_W2FC_RX0 56
+#define OMAP24XX_DMA_USB_W2FC_TX1 57
+#define OMAP24XX_DMA_USB_W2FC_RX1 58
+#define OMAP24XX_DMA_USB_W2FC_TX2 59
+#define OMAP24XX_DMA_USB_W2FC_RX2 60
+#define OMAP24XX_DMA_MMC1_TX 61
+#define OMAP24XX_DMA_MMC1_RX 62
+#define OMAP24XX_DMA_MS 63
+#define OMAP24XX_DMA_EXT_DMAREQ5 64
+
+#define OMAP1510_DMA_LCD_BASE (0xfffedb00)
+#define OMAP1510_DMA_LCD_CTRL (OMAP1510_DMA_LCD_BASE + 0x00)
+#define OMAP1510_DMA_LCD_TOP_F1_L (OMAP1510_DMA_LCD_BASE + 0x02)
+#define OMAP1510_DMA_LCD_TOP_F1_U (OMAP1510_DMA_LCD_BASE + 0x04)
+#define OMAP1510_DMA_LCD_BOT_F1_L (OMAP1510_DMA_LCD_BASE + 0x06)
+#define OMAP1510_DMA_LCD_BOT_F1_U (OMAP1510_DMA_LCD_BASE + 0x08)
+
+#define OMAP1610_DMA_LCD_BASE (0xfffee300)
+#define OMAP1610_DMA_LCD_CSDP (OMAP1610_DMA_LCD_BASE + 0xc0)
+#define OMAP1610_DMA_LCD_CCR (OMAP1610_DMA_LCD_BASE + 0xc2)
+#define OMAP1610_DMA_LCD_CTRL (OMAP1610_DMA_LCD_BASE + 0xc4)
+#define OMAP1610_DMA_LCD_TOP_B1_L (OMAP1610_DMA_LCD_BASE + 0xc8)
+#define OMAP1610_DMA_LCD_TOP_B1_U (OMAP1610_DMA_LCD_BASE + 0xca)
+#define OMAP1610_DMA_LCD_BOT_B1_L (OMAP1610_DMA_LCD_BASE + 0xcc)
+#define OMAP1610_DMA_LCD_BOT_B1_U (OMAP1610_DMA_LCD_BASE + 0xce)
+#define OMAP1610_DMA_LCD_TOP_B2_L (OMAP1610_DMA_LCD_BASE + 0xd0)
+#define OMAP1610_DMA_LCD_TOP_B2_U (OMAP1610_DMA_LCD_BASE + 0xd2)
+#define OMAP1610_DMA_LCD_BOT_B2_L (OMAP1610_DMA_LCD_BASE + 0xd4)
+#define OMAP1610_DMA_LCD_BOT_B2_U (OMAP1610_DMA_LCD_BASE + 0xd6)
+#define OMAP1610_DMA_LCD_SRC_EI_B1 (OMAP1610_DMA_LCD_BASE + 0xd8)
+#define OMAP1610_DMA_LCD_SRC_FI_B1_L (OMAP1610_DMA_LCD_BASE + 0xda)
+#define OMAP1610_DMA_LCD_SRC_EN_B1 (OMAP1610_DMA_LCD_BASE + 0xe0)
+#define OMAP1610_DMA_LCD_SRC_FN_B1 (OMAP1610_DMA_LCD_BASE + 0xe4)
+#define OMAP1610_DMA_LCD_LCH_CTRL (OMAP1610_DMA_LCD_BASE + 0xea)
+#define OMAP1610_DMA_LCD_SRC_FI_B1_U (OMAP1610_DMA_LCD_BASE + 0xf4)
+
+#define OMAP1_DMA_TOUT_IRQ (1 << 0)
+#define OMAP_DMA_DROP_IRQ (1 << 1)
+#define OMAP_DMA_HALF_IRQ (1 << 2)
+#define OMAP_DMA_FRAME_IRQ (1 << 3)
+#define OMAP_DMA_LAST_IRQ (1 << 4)
+#define OMAP_DMA_BLOCK_IRQ (1 << 5)
+#define OMAP1_DMA_SYNC_IRQ (1 << 6)
+#define OMAP2_DMA_PKT_IRQ (1 << 7)
+#define OMAP2_DMA_TRANS_ERR_IRQ (1 << 8)
+#define OMAP2_DMA_SECURE_ERR_IRQ (1 << 9)
+#define OMAP2_DMA_SUPERVISOR_ERR_IRQ (1 << 10)
+#define OMAP2_DMA_MISALIGNED_ERR_IRQ (1 << 11)
+
+#define OMAP_DMA_DATA_TYPE_S8 0x00
+#define OMAP_DMA_DATA_TYPE_S16 0x01
+#define OMAP_DMA_DATA_TYPE_S32 0x02
+
+#define OMAP_DMA_SYNC_ELEMENT 0x00
+#define OMAP_DMA_SYNC_FRAME 0x01
+#define OMAP_DMA_SYNC_BLOCK 0x02
+
+#define OMAP_DMA_PORT_EMIFF 0x00
+#define OMAP_DMA_PORT_EMIFS 0x01
+#define OMAP_DMA_PORT_OCP_T1 0x02
+#define OMAP_DMA_PORT_TIPB 0x03
+#define OMAP_DMA_PORT_OCP_T2 0x04
+#define OMAP_DMA_PORT_MPUI 0x05
+
+#define OMAP_DMA_AMODE_CONSTANT 0x00
+#define OMAP_DMA_AMODE_POST_INC 0x01
+#define OMAP_DMA_AMODE_SINGLE_IDX 0x02
+#define OMAP_DMA_AMODE_DOUBLE_IDX 0x03
+
+enum {
+ OMAP_LCD_DMA_B1_TOP,
+ OMAP_LCD_DMA_B1_BOTTOM,
+ OMAP_LCD_DMA_B2_TOP,
+ OMAP_LCD_DMA_B2_BOTTOM
+};
+
+enum omap_dma_burst_mode {
+ OMAP_DMA_DATA_BURST_DIS = 0,
+ OMAP_DMA_DATA_BURST_4,
+ OMAP_DMA_DATA_BURST_8,
+ OMAP_DMA_DATA_BURST_16,
+};
+
+enum omap_dma_color_mode {
+ OMAP_DMA_COLOR_DIS = 0,
+ OMAP_DMA_CONSTANT_FILL,
+ OMAP_DMA_TRANSPARENT_COPY
+};
+
+enum omap_dma_write_mode {
+ OMAP_DMA_WRITE_NON_POSTED = 0,
+ OMAP_DMA_WRITE_POSTED,
+ OMAP_DMA_WRITE_LAST_NON_POSTED
+};
+
+struct omap_dma_channel_params {
+ int data_type;
+ int elem_count;
+ int frame_count;
+
+ int src_port;
+ int src_amode;
+ unsigned long src_start;
+ int src_ei;
+ int src_fi;
+
+ int dst_port;
+ int dst_amode;
+ unsigned long dst_start;
+ int dst_ei;
+ int dst_fi;
+
+ int trigger;
+ int sync_mode;
+ int src_or_dst_synch;
+
+ int ie;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/fpga.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/fpga.h
new file mode 100644
index 000000000..a1b210dc7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/fpga.h
@@ -0,0 +1,160 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_FPGA_H
+#define __ASM_ARCH_OMAP_FPGA_H
+
+#define omap1510_fpga_init_irq() (0)
+
+#define fpga_read(reg) __raw_readb(reg)
+#define fpga_write(val, reg) __raw_writeb(val, reg)
+
+#define H2P2_DBG_FPGA_BASE 0xE8000000
+#define H2P2_DBG_FPGA_SIZE SZ_4K
+#define H2P2_DBG_FPGA_START 0x04000000
+
+#define H2P2_DBG_FPGA_ETHR_START (H2P2_DBG_FPGA_START + 0x300)
+#define H2P2_DBG_FPGA_FPGA_REV (H2P2_DBG_FPGA_BASE + 0x10)
+#define H2P2_DBG_FPGA_BOARD_REV (H2P2_DBG_FPGA_BASE + 0x12)
+#define H2P2_DBG_FPGA_GPIO (H2P2_DBG_FPGA_BASE + 0x14)
+#define H2P2_DBG_FPGA_LEDS (H2P2_DBG_FPGA_BASE + 0x16)
+#define H2P2_DBG_FPGA_MISC_INPUTS (H2P2_DBG_FPGA_BASE + 0x18)
+#define H2P2_DBG_FPGA_LAN_STATUS (H2P2_DBG_FPGA_BASE + 0x1A)
+#define H2P2_DBG_FPGA_LAN_RESET (H2P2_DBG_FPGA_BASE + 0x1C)
+
+struct h2p2_dbg_fpga {
+
+ u16 smc91x[8];
+
+ u16 fpga_rev;
+ u16 board_rev;
+ u16 gpio_outputs;
+ u16 leds;
+
+ u16 misc_inputs;
+ u16 lan_status;
+ u16 lan_reset;
+ u16 reserved0;
+
+ u16 ps2_data;
+ u16 ps2_ctrl;
+
+};
+
+#define H2P2_DBG_FPGA_LED_GREEN (1 << 15)
+#define H2P2_DBG_FPGA_LED_AMBER (1 << 14)
+#define H2P2_DBG_FPGA_LED_RED (1 << 13)
+#define H2P2_DBG_FPGA_LED_BLUE (1 << 12)
+
+#define H2P2_DBG_FPGA_LOAD_METER (1 << 0)
+#define H2P2_DBG_FPGA_LOAD_METER_SIZE 11
+#define H2P2_DBG_FPGA_LOAD_METER_MASK ((1 << H2P2_DBG_FPGA_LOAD_METER_SIZE) - 1)
+
+#define H2P2_DBG_FPGA_P2_LED_TIMER (1 << 0)
+#define H2P2_DBG_FPGA_P2_LED_IDLE (1 << 1)
+
+#define OMAP1510_FPGA_BASE 0xE8000000
+#define OMAP1510_FPGA_SIZE SZ_4K
+#define OMAP1510_FPGA_START 0x08000000
+
+#define OMAP1510_FPGA_REV_LOW (OMAP1510_FPGA_BASE + 0x0)
+#define OMAP1510_FPGA_REV_HIGH (OMAP1510_FPGA_BASE + 0x1)
+
+#define OMAP1510_FPGA_LCD_PANEL_CONTROL (OMAP1510_FPGA_BASE + 0x2)
+#define OMAP1510_FPGA_LED_DIGIT (OMAP1510_FPGA_BASE + 0x3)
+#define INNOVATOR_FPGA_HID_SPI (OMAP1510_FPGA_BASE + 0x4)
+#define OMAP1510_FPGA_POWER (OMAP1510_FPGA_BASE + 0x5)
+
+#define OMAP1510_FPGA_ISR_LO (OMAP1510_FPGA_BASE + 0x6)
+#define OMAP1510_FPGA_ISR_HI (OMAP1510_FPGA_BASE + 0x7)
+
+#define OMAP1510_FPGA_IMR_LO (OMAP1510_FPGA_BASE + 0x8)
+#define OMAP1510_FPGA_IMR_HI (OMAP1510_FPGA_BASE + 0x9)
+
+#define OMAP1510_FPGA_HOST_RESET (OMAP1510_FPGA_BASE + 0xa)
+#define OMAP1510_FPGA_RST (OMAP1510_FPGA_BASE + 0xb)
+
+#define OMAP1510_FPGA_AUDIO (OMAP1510_FPGA_BASE + 0xc)
+#define OMAP1510_FPGA_DIP (OMAP1510_FPGA_BASE + 0xe)
+#define OMAP1510_FPGA_FPGA_IO (OMAP1510_FPGA_BASE + 0xf)
+#define OMAP1510_FPGA_UART1 (OMAP1510_FPGA_BASE + 0x14)
+#define OMAP1510_FPGA_UART2 (OMAP1510_FPGA_BASE + 0x15)
+#define OMAP1510_FPGA_OMAP1510_STATUS (OMAP1510_FPGA_BASE + 0x16)
+#define OMAP1510_FPGA_BOARD_REV (OMAP1510_FPGA_BASE + 0x18)
+#define OMAP1510P1_PPT_DATA (OMAP1510_FPGA_BASE + 0x100)
+#define OMAP1510P1_PPT_STATUS (OMAP1510_FPGA_BASE + 0x101)
+#define OMAP1510P1_PPT_CONTROL (OMAP1510_FPGA_BASE + 0x102)
+
+#define OMAP1510_FPGA_TOUCHSCREEN (OMAP1510_FPGA_BASE + 0x204)
+
+#define INNOVATOR_FPGA_INFO (OMAP1510_FPGA_BASE + 0x205)
+#define INNOVATOR_FPGA_LCD_BRIGHT_LO (OMAP1510_FPGA_BASE + 0x206)
+#define INNOVATOR_FPGA_LCD_BRIGHT_HI (OMAP1510_FPGA_BASE + 0x207)
+#define INNOVATOR_FPGA_LED_GRN_LO (OMAP1510_FPGA_BASE + 0x208)
+#define INNOVATOR_FPGA_LED_GRN_HI (OMAP1510_FPGA_BASE + 0x209)
+#define INNOVATOR_FPGA_LED_RED_LO (OMAP1510_FPGA_BASE + 0x20a)
+#define INNOVATOR_FPGA_LED_RED_HI (OMAP1510_FPGA_BASE + 0x20b)
+#define INNOVATOR_FPGA_CAM_USB_CONTROL (OMAP1510_FPGA_BASE + 0x20c)
+#define INNOVATOR_FPGA_EXP_CONTROL (OMAP1510_FPGA_BASE + 0x20d)
+#define INNOVATOR_FPGA_ISR2 (OMAP1510_FPGA_BASE + 0x20e)
+#define INNOVATOR_FPGA_IMR2 (OMAP1510_FPGA_BASE + 0x210)
+
+#define OMAP1510_FPGA_ETHR_START (OMAP1510_FPGA_START + 0x300)
+
+#define OMAP1510_FPGA_RESET_VALUE 0x42
+
+#define OMAP1510_FPGA_PCR_IF_PD0 (1 << 7)
+#define OMAP1510_FPGA_PCR_COM2_EN (1 << 6)
+#define OMAP1510_FPGA_PCR_COM1_EN (1 << 5)
+#define OMAP1510_FPGA_PCR_EXP_PD0 (1 << 4)
+#define OMAP1510_FPGA_PCR_EXP_PD1 (1 << 3)
+#define OMAP1510_FPGA_PCR_48MHZ_CLK (1 << 2)
+#define OMAP1510_FPGA_PCR_4MHZ_CLK (1 << 1)
+#define OMAP1510_FPGA_PCR_RSRVD_BIT0 (1 << 0)
+
+#define OMAP1510_FPGA_HID_SCLK (1<<0)
+#define OMAP1510_FPGA_HID_MOSI (1<<1)
+#define OMAP1510_FPGA_HID_nSS (1<<2)
+#define OMAP1510_FPGA_HID_nHSUS (1<<3)
+#define OMAP1510_FPGA_HID_MISO (1<<4)
+#define OMAP1510_FPGA_HID_ATN (1<<5)
+#define OMAP1510_FPGA_HID_rsrvd (1<<6)
+#define OMAP1510_FPGA_HID_RESETn (1<<7)
+
+#define OMAP1510_INT_FPGA (IH_GPIO_BASE + 13)
+
+#define OMAP1510_IH_FPGA_BASE IH_BOARD_BASE
+#define OMAP1510_INT_FPGA_ATN (OMAP1510_IH_FPGA_BASE + 0)
+#define OMAP1510_INT_FPGA_ACK (OMAP1510_IH_FPGA_BASE + 1)
+#define OMAP1510_INT_FPGA2 (OMAP1510_IH_FPGA_BASE + 2)
+#define OMAP1510_INT_FPGA3 (OMAP1510_IH_FPGA_BASE + 3)
+#define OMAP1510_INT_FPGA4 (OMAP1510_IH_FPGA_BASE + 4)
+#define OMAP1510_INT_FPGA5 (OMAP1510_IH_FPGA_BASE + 5)
+#define OMAP1510_INT_FPGA6 (OMAP1510_IH_FPGA_BASE + 6)
+#define OMAP1510_INT_FPGA7 (OMAP1510_IH_FPGA_BASE + 7)
+#define OMAP1510_INT_FPGA8 (OMAP1510_IH_FPGA_BASE + 8)
+#define OMAP1510_INT_FPGA9 (OMAP1510_IH_FPGA_BASE + 9)
+#define OMAP1510_INT_FPGA10 (OMAP1510_IH_FPGA_BASE + 10)
+#define OMAP1510_INT_FPGA11 (OMAP1510_IH_FPGA_BASE + 11)
+#define OMAP1510_INT_FPGA12 (OMAP1510_IH_FPGA_BASE + 12)
+#define OMAP1510_INT_ETHER (OMAP1510_IH_FPGA_BASE + 13)
+#define OMAP1510_INT_FPGAUART1 (OMAP1510_IH_FPGA_BASE + 14)
+#define OMAP1510_INT_FPGAUART2 (OMAP1510_IH_FPGA_BASE + 15)
+#define OMAP1510_INT_FPGA_TS (OMAP1510_IH_FPGA_BASE + 16)
+#define OMAP1510_INT_FPGA17 (OMAP1510_IH_FPGA_BASE + 17)
+#define OMAP1510_INT_FPGA_CAM (OMAP1510_IH_FPGA_BASE + 18)
+#define OMAP1510_INT_FPGA_RTC_A (OMAP1510_IH_FPGA_BASE + 19)
+#define OMAP1510_INT_FPGA_RTC_B (OMAP1510_IH_FPGA_BASE + 20)
+#define OMAP1510_INT_FPGA_CD (OMAP1510_IH_FPGA_BASE + 21)
+#define OMAP1510_INT_FPGA22 (OMAP1510_IH_FPGA_BASE + 22)
+#define OMAP1510_INT_FPGA23 (OMAP1510_IH_FPGA_BASE + 23)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio-switch.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio-switch.h
new file mode 100644
index 000000000..20ea3f278
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio-switch.h
@@ -0,0 +1,37 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_GPIO_SWITCH_H
+#define __ASM_ARCH_OMAP_GPIO_SWITCH_H
+
+#include
+
+#define OMAP_GPIO_SWITCH_TYPE_COVER 0x0000
+#define OMAP_GPIO_SWITCH_TYPE_CONNECTION 0x0001
+#define OMAP_GPIO_SWITCH_TYPE_ACTIVITY 0x0002
+#define OMAP_GPIO_SWITCH_FLAG_INVERTED 0x0001
+#define OMAP_GPIO_SWITCH_FLAG_OUTPUT 0x0002
+
+struct omap_gpio_switch {
+ const char *name;
+ s16 gpio;
+ unsigned flags:4;
+ unsigned type:4;
+
+ u16 debounce_rising;
+
+ u16 debounce_falling;
+
+ void (* notify)(void *data, int state);
+ void *notify_data;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio.h
new file mode 100644
index 000000000..332246d7c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/gpio.h
@@ -0,0 +1,49 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_GPIO_H
+#define __ASM_ARCH_OMAP_GPIO_H
+
+#include
+#include
+#include
+
+#define OMAP_MPUIO_BASE (void __iomem *)0xfffb5000
+
+#define OMAP_MPUIO_INPUT_LATCH 0x00
+#define OMAP_MPUIO_OUTPUT 0x04
+#define OMAP_MPUIO_IO_CNTL 0x08
+#define OMAP_MPUIO_KBR_LATCH 0x10
+#define OMAP_MPUIO_KBC 0x14
+#define OMAP_MPUIO_GPIO_EVENT_MODE 0x18
+#define OMAP_MPUIO_GPIO_INT_EDGE 0x1c
+#define OMAP_MPUIO_KBD_INT 0x20
+#define OMAP_MPUIO_GPIO_INT 0x24
+#define OMAP_MPUIO_KBD_MASKIT 0x28
+#define OMAP_MPUIO_GPIO_MASKIT 0x2c
+#define OMAP_MPUIO_GPIO_DEBOUNCING 0x30
+#define OMAP_MPUIO_LATCH 0x34
+
+#define OMAP_MPUIO(nr) (OMAP_MAX_GPIO_LINES + (nr))
+#define OMAP_GPIO_IS_MPUIO(nr) ((nr) >= OMAP_MAX_GPIO_LINES)
+
+#define OMAP_GPIO_IRQ(nr) (OMAP_GPIO_IS_MPUIO(nr) ? IH_MPUIO_BASE + ((nr) & 0x0f) : IH_GPIO_BASE + (nr))
+
+struct omap_machine_gpio_bank {
+ int start;
+ int end;
+
+ void (*set_gpio_direction)(int gpio, int is_input);
+ void (*set_gpio_dataout)(int gpio, int enable);
+ int (*get_gpio_datain)(int gpio);
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/hardware.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/hardware.h
new file mode 100644
index 000000000..e515ee8eb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/hardware.h
@@ -0,0 +1,157 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_HARDWARE_H
+#define __ASM_ARCH_OMAP_HARDWARE_H
+
+#include
+#ifndef __ASSEMBLER__
+#include
+#include
+#endif
+#include
+#include
+
+#define OMAP_MPU_TIMER1_BASE (0xfffec500)
+#define OMAP_MPU_TIMER2_BASE (0xfffec600)
+#define OMAP_MPU_TIMER3_BASE (0xfffec700)
+#define MPU_TIMER_FREE (1 << 6)
+#define MPU_TIMER_CLOCK_ENABLE (1 << 5)
+#define MPU_TIMER_AR (1 << 1)
+#define MPU_TIMER_ST (1 << 0)
+
+#define CLKGEN_REG_BASE (0xfffece00)
+#define ARM_CKCTL (CLKGEN_REG_BASE + 0x0)
+#define ARM_IDLECT1 (CLKGEN_REG_BASE + 0x4)
+#define ARM_IDLECT2 (CLKGEN_REG_BASE + 0x8)
+#define ARM_EWUPCT (CLKGEN_REG_BASE + 0xC)
+#define ARM_RSTCT1 (CLKGEN_REG_BASE + 0x10)
+#define ARM_RSTCT2 (CLKGEN_REG_BASE + 0x14)
+#define ARM_SYSST (CLKGEN_REG_BASE + 0x18)
+#define ARM_IDLECT3 (CLKGEN_REG_BASE + 0x24)
+
+#define CK_RATEF 1
+#define CK_IDLEF 2
+#define CK_ENABLEF 4
+#define CK_SELECTF 8
+#define SETARM_IDLE_SHIFT
+
+#define DPLL_CTL (0xfffecf00)
+
+#define DSP_CONFIG_REG_BASE (0xe1008000)
+#define DSP_CKCTL (DSP_CONFIG_REG_BASE + 0x0)
+#define DSP_IDLECT1 (DSP_CONFIG_REG_BASE + 0x4)
+#define DSP_IDLECT2 (DSP_CONFIG_REG_BASE + 0x8)
+#define DSP_RSTCT2 (DSP_CONFIG_REG_BASE + 0x14)
+
+#define ULPD_REG_BASE (0xfffe0800)
+#define ULPD_IT_STATUS (ULPD_REG_BASE + 0x14)
+#define ULPD_SETUP_ANALOG_CELL_3 (ULPD_REG_BASE + 0x24)
+#define ULPD_CLOCK_CTRL (ULPD_REG_BASE + 0x30)
+#define DIS_USB_PVCI_CLK (1 << 5)
+#define USB_MCLK_EN (1 << 4)
+#define ULPD_SOFT_REQ (ULPD_REG_BASE + 0x34)
+#define SOFT_UDC_REQ (1 << 4)
+#define SOFT_USB_CLK_REQ (1 << 3)
+#define SOFT_DPLL_REQ (1 << 0)
+#define ULPD_DPLL_CTRL (ULPD_REG_BASE + 0x3c)
+#define ULPD_STATUS_REQ (ULPD_REG_BASE + 0x40)
+#define ULPD_APLL_CTRL (ULPD_REG_BASE + 0x4c)
+#define ULPD_POWER_CTRL (ULPD_REG_BASE + 0x50)
+#define ULPD_SOFT_DISABLE_REQ_REG (ULPD_REG_BASE + 0x68)
+#define DIS_MMC2_DPLL_REQ (1 << 11)
+#define DIS_MMC1_DPLL_REQ (1 << 10)
+#define DIS_UART3_DPLL_REQ (1 << 9)
+#define DIS_UART2_DPLL_REQ (1 << 8)
+#define DIS_UART1_DPLL_REQ (1 << 7)
+#define DIS_USB_HOST_DPLL_REQ (1 << 6)
+#define ULPD_SDW_CLK_DIV_CTRL_SEL (ULPD_REG_BASE + 0x74)
+#define ULPD_CAM_CLK_CTRL (ULPD_REG_BASE + 0x7c)
+
+#define OMAP_MPU_WATCHDOG_BASE (0xfffec800)
+#define OMAP_WDT_TIMER (OMAP_MPU_WATCHDOG_BASE + 0x0)
+#define OMAP_WDT_LOAD_TIM (OMAP_MPU_WATCHDOG_BASE + 0x4)
+#define OMAP_WDT_READ_TIM (OMAP_MPU_WATCHDOG_BASE + 0x4)
+#define OMAP_WDT_TIMER_MODE (OMAP_MPU_WATCHDOG_BASE + 0x8)
+
+#define MOD_CONF_CTRL_0 0xfffe1080
+#define MOD_CONF_CTRL_1 0xfffe1110
+
+#define FUNC_MUX_CTRL_0 0xfffe1000
+#define FUNC_MUX_CTRL_1 0xfffe1004
+#define FUNC_MUX_CTRL_2 0xfffe1008
+#define COMP_MODE_CTRL_0 0xfffe100c
+#define FUNC_MUX_CTRL_3 0xfffe1010
+#define FUNC_MUX_CTRL_4 0xfffe1014
+#define FUNC_MUX_CTRL_5 0xfffe1018
+#define FUNC_MUX_CTRL_6 0xfffe101C
+#define FUNC_MUX_CTRL_7 0xfffe1020
+#define FUNC_MUX_CTRL_8 0xfffe1024
+#define FUNC_MUX_CTRL_9 0xfffe1028
+#define FUNC_MUX_CTRL_A 0xfffe102C
+#define FUNC_MUX_CTRL_B 0xfffe1030
+#define FUNC_MUX_CTRL_C 0xfffe1034
+#define FUNC_MUX_CTRL_D 0xfffe1038
+#define PULL_DWN_CTRL_0 0xfffe1040
+#define PULL_DWN_CTRL_1 0xfffe1044
+#define PULL_DWN_CTRL_2 0xfffe1048
+#define PULL_DWN_CTRL_3 0xfffe104c
+#define PULL_DWN_CTRL_4 0xfffe10ac
+
+#define FUNC_MUX_CTRL_E 0xfffe1090
+#define FUNC_MUX_CTRL_F 0xfffe1094
+#define FUNC_MUX_CTRL_10 0xfffe1098
+#define FUNC_MUX_CTRL_11 0xfffe109c
+#define FUNC_MUX_CTRL_12 0xfffe10a0
+#define PU_PD_SEL_0 0xfffe10b4
+#define PU_PD_SEL_1 0xfffe10b8
+#define PU_PD_SEL_2 0xfffe10bc
+#define PU_PD_SEL_3 0xfffe10c0
+#define PU_PD_SEL_4 0xfffe10c4
+
+#define OMAP_TIMER32K_BASE 0xFFFBC400
+
+#define TIPB_PUBLIC_CNTL_BASE 0xfffed300
+#define MPU_PUBLIC_TIPB_CNTL (TIPB_PUBLIC_CNTL_BASE + 0x8)
+#define TIPB_PRIVATE_CNTL_BASE 0xfffeca00
+#define MPU_PRIVATE_TIPB_CNTL (TIPB_PRIVATE_CNTL_BASE + 0x8)
+
+#define MPUI_BASE (0xfffec900)
+#define MPUI_CTRL (MPUI_BASE + 0x0)
+#define MPUI_DEBUG_ADDR (MPUI_BASE + 0x4)
+#define MPUI_DEBUG_DATA (MPUI_BASE + 0x8)
+#define MPUI_DEBUG_FLAG (MPUI_BASE + 0xc)
+#define MPUI_STATUS_REG (MPUI_BASE + 0x10)
+#define MPUI_DSP_STATUS (MPUI_BASE + 0x14)
+#define MPUI_DSP_BOOT_CONFIG (MPUI_BASE + 0x18)
+#define MPUI_DSP_API_CONFIG (MPUI_BASE + 0x1c)
+
+#define OMAP_LPG1_BASE 0xfffbd000
+#define OMAP_LPG2_BASE 0xfffbd800
+#define OMAP_LPG1_LCR (OMAP_LPG1_BASE + 0x00)
+#define OMAP_LPG1_PMR (OMAP_LPG1_BASE + 0x04)
+#define OMAP_LPG2_LCR (OMAP_LPG2_BASE + 0x00)
+#define OMAP_LPG2_PMR (OMAP_LPG2_BASE + 0x04)
+
+#define OMAP_PWL_BASE 0xfffb5800
+#define OMAP_PWL_ENABLE (OMAP_PWL_BASE + 0x00)
+#define OMAP_PWL_CLK_ENABLE (OMAP_PWL_BASE + 0x04)
+
+#include "omap730.h"
+#include "omap1510.h"
+#include "omap24xx.h"
+#include "omap16xx.h"
+
+#ifndef __ASSEMBLER__
+
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/io.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/io.h
new file mode 100644
index 000000000..12ac3d41a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/io.h
@@ -0,0 +1,54 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_ARCH_IO_H
+#define __ASM_ARM_ARCH_IO_H
+
+#include
+
+#define IO_SPACE_LIMIT 0xffffffff
+
+#define __io(a) ((void __iomem *)(PCIO_BASE + (a)))
+#define __mem_pci(a) (a)
+
+#define PCIO_BASE 0
+
+#ifndef __ASSEMBLER__
+
+#define omap_readb(a) (*(volatile unsigned char *)IO_ADDRESS(a))
+#define omap_readw(a) (*(volatile unsigned short *)IO_ADDRESS(a))
+#define omap_readl(a) (*(volatile unsigned int *)IO_ADDRESS(a))
+
+#define omap_writeb(v,a) (*(volatile unsigned char *)IO_ADDRESS(a) = (v))
+#define omap_writew(v,a) (*(volatile unsigned short *)IO_ADDRESS(a) = (v))
+#define omap_writel(v,a) (*(volatile unsigned int *)IO_ADDRESS(a) = (v))
+
+typedef struct { volatile u16 offset[256]; } __regbase16;
+#define __REGV16(vaddr) ((__regbase16 *)((vaddr)&~0xff)) ->offset[((vaddr)&0xff)>>1]
+#define __REG16(paddr) __REGV16(io_p2v(paddr))
+
+typedef struct { volatile u8 offset[4096]; } __regbase8;
+#define __REGV8(vaddr) ((__regbase8 *)((vaddr)&~4095)) ->offset[((vaddr)&4095)>>0]
+#define __REG8(paddr) __REGV8(io_p2v(paddr))
+
+typedef struct { volatile u32 offset[4096]; } __regbase32;
+#define __REGV32(vaddr) ((__regbase32 *)((vaddr)&~4095)) ->offset[((vaddr)&4095)>>2]
+#define __REG32(paddr) __REGV32(io_p2v(paddr))
+
+#else
+
+#define __REG8(paddr) io_p2v(paddr)
+#define __REG16(paddr) io_p2v(paddr)
+#define __REG32(paddr) io_p2v(paddr)
+
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/irqs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/irqs.h
new file mode 100644
index 000000000..3e9448735
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/irqs.h
@@ -0,0 +1,242 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP15XX_IRQS_H
+#define __ASM_ARCH_OMAP15XX_IRQS_H
+
+#define INT_CAMERA 1
+#define INT_FIQ 3
+#define INT_RTDX 6
+#define INT_DSP_MMU_ABORT 7
+#define INT_HOST 8
+#define INT_ABORT 9
+#define INT_DSP_MAILBOX1 10
+#define INT_DSP_MAILBOX2 11
+#define INT_BRIDGE_PRIV 13
+#define INT_GPIO_BANK1 14
+#define INT_UART3 15
+#define INT_TIMER3 16
+#define INT_DMA_CH0_6 19
+#define INT_DMA_CH1_7 20
+#define INT_DMA_CH2_8 21
+#define INT_DMA_CH3 22
+#define INT_DMA_CH4 23
+#define INT_DMA_CH5 24
+#define INT_DMA_LCD 25
+#define INT_TIMER1 26
+#define INT_WD_TIMER 27
+#define INT_BRIDGE_PUB 28
+#define INT_TIMER2 30
+#define INT_LCD_CTRL 31
+
+#define INT_1510_IH2_IRQ 0
+#define INT_1510_RES2 2
+#define INT_1510_SPI_TX 4
+#define INT_1510_SPI_RX 5
+#define INT_1510_RES12 12
+#define INT_1510_LB_MMU 17
+#define INT_1510_RES18 18
+#define INT_1510_LOCAL_BUS 29
+
+#define INT_1610_IH2_IRQ 0
+#define INT_1610_IH2_FIQ 2
+#define INT_1610_McBSP2_TX 4
+#define INT_1610_McBSP2_RX 5
+#define INT_1610_LCD_LINE 12
+#define INT_1610_GPTIMER1 17
+#define INT_1610_GPTIMER2 18
+#define INT_1610_SSR_FIFO_0 29
+
+#define INT_730_IH2_FIQ 0
+#define INT_730_IH2_IRQ 1
+#define INT_730_USB_NON_ISO 2
+#define INT_730_USB_ISO 3
+#define INT_730_ICR 4
+#define INT_730_EAC 5
+#define INT_730_GPIO_BANK1 6
+#define INT_730_GPIO_BANK2 7
+#define INT_730_GPIO_BANK3 8
+#define INT_730_McBSP2TX 10
+#define INT_730_McBSP2RX 11
+#define INT_730_McBSP2RX_OVF 12
+#define INT_730_LCD_LINE 14
+#define INT_730_GSM_PROTECT 15
+#define INT_730_TIMER3 16
+#define INT_730_GPIO_BANK5 17
+#define INT_730_GPIO_BANK6 18
+#define INT_730_SPGIO_WR 29
+
+#define IH2_BASE 32
+
+#define INT_KEYBOARD (1 + IH2_BASE)
+#define INT_uWireTX (2 + IH2_BASE)
+#define INT_uWireRX (3 + IH2_BASE)
+#define INT_I2C (4 + IH2_BASE)
+#define INT_MPUIO (5 + IH2_BASE)
+#define INT_USB_HHC_1 (6 + IH2_BASE)
+#define INT_McBSP3TX (10 + IH2_BASE)
+#define INT_McBSP3RX (11 + IH2_BASE)
+#define INT_McBSP1TX (12 + IH2_BASE)
+#define INT_McBSP1RX (13 + IH2_BASE)
+#define INT_UART2 (14 + IH2_BASE)
+#define INT_UART1 (15 + IH2_BASE)
+#define INT_BT_MCSI1TX (16 + IH2_BASE)
+#define INT_BT_MCSI1RX (17 + IH2_BASE)
+#define INT_USB_W2FC (20 + IH2_BASE)
+#define INT_1WIRE (21 + IH2_BASE)
+#define INT_OS_TIMER (22 + IH2_BASE)
+#define INT_MMC (23 + IH2_BASE)
+#define INT_GAUGE_32K (24 + IH2_BASE)
+#define INT_RTC_TIMER (25 + IH2_BASE)
+#define INT_RTC_ALARM (26 + IH2_BASE)
+#define INT_MEM_STICK (27 + IH2_BASE)
+#define INT_DSP_MMU (28 + IH2_BASE)
+
+#define INT_1510_COM_SPI_RO (31 + IH2_BASE)
+
+#define INT_1610_FAC (0 + IH2_BASE)
+#define INT_1610_USB_HHC_2 (7 + IH2_BASE)
+#define INT_1610_USB_OTG (8 + IH2_BASE)
+#define INT_1610_SoSSI (9 + IH2_BASE)
+#define INT_1610_SoSSI_MATCH (19 + IH2_BASE)
+#define INT_1610_McBSP2RX_OF (31 + IH2_BASE)
+#define INT_1610_STI (32 + IH2_BASE)
+#define INT_1610_STI_WAKEUP (33 + IH2_BASE)
+#define INT_1610_GPTIMER3 (34 + IH2_BASE)
+#define INT_1610_GPTIMER4 (35 + IH2_BASE)
+#define INT_1610_GPTIMER5 (36 + IH2_BASE)
+#define INT_1610_GPTIMER6 (37 + IH2_BASE)
+#define INT_1610_GPTIMER7 (38 + IH2_BASE)
+#define INT_1610_GPTIMER8 (39 + IH2_BASE)
+#define INT_1610_GPIO_BANK2 (40 + IH2_BASE)
+#define INT_1610_GPIO_BANK3 (41 + IH2_BASE)
+#define INT_1610_MMC2 (42 + IH2_BASE)
+#define INT_1610_CF (43 + IH2_BASE)
+#define INT_1610_WAKE_UP_REQ (46 + IH2_BASE)
+#define INT_1610_GPIO_BANK4 (48 + IH2_BASE)
+#define INT_1610_SPI (49 + IH2_BASE)
+#define INT_1610_DMA_CH6 (53 + IH2_BASE)
+#define INT_1610_DMA_CH7 (54 + IH2_BASE)
+#define INT_1610_DMA_CH8 (55 + IH2_BASE)
+#define INT_1610_DMA_CH9 (56 + IH2_BASE)
+#define INT_1610_DMA_CH10 (57 + IH2_BASE)
+#define INT_1610_DMA_CH11 (58 + IH2_BASE)
+#define INT_1610_DMA_CH12 (59 + IH2_BASE)
+#define INT_1610_DMA_CH13 (60 + IH2_BASE)
+#define INT_1610_DMA_CH14 (61 + IH2_BASE)
+#define INT_1610_DMA_CH15 (62 + IH2_BASE)
+#define INT_1610_NAND (63 + IH2_BASE)
+
+#define INT_730_HW_ERRORS (0 + IH2_BASE)
+#define INT_730_NFIQ_PWR_FAIL (1 + IH2_BASE)
+#define INT_730_CFCD (2 + IH2_BASE)
+#define INT_730_CFIREQ (3 + IH2_BASE)
+#define INT_730_I2C (4 + IH2_BASE)
+#define INT_730_PCC (5 + IH2_BASE)
+#define INT_730_MPU_EXT_NIRQ (6 + IH2_BASE)
+#define INT_730_SPI_100K_1 (7 + IH2_BASE)
+#define INT_730_SYREN_SPI (8 + IH2_BASE)
+#define INT_730_VLYNQ (9 + IH2_BASE)
+#define INT_730_GPIO_BANK4 (10 + IH2_BASE)
+#define INT_730_McBSP1TX (11 + IH2_BASE)
+#define INT_730_McBSP1RX (12 + IH2_BASE)
+#define INT_730_McBSP1RX_OF (13 + IH2_BASE)
+#define INT_730_UART_MODEM_IRDA_2 (14 + IH2_BASE)
+#define INT_730_UART_MODEM_1 (15 + IH2_BASE)
+#define INT_730_MCSI (16 + IH2_BASE)
+#define INT_730_uWireTX (17 + IH2_BASE)
+#define INT_730_uWireRX (18 + IH2_BASE)
+#define INT_730_SMC_CD (19 + IH2_BASE)
+#define INT_730_SMC_IREQ (20 + IH2_BASE)
+#define INT_730_HDQ_1WIRE (21 + IH2_BASE)
+#define INT_730_TIMER32K (22 + IH2_BASE)
+#define INT_730_MMC_SDIO (23 + IH2_BASE)
+#define INT_730_UPLD (24 + IH2_BASE)
+#define INT_730_USB_HHC_1 (27 + IH2_BASE)
+#define INT_730_USB_HHC_2 (28 + IH2_BASE)
+#define INT_730_USB_GENI (29 + IH2_BASE)
+#define INT_730_USB_OTG (30 + IH2_BASE)
+#define INT_730_CAMERA_IF (31 + IH2_BASE)
+#define INT_730_RNG (32 + IH2_BASE)
+#define INT_730_DUAL_MODE_TIMER (33 + IH2_BASE)
+#define INT_730_DBB_RF_EN (34 + IH2_BASE)
+#define INT_730_MPUIO_KEYPAD (35 + IH2_BASE)
+#define INT_730_SHA1_MD5 (36 + IH2_BASE)
+#define INT_730_SPI_100K_2 (37 + IH2_BASE)
+#define INT_730_RNG_IDLE (38 + IH2_BASE)
+#define INT_730_MPUIO (39 + IH2_BASE)
+#define INT_730_LLPC_LCD_CTRL_CAN_BE_OFF (40 + IH2_BASE)
+#define INT_730_LLPC_OE_FALLING (41 + IH2_BASE)
+#define INT_730_LLPC_OE_RISING (42 + IH2_BASE)
+#define INT_730_LLPC_VSYNC (43 + IH2_BASE)
+#define INT_730_WAKE_UP_REQ (46 + IH2_BASE)
+#define INT_730_DMA_CH6 (53 + IH2_BASE)
+#define INT_730_DMA_CH7 (54 + IH2_BASE)
+#define INT_730_DMA_CH8 (55 + IH2_BASE)
+#define INT_730_DMA_CH9 (56 + IH2_BASE)
+#define INT_730_DMA_CH10 (57 + IH2_BASE)
+#define INT_730_DMA_CH11 (58 + IH2_BASE)
+#define INT_730_DMA_CH12 (59 + IH2_BASE)
+#define INT_730_DMA_CH13 (60 + IH2_BASE)
+#define INT_730_DMA_CH14 (61 + IH2_BASE)
+#define INT_730_DMA_CH15 (62 + IH2_BASE)
+#define INT_730_NAND (63 + IH2_BASE)
+
+#define INT_24XX_SYS_NIRQ 7
+#define INT_24XX_SDMA_IRQ0 12
+#define INT_24XX_SDMA_IRQ1 13
+#define INT_24XX_SDMA_IRQ2 14
+#define INT_24XX_SDMA_IRQ3 15
+#define INT_24XX_CAM_IRQ 24
+#define INT_24XX_DSS_IRQ 25
+#define INT_24XX_GPIO_BANK1 29
+#define INT_24XX_GPIO_BANK2 30
+#define INT_24XX_GPIO_BANK3 31
+#define INT_24XX_GPIO_BANK4 32
+#define INT_24XX_GPTIMER1 37
+#define INT_24XX_GPTIMER2 38
+#define INT_24XX_GPTIMER3 39
+#define INT_24XX_GPTIMER4 40
+#define INT_24XX_GPTIMER5 41
+#define INT_24XX_GPTIMER6 42
+#define INT_24XX_GPTIMER7 43
+#define INT_24XX_GPTIMER8 44
+#define INT_24XX_GPTIMER9 45
+#define INT_24XX_GPTIMER10 46
+#define INT_24XX_GPTIMER11 47
+#define INT_24XX_GPTIMER12 48
+#define INT_24XX_MCBSP1_IRQ_TX 59
+#define INT_24XX_MCBSP1_IRQ_RX 60
+#define INT_24XX_MCBSP2_IRQ_TX 62
+#define INT_24XX_MCBSP2_IRQ_RX 63
+#define INT_24XX_UART1_IRQ 72
+#define INT_24XX_UART2_IRQ 73
+#define INT_24XX_UART3_IRQ 74
+#define INT_24XX_MMC_IRQ 83
+
+#define OMAP_MAX_GPIO_LINES 192
+#define IH_GPIO_BASE (128 + IH2_BASE)
+#define IH_MPUIO_BASE (OMAP_MAX_GPIO_LINES + IH_GPIO_BASE)
+#define IH_BOARD_BASE (16 + IH_MPUIO_BASE)
+
+#define OMAP_IRQ_BIT(irq) (1 << ((irq) % 32))
+
+#ifndef __ASSEMBLY__
+
+#endif
+
+#include
+
+#ifndef NR_IRQS
+#define NR_IRQS IH_BOARD_BASE
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mcbsp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mcbsp.h
new file mode 100644
index 000000000..cae5e3b3e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mcbsp.h
@@ -0,0 +1,185 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_MCBSP_H
+#define __ASM_ARCH_OMAP_MCBSP_H
+
+#include
+
+#define OMAP730_MCBSP1_BASE 0xfffb1000
+#define OMAP730_MCBSP2_BASE 0xfffb1800
+
+#define OMAP1510_MCBSP1_BASE 0xe1011800
+#define OMAP1510_MCBSP2_BASE 0xfffb1000
+#define OMAP1510_MCBSP3_BASE 0xe1017000
+
+#define OMAP1610_MCBSP1_BASE 0xe1011800
+#define OMAP1610_MCBSP2_BASE 0xfffb1000
+#define OMAP1610_MCBSP3_BASE 0xe1017000
+
+#define OMAP24XX_MCBSP1_BASE 0x48074000
+#define OMAP24XX_MCBSP2_BASE 0x48076000
+
+#define OMAP_MCBSP_READ(base, reg) __raw_readw((base) + OMAP_MCBSP_REG_##reg)
+#define OMAP_MCBSP_WRITE(base, reg, val) __raw_writew((val), (base) + OMAP_MCBSP_REG_##reg)
+
+#define RRST 0x0001
+#define RRDY 0x0002
+#define RFULL 0x0004
+#define RSYNC_ERR 0x0008
+#define RINTM(value) ((value)<<4)
+#define ABIS 0x0040
+#define DXENA 0x0080
+#define CLKSTP(value) ((value)<<11)
+#define RJUST(value) ((value)<<13)
+#define DLB 0x8000
+
+#define XRST 0x0001
+#define XRDY 0x0002
+#define XEMPTY 0x0004
+#define XSYNC_ERR 0x0008
+#define XINTM(value) ((value)<<4)
+#define GRST 0x0040
+#define FRST 0x0080
+#define SOFT 0x0100
+#define FREE 0x0200
+
+#define CLKRP 0x0001
+#define CLKXP 0x0002
+#define FSRP 0x0004
+#define FSXP 0x0008
+#define DR_STAT 0x0010
+#define DX_STAT 0x0020
+#define CLKS_STAT 0x0040
+#define SCLKME 0x0080
+#define CLKRM 0x0100
+#define CLKXM 0x0200
+#define FSRM 0x0400
+#define FSXM 0x0800
+#define RIOEN 0x1000
+#define XIOEN 0x2000
+#define IDLE_EN 0x4000
+
+#define RWDLEN1(value) ((value)<<5)
+#define RFRLEN1(value) ((value)<<8)
+
+#define XWDLEN1(value) ((value)<<5)
+#define XFRLEN1(value) ((value)<<8)
+
+#define RDATDLY(value) (value)
+#define RFIG 0x0004
+#define RCOMPAND(value) ((value)<<3)
+#define RWDLEN2(value) ((value)<<5)
+#define RFRLEN2(value) ((value)<<8)
+#define RPHASE 0x8000
+
+#define XDATDLY(value) (value)
+#define XFIG 0x0004
+#define XCOMPAND(value) ((value)<<3)
+#define XWDLEN2(value) ((value)<<5)
+#define XFRLEN2(value) ((value)<<8)
+#define XPHASE 0x8000
+
+#define CLKGDV(value) (value)
+#define FWID(value) ((value)<<8)
+
+#define FPER(value) (value)
+#define FSGM 0x1000
+#define CLKSM 0x2000
+#define CLKSP 0x4000
+#define GSYNC 0x8000
+
+#define RMCM 0x0001
+#define RCBLK(value) ((value)<<2)
+#define RPABLK(value) ((value)<<5)
+#define RPBBLK(value) ((value)<<7)
+
+#define XMCM(value) (value)
+#define XCBLK(value) ((value)<<2)
+#define XPABLK(value) ((value)<<5)
+#define XPBBLK(value) ((value)<<7)
+
+struct omap_mcbsp_reg_cfg {
+ u16 spcr2;
+ u16 spcr1;
+ u16 rcr2;
+ u16 rcr1;
+ u16 xcr2;
+ u16 xcr1;
+ u16 srgr2;
+ u16 srgr1;
+ u16 mcr2;
+ u16 mcr1;
+ u16 pcr0;
+ u16 rcerc;
+ u16 rcerd;
+ u16 xcerc;
+ u16 xcerd;
+ u16 rcere;
+ u16 rcerf;
+ u16 xcere;
+ u16 xcerf;
+ u16 rcerg;
+ u16 rcerh;
+ u16 xcerg;
+ u16 xcerh;
+};
+
+typedef enum {
+ OMAP_MCBSP1 = 0,
+ OMAP_MCBSP2,
+ OMAP_MCBSP3,
+} omap_mcbsp_id;
+
+typedef int __bitwise omap_mcbsp_io_type_t;
+#define OMAP_MCBSP_IRQ_IO ((__force omap_mcbsp_io_type_t) 1)
+#define OMAP_MCBSP_POLL_IO ((__force omap_mcbsp_io_type_t) 2)
+
+typedef enum {
+ OMAP_MCBSP_WORD_8 = 0,
+ OMAP_MCBSP_WORD_12,
+ OMAP_MCBSP_WORD_16,
+ OMAP_MCBSP_WORD_20,
+ OMAP_MCBSP_WORD_24,
+ OMAP_MCBSP_WORD_32,
+} omap_mcbsp_word_length;
+
+typedef enum {
+ OMAP_MCBSP_CLK_RISING = 0,
+ OMAP_MCBSP_CLK_FALLING,
+} omap_mcbsp_clk_polarity;
+
+typedef enum {
+ OMAP_MCBSP_FS_ACTIVE_HIGH = 0,
+ OMAP_MCBSP_FS_ACTIVE_LOW,
+} omap_mcbsp_fs_polarity;
+
+typedef enum {
+ OMAP_MCBSP_CLK_STP_MODE_NO_DELAY = 0,
+ OMAP_MCBSP_CLK_STP_MODE_DELAY,
+} omap_mcbsp_clk_stp_mode;
+
+typedef enum {
+ OMAP_MCBSP_SPI_MASTER = 0,
+ OMAP_MCBSP_SPI_SLAVE,
+} omap_mcbsp_spi_mode;
+
+struct omap_mcbsp_spi_cfg {
+ omap_mcbsp_spi_mode spi_mode;
+ omap_mcbsp_clk_polarity rx_clock_polarity;
+ omap_mcbsp_clk_polarity tx_clock_polarity;
+ omap_mcbsp_fs_polarity fsx_polarity;
+ u8 clk_div;
+ omap_mcbsp_clk_stp_mode clk_stp_mode;
+ omap_mcbsp_word_length word_length;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/memory.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/memory.h
new file mode 100644
index 000000000..8b064b80e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/memory.h
@@ -0,0 +1,19 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_MEMORY_H
+#define __ASM_ARCH_MEMORY_H
+
+#define __virt_to_bus(x) __virt_to_phys(x)
+#define __bus_to_virt(x) __phys_to_virt(x)
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mtd-xip.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mtd-xip.h
new file mode 100644
index 000000000..9b60aefc6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mtd-xip.h
@@ -0,0 +1,31 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARCH_OMAP_MTD_XIP_H__
+#define __ARCH_OMAP_MTD_XIP_H__
+
+#include
+#define OMAP_MPU_TIMER_BASE (0xfffec500)
+#define OMAP_MPU_TIMER_OFFSET 0x100
+
+typedef struct {
+ u32 cntl;
+ u32 load_tim;
+ u32 read_tim;
+} xip_omap_mpu_timer_regs_t;
+
+#define xip_omap_mpu_timer_base(n) ((volatile xip_omap_mpu_timer_regs_t*)IO_ADDRESS(OMAP_MPU_TIMER_BASE + (n)*OMAP_MPU_TIMER_OFFSET))
+
+#define xip_irqpending() (omap_readl(OMAP_IH1_ITR) & ~omap_readl(OMAP_IH1_MIR))
+#define xip_currtime() (~xip_omap_mpu_timer_read(0))
+#define xip_elapsed_since(x) (signed)((~xip_omap_mpu_timer_read(0) - (x)) / 6)
+#define xip_cpu_idle() asm volatile ("mcr p15, 0, %0, c7, c0, 4" :: "r" (1))
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mux.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mux.h
new file mode 100644
index 000000000..72da54e60
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/mux.h
@@ -0,0 +1,391 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_MUX_H
+#define __ASM_ARCH_MUX_H
+
+#define PU_PD_SEL_NA 0
+#define PULL_DWN_CTRL_NA 0
+
+#define MUX_REG(reg, mode_offset, mode) .mux_reg = FUNC_MUX_CTRL_##reg, .mask_offset = mode_offset, .mask = mode,
+
+#define PULL_REG(reg, bit, status) .pull_reg = PULL_DWN_CTRL_##reg, .pull_bit = bit, .pull_val = status,
+
+#define PU_PD_REG(reg, status) .pu_pd_reg = PU_PD_SEL_##reg, .pu_pd_val = status,
+
+#define MUX_REG_730(reg, mode_offset, mode) .mux_reg = OMAP730_IO_CONF_##reg, .mask_offset = mode_offset, .mask = mode,
+
+#define PULL_REG_730(reg, bit, status) .pull_reg = OMAP730_IO_CONF_##reg, .pull_bit = bit, .pull_val = status,
+
+#define MUX_CFG(desc, mux_reg, mode_offset, mode, pull_reg, pull_bit, pull_status, pu_pd_reg, pu_pd_status, debug_status) { .name = desc, .debug = debug_status, MUX_REG(mux_reg, mode_offset, mode) PULL_REG(pull_reg, pull_bit, !pull_status) PU_PD_REG(pu_pd_reg, pu_pd_status) },
+
+#define MUX_CFG_730(desc, mux_reg, mode_offset, mode, pull_bit, pull_status, debug_status) { .name = desc, .debug = debug_status, MUX_REG_730(mux_reg, mode_offset, mode) PULL_REG_730(mux_reg, pull_bit, pull_status) PU_PD_REG(NA, 0) },
+
+#define MUX_CFG_24XX(desc, reg_offset, mode, pull_en, pull_mode, dbg) { .name = desc, .debug = dbg, .mux_reg = reg_offset, .mask = mode, .pull_val = pull_en, .pu_pd_val = pull_mode, },
+
+#define PULL_DISABLED 0
+#define PULL_ENABLED 1
+
+#define PULL_DOWN 0
+#define PULL_UP 1
+
+struct pin_config {
+ char *name;
+ unsigned char busy;
+ unsigned char debug;
+
+ const char *mux_reg_name;
+ const unsigned int mux_reg;
+ const unsigned char mask_offset;
+ const unsigned char mask;
+
+ const char *pull_name;
+ const unsigned int pull_reg;
+ const unsigned char pull_val;
+ const unsigned char pull_bit;
+
+ const char *pu_pd_name;
+ const unsigned int pu_pd_reg;
+ const unsigned char pu_pd_val;
+};
+
+enum omap730_index {
+
+ E2_730_KBR0,
+ J7_730_KBR1,
+ E1_730_KBR2,
+ F3_730_KBR3,
+ D2_730_KBR4,
+ AA20_730_KBR5,
+ V17_730_KBR6,
+ C2_730_KBC0,
+ D3_730_KBC1,
+ E4_730_KBC2,
+ F4_730_KBC3,
+ E3_730_KBC4,
+
+ AA17_730_USB_DM,
+ W16_730_USB_PU_EN,
+ W17_730_USB_VBUSI,
+
+ V19_730_GPIO_15,
+ M19_730_GPIO_77,
+ C21_730_GPIO_121_122,
+ K19_730_GPIO_126,
+ K15_730_GPIO_127,
+
+ P15_730_GPIO_16_17,
+
+ M15_730_GPIO_83,
+ N20_730_GPIO_82,
+ N18_730_GPIO_81,
+ N19_730_GPIO_80,
+ L15_730_GPIO_76,
+
+ UART1_CTS_RTS,
+ OMAP_730_GPIOS_42_43,
+ UART1_TX_RX,
+ OMAP_730_GPIOS_40_41,
+ UART1_USB_RX_TX,
+ UART1_USB_RTS,
+ UART1_USB_CTS
+};
+
+enum omap1xxx_index {
+
+ UART1_TX = 0,
+ UART1_RTS,
+
+ UART2_TX,
+ UART2_RX,
+ UART2_CTS,
+ UART2_RTS,
+
+ UART3_TX,
+ UART3_RX,
+ UART3_CTS,
+ UART3_RTS,
+ UART3_CLKREQ,
+ UART3_BCLK,
+ Y15_1610_UART3_RTS,
+
+ PWT,
+ PWL,
+
+ R18_USB_VBUS,
+ R18_1510_USB_GPIO0,
+ W4_USB_PUEN,
+ W4_USB_CLKO,
+ W4_USB_HIGHZ,
+ W4_GPIO58,
+
+ USB1_SUSP,
+ USB1_SEO,
+ W13_1610_USB1_SE0,
+ USB1_TXEN,
+ USB1_TXD,
+ USB1_VP,
+ USB1_VM,
+ USB1_RCV,
+ USB1_SPEED,
+ R13_1610_USB1_SPEED,
+ R13_1710_USB1_SE0,
+
+ USB2_SUSP,
+ USB2_VP,
+ USB2_TXEN,
+ USB2_VM,
+ USB2_RCV,
+ USB2_SEO,
+ USB2_TXD,
+
+ R18_1510_GPIO0,
+ R19_1510_GPIO1,
+ M14_1510_GPIO2,
+
+ P18_1610_GPIO3,
+ Y15_1610_GPIO17,
+
+ R18_1710_GPIO0,
+ V2_1710_GPIO10,
+ N21_1710_GPIO14,
+ W15_1710_GPIO40,
+
+ MPUIO2,
+ N15_1610_MPUIO2,
+ MPUIO4,
+ MPUIO5,
+ T20_1610_MPUIO5,
+ W11_1610_MPUIO6,
+ V10_1610_MPUIO7,
+ W11_1610_MPUIO9,
+ V10_1610_MPUIO10,
+ W10_1610_MPUIO11,
+ E20_1610_MPUIO13,
+ U20_1610_MPUIO14,
+ E19_1610_MPUIO15,
+
+ MCBSP2_CLKR,
+ MCBSP2_CLKX,
+ MCBSP2_DR,
+ MCBSP2_DX,
+ MCBSP2_FSR,
+ MCBSP2_FSX,
+
+ MCBSP3_CLKX,
+
+ BALLOUT_V8_ARMIO3,
+ N20_HDQ,
+
+ W8_1610_MMC2_DAT0,
+ V8_1610_MMC2_DAT1,
+ W15_1610_MMC2_DAT2,
+ R10_1610_MMC2_DAT3,
+ Y10_1610_MMC2_CLK,
+ Y8_1610_MMC2_CMD,
+ V9_1610_MMC2_CMDDIR,
+ V5_1610_MMC2_DATDIR0,
+ W19_1610_MMC2_DATDIR1,
+ R18_1610_MMC2_CLKIN,
+
+ M19_1610_ETM_PSTAT0,
+ L15_1610_ETM_PSTAT1,
+ L18_1610_ETM_PSTAT2,
+ L19_1610_ETM_D0,
+ J19_1610_ETM_D6,
+ J18_1610_ETM_D7,
+
+ P20_1610_GPIO4,
+ V9_1610_GPIO7,
+ W8_1610_GPIO9,
+ N20_1610_GPIO11,
+ N19_1610_GPIO13,
+ P10_1610_GPIO22,
+ V5_1610_GPIO24,
+ AA20_1610_GPIO_41,
+ W19_1610_GPIO48,
+ M7_1610_GPIO62,
+ V14_16XX_GPIO37,
+ R9_16XX_GPIO18,
+ L14_16XX_GPIO49,
+
+ V19_1610_UWIRE_SCLK,
+ U18_1610_UWIRE_SDI,
+ W21_1610_UWIRE_SDO,
+ N14_1610_UWIRE_CS0,
+ P15_1610_UWIRE_CS3,
+ N15_1610_UWIRE_CS1,
+
+ U19_1610_SPIF_SCK,
+ U18_1610_SPIF_DIN,
+ P20_1610_SPIF_DIN,
+ W21_1610_SPIF_DOUT,
+ R18_1610_SPIF_DOUT,
+ N14_1610_SPIF_CS0,
+ N15_1610_SPIF_CS1,
+ T19_1610_SPIF_CS2,
+ P15_1610_SPIF_CS3,
+
+ L3_1610_FLASH_CS2B_OE,
+ M8_1610_FLASH_CS2B_WE,
+
+ MMC_CMD,
+ MMC_DAT1,
+ MMC_DAT2,
+ MMC_DAT0,
+ MMC_CLK,
+ MMC_DAT3,
+
+ M15_1710_MMC_CLKI,
+ P19_1710_MMC_CMDDIR,
+ P20_1710_MMC_DATDIR0,
+
+ W9_USB0_TXEN,
+ AA9_USB0_VP,
+ Y5_USB0_RCV,
+ R9_USB0_VM,
+ V6_USB0_TXD,
+ W5_USB0_SE0,
+ V9_USB0_SPEED,
+ V9_USB0_SUSP,
+
+ W9_USB2_TXEN,
+ AA9_USB2_VP,
+ Y5_USB2_RCV,
+ R9_USB2_VM,
+ V6_USB2_TXD,
+ W5_USB2_SE0,
+
+ R13_1610_UART1_TX,
+ V14_16XX_UART1_RX,
+ R14_1610_UART1_CTS,
+ AA15_1610_UART1_RTS,
+ R9_16XX_UART2_RX,
+ L14_16XX_UART3_RX,
+
+ I2C_SCL,
+ I2C_SDA,
+
+ F18_1610_KBC0,
+ D20_1610_KBC1,
+ D19_1610_KBC2,
+ E18_1610_KBC3,
+ C21_1610_KBC4,
+ G18_1610_KBR0,
+ F19_1610_KBR1,
+ H14_1610_KBR2,
+ E20_1610_KBR3,
+ E19_1610_KBR4,
+ N19_1610_KBR5,
+
+ T20_1610_LOW_PWR,
+
+ V5_1710_MCLK_ON,
+ V5_1710_MCLK_OFF,
+ R10_1610_MCLK_ON,
+ R10_1610_MCLK_OFF,
+
+ P11_1610_CF_CD2,
+ R11_1610_CF_IOIS16,
+ V10_1610_CF_IREQ,
+ W10_1610_CF_RESET,
+ W11_1610_CF_CD1,
+};
+
+enum omap24xx_index {
+
+ M19_24XX_I2C1_SCL,
+ L15_24XX_I2C1_SDA,
+ J15_24XX_I2C2_SCL,
+ H19_24XX_I2C2_SDA,
+
+ W19_24XX_SYS_NIRQ,
+
+ W14_24XX_SYS_CLKOUT,
+
+ L3_GPMC_WAIT0,
+ N7_GPMC_WAIT1,
+ M1_GPMC_WAIT2,
+ P1_GPMC_WAIT3,
+
+ Y15_24XX_MCBSP2_CLKX,
+ R14_24XX_MCBSP2_FSX,
+ W15_24XX_MCBSP2_DR,
+ V15_24XX_MCBSP2_DX,
+
+ M21_242X_GPIO11,
+ AA10_242X_GPIO13,
+ AA6_242X_GPIO14,
+ AA4_242X_GPIO15,
+ Y11_242X_GPIO16,
+ AA12_242X_GPIO17,
+ AA8_242X_GPIO58,
+ Y20_24XX_GPIO60,
+ W4__24XX_GPIO74,
+ M15_24XX_GPIO92,
+ V14_24XX_GPIO117,
+
+ V4_242X_GPIO49,
+ W2_242X_GPIO50,
+ U4_242X_GPIO51,
+ V3_242X_GPIO52,
+ V2_242X_GPIO53,
+ V6_242X_GPIO53,
+ T4_242X_GPIO54,
+ Y4_242X_GPIO54,
+ T3_242X_GPIO55,
+ U2_242X_GPIO56,
+
+ AA10_242X_DMAREQ0,
+ AA6_242X_DMAREQ1,
+ E4_242X_DMAREQ2,
+ G4_242X_DMAREQ3,
+ D3_242X_DMAREQ4,
+ E3_242X_DMAREQ5,
+
+ P20_24XX_TSC_IRQ,
+
+ K15_24XX_UART3_TX,
+ K14_24XX_UART3_RX,
+
+ G19_24XX_MMC_CLKO,
+ H18_24XX_MMC_CMD,
+ F20_24XX_MMC_DAT0,
+ H14_24XX_MMC_DAT1,
+ E19_24XX_MMC_DAT2,
+ D19_24XX_MMC_DAT3,
+ F19_24XX_MMC_DAT_DIR0,
+ E20_24XX_MMC_DAT_DIR1,
+ F18_24XX_MMC_DAT_DIR2,
+ E18_24XX_MMC_DAT_DIR3,
+ G18_24XX_MMC_CMD_DIR,
+ H15_24XX_MMC_CLKI,
+
+ T19_24XX_KBR0,
+ R19_24XX_KBR1,
+ V18_24XX_KBR2,
+ M21_24XX_KBR3,
+ E5__24XX_KBR4,
+ M18_24XX_KBR5,
+ R20_24XX_KBC0,
+ M14_24XX_KBC1,
+ H19_24XX_KBC2,
+ V17_24XX_KBC3,
+ P21_24XX_KBC4,
+ L14_24XX_KBC5,
+ N19_24XX_KBC6,
+
+ B3__24XX_KBR5,
+ AA4_24XX_KBC2,
+ B13_24XX_KBC6,
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/omap24xx.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/omap24xx.h
new file mode 100644
index 000000000..37def2fa9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/omap24xx.h
@@ -0,0 +1,30 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP24XX_H
+#define __ASM_ARCH_OMAP24XX_H
+
+#define L4_24XX_BASE 0x48000000
+#define L3_24XX_BASE 0x68000000
+
+#define OMAP24XX_IC_BASE (L4_24XX_BASE + 0xfe000)
+#define VA_IC_BASE IO_ADDRESS(OMAP24XX_IC_BASE)
+#define OMAP24XX_IVA_INTC_BASE 0x40000000
+#define IRQ_SIR_IRQ 0x0040
+
+#define OMAP24XX_32KSYNCT_BASE (L4_24XX_BASE + 0x4000)
+#define OMAP24XX_PRCM_BASE (L4_24XX_BASE + 0x8000)
+#define OMAP24XX_SDRC_BASE (L3_24XX_BASE + 0x9000)
+
+#define OMAP242X_CONTROL_STATUS (L4_24XX_BASE + 0x2f8)
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/serial.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/serial.h
new file mode 100644
index 000000000..6ab86135d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/serial.h
@@ -0,0 +1,21 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_SERIAL_H
+#define __ASM_ARCH_SERIAL_H
+
+#define OMAP_MAX_NR_PORTS 3
+#define OMAP1510_BASE_BAUD (12000000/16)
+#define OMAP16XX_BASE_BAUD (48000000/16)
+
+#define is_omap_port(p) ({int __ret = 0; if (p == IO_ADDRESS(OMAP_UART1_BASE) || p == IO_ADDRESS(OMAP_UART2_BASE) || p == IO_ADDRESS(OMAP_UART3_BASE)) __ret = 1; __ret; })
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/timex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/timex.h
new file mode 100644
index 000000000..2c9234c7b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/timex.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARCH_OMAP_TIMEX_H
+#define __ASM_ARCH_OMAP_TIMEX_H
+
+#define CLOCK_TICK_RATE (HZ * 100000UL)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/vmalloc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/vmalloc.h
new file mode 100644
index 000000000..f2b5b4479
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/arch/vmalloc.h
@@ -0,0 +1,13 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#define VMALLOC_END (PAGE_OFFSET + 0x10000000)
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/atomic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/atomic.h
new file mode 100644
index 000000000..6f1921afb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/atomic.h
@@ -0,0 +1,21 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_ATOMIC_H
+#define __ASM_ARM_ATOMIC_H
+
+#include
+
+typedef struct { volatile int counter; } atomic_t;
+
+#define ATOMIC_INIT(i) { (i) }
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/auxvec.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/auxvec.h
new file mode 100644
index 000000000..c7e839cb7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/auxvec.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_AUXVEC_H
+#define __ASMARM_AUXVEC_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/bitops.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/bitops.h
new file mode 100644
index 000000000..ff76a68df
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/bitops.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_BITOPS_H
+#define __ASM_ARM_BITOPS_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/byteorder.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/byteorder.h
new file mode 100644
index 000000000..4da37bf8e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/byteorder.h
@@ -0,0 +1,51 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_BYTEORDER_H
+#define __ASM_ARM_BYTEORDER_H
+
+#include
+#include
+
+static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
+{
+ __u32 t;
+
+#ifndef __thumb__
+ if (!__builtin_constant_p(x)) {
+
+ asm ("eor\t%0, %1, %1, ror #16" : "=r" (t) : "r" (x));
+ } else
+#endif
+ t = x ^ ((x << 16) | (x >> 16));
+
+ x = (x << 24) | (x >> 8);
+ t &= ~0x00FF0000;
+ x ^= (t >> 8);
+
+ return x;
+}
+
+#define __arch__swab32(x) ___arch__swab32(x)
+
+#ifndef __STRICT_ANSI__
+#define __BYTEORDER_HAS_U64__
+#define __SWAB_64_THRU_32__
+#endif
+
+#ifdef __ARMEB__
+#include
+#else
+#include
+#endif
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cache.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cache.h
new file mode 100644
index 000000000..be2642330
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cache.h
@@ -0,0 +1,18 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_CACHE_H
+#define __ASMARM_CACHE_H
+
+#define L1_CACHE_SHIFT 5
+#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cacheflush.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cacheflush.h
new file mode 100644
index 000000000..3ffa87a1b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cacheflush.h
@@ -0,0 +1,107 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_CACHEFLUSH_H
+#define _ASMARM_CACHEFLUSH_H
+
+#include
+#include
+
+#include
+#include
+
+#define CACHE_COLOUR(vaddr) ((vaddr & (SHMLBA - 1)) >> PAGE_SHIFT)
+
+#undef _CACHE
+#undef MULTI_CACHE
+
+#if !defined(_CACHE) && !defined(MULTI_CACHE)
+#error Unknown cache maintainence model
+#endif
+
+#define PG_dcache_dirty PG_arch_1
+
+struct cpu_cache_fns {
+ void (*flush_kern_all)(void);
+ void (*flush_user_all)(void);
+ void (*flush_user_range)(unsigned long, unsigned long, unsigned int);
+
+ void (*coherent_kern_range)(unsigned long, unsigned long);
+ void (*coherent_user_range)(unsigned long, unsigned long);
+ void (*flush_kern_dcache_page)(void *);
+
+ void (*dma_inv_range)(unsigned long, unsigned long);
+ void (*dma_clean_range)(unsigned long, unsigned long);
+ void (*dma_flush_range)(unsigned long, unsigned long);
+};
+
+#ifdef MULTI_CACHE
+
+#define __cpuc_flush_kern_all cpu_cache.flush_kern_all
+#define __cpuc_flush_user_all cpu_cache.flush_user_all
+#define __cpuc_flush_user_range cpu_cache.flush_user_range
+#define __cpuc_coherent_kern_range cpu_cache.coherent_kern_range
+#define __cpuc_coherent_user_range cpu_cache.coherent_user_range
+#define __cpuc_flush_dcache_page cpu_cache.flush_kern_dcache_page
+
+#define dmac_inv_range cpu_cache.dma_inv_range
+#define dmac_clean_range cpu_cache.dma_clean_range
+#define dmac_flush_range cpu_cache.dma_flush_range
+
+#else
+
+#define __cpuc_flush_kern_all __glue(_CACHE,_flush_kern_cache_all)
+#define __cpuc_flush_user_all __glue(_CACHE,_flush_user_cache_all)
+#define __cpuc_flush_user_range __glue(_CACHE,_flush_user_cache_range)
+#define __cpuc_coherent_kern_range __glue(_CACHE,_coherent_kern_range)
+#define __cpuc_coherent_user_range __glue(_CACHE,_coherent_user_range)
+#define __cpuc_flush_dcache_page __glue(_CACHE,_flush_kern_dcache_page)
+
+#define dmac_inv_range __glue(_CACHE,_dma_inv_range)
+#define dmac_clean_range __glue(_CACHE,_dma_clean_range)
+#define dmac_flush_range __glue(_CACHE,_dma_flush_range)
+
+#endif
+
+#define flush_cache_vmap(start, end) flush_cache_all()
+#define flush_cache_vunmap(start, end) flush_cache_all()
+
+#define copy_to_user_page(vma, page, vaddr, dst, src, len) do { memcpy(dst, src, len); flush_ptrace_access(vma, page, vaddr, dst, len, 1); } while (0)
+
+#define copy_from_user_page(vma, page, vaddr, dst, src, len) do { memcpy(dst, src, len); } while (0)
+
+#define flush_cache_all() __cpuc_flush_kern_all()
+#define flush_cache_user_range(vma,start,end) __cpuc_coherent_user_range((start) & PAGE_MASK, PAGE_ALIGN(end))
+#define flush_icache_range(s,e) __cpuc_coherent_kern_range(s,e)
+#define clean_dcache_area(start,size) cpu_dcache_clean_area(start, size)
+
+#define flush_dcache_mmap_lock(mapping) write_lock_irq(&(mapping)->tree_lock)
+#define flush_dcache_mmap_unlock(mapping) write_unlock_irq(&(mapping)->tree_lock)
+
+#define flush_icache_user_range(vma,page,addr,len) flush_dcache_page(page)
+
+#define flush_icache_page(vma,page) do { } while (0)
+
+#define __cacheid_present(val) (val != read_cpuid(CPUID_ID))
+#define __cacheid_vivt(val) ((val & (15 << 25)) != (14 << 25))
+#define __cacheid_vipt(val) ((val & (15 << 25)) == (14 << 25))
+#define __cacheid_vipt_nonaliasing(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25))
+#define __cacheid_vipt_aliasing(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25 | 1 << 23))
+
+#define cache_is_vivt() ({ unsigned int __val = read_cpuid(CPUID_CACHETYPE); (!__cacheid_present(__val)) || __cacheid_vivt(__val); })
+
+#define cache_is_vipt() ({ unsigned int __val = read_cpuid(CPUID_CACHETYPE); __cacheid_present(__val) && __cacheid_vipt(__val); })
+
+#define cache_is_vipt_nonaliasing() ({ unsigned int __val = read_cpuid(CPUID_CACHETYPE); __cacheid_present(__val) && __cacheid_vipt_nonaliasing(__val); })
+
+#define cache_is_vipt_aliasing() ({ unsigned int __val = read_cpuid(CPUID_CACHETYPE); __cacheid_present(__val) && __cacheid_vipt_aliasing(__val); })
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cputime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cputime.h
new file mode 100644
index 000000000..4a4097fe8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/cputime.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARM_CPUTIME_H
+#define __ARM_CPUTIME_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/delay.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/delay.h
new file mode 100644
index 000000000..631fd9bad
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/delay.h
@@ -0,0 +1,22 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_DELAY_H
+#define __ASM_ARM_DELAY_H
+
+#include
+
+#define MAX_UDELAY_MS 2
+
+#define udelay(n) (__builtin_constant_p(n) ? ((n) > (MAX_UDELAY_MS * 1000) ? __bad_udelay() : __const_udelay((n) * ((2199023U*HZ)>>11))) : __udelay(n))
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/div64.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/div64.h
new file mode 100644
index 000000000..c03a0e47a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/div64.h
@@ -0,0 +1,27 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_DIV64
+#define __ASM_ARM_DIV64
+
+#include
+
+#ifdef __ARMEB__
+#define __xh "r0"
+#define __xl "r1"
+#else
+#define __xl "r0"
+#define __xh "r1"
+#endif
+
+#define do_div(n,base) ({ register unsigned int __base asm("r4") = base; register unsigned long long __n asm("r0") = n; register unsigned long long __res asm("r2"); register unsigned int __rem asm(__xh); asm( __asmeq("%0", __xh) __asmeq("%1", "r2") __asmeq("%2", "r0") __asmeq("%3", "r4") "bl __do_div64" : "=r" (__rem), "=r" (__res) : "r" (__n), "r" (__base) : "ip", "lr", "cc"); n = __res; __rem; })
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma-mapping.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma-mapping.h
new file mode 100644
index 000000000..7e65009ba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma-mapping.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef ASMARM_DMA_MAPPING_H
+#define ASMARM_DMA_MAPPING_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma.h
new file mode 100644
index 000000000..7eeeb780b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dma.h
@@ -0,0 +1,45 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_DMA_H
+#define __ASM_ARM_DMA_H
+
+typedef unsigned int dmach_t;
+
+#include
+#include
+#include
+#include
+
+#ifndef MAX_DMA_ADDRESS
+#define MAX_DMA_ADDRESS 0xffffffff
+#endif
+
+typedef unsigned int dmamode_t;
+
+#define DMA_MODE_MASK 3
+
+#define DMA_MODE_READ 0
+#define DMA_MODE_WRITE 1
+#define DMA_MODE_CASCADE 2
+#define DMA_AUTOINIT 4
+
+#define clear_dma_ff(channel)
+
+#define set_dma_addr(channel, addr) __set_dma_addr(channel, bus_to_virt(addr))
+
+#ifndef NO_DMA
+#define NO_DMA 255
+#endif
+
+#define isa_dma_bridge_buggy (0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/domain.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/domain.h
new file mode 100644
index 000000000..973109e5b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/domain.h
@@ -0,0 +1,32 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_PROC_DOMAIN_H
+#define __ASM_PROC_DOMAIN_H
+
+#define DOMAIN_KERNEL 0
+#define DOMAIN_TABLE 0
+#define DOMAIN_USER 1
+#define DOMAIN_IO 2
+
+#define DOMAIN_NOACCESS 0
+#define DOMAIN_CLIENT 1
+#define DOMAIN_MANAGER 3
+
+#define domain_val(dom,type) ((type) << (2*(dom)))
+
+#ifndef __ASSEMBLY__
+
+#define set_domain(x) do { } while (0)
+#define modify_domain(dom,type) do { } while (0)
+
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dyntick.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dyntick.h
new file mode 100644
index 000000000..1f323f2d8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/dyntick.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_DYNTICK_H
+#define _ASMARM_DYNTICK_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/elf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/elf.h
new file mode 100644
index 000000000..e9d095e6c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/elf.h
@@ -0,0 +1,63 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_ELF_H
+#define __ASMARM_ELF_H
+
+#include
+#include
+#ifdef __KERNEL
+#include
+#endif
+
+typedef unsigned long elf_greg_t;
+typedef unsigned long elf_freg_t[3];
+
+#define EM_ARM 40
+#define EF_ARM_APCS26 0x08
+#define EF_ARM_SOFT_FLOAT 0x200
+#define EF_ARM_EABI_MASK 0xFF000000
+
+#define R_ARM_NONE 0
+#define R_ARM_PC24 1
+#define R_ARM_ABS32 2
+#define R_ARM_CALL 28
+#define R_ARM_JUMP24 29
+
+#define ELF_NGREG (sizeof (struct pt_regs) / sizeof(elf_greg_t))
+typedef elf_greg_t elf_gregset_t[ELF_NGREG];
+
+typedef struct user_fp elf_fpregset_t;
+
+#define elf_check_arch(x) ( ((x)->e_machine == EM_ARM) && (ELF_PROC_OK((x))) )
+
+#define ELF_CLASS ELFCLASS32
+#ifdef __ARMEB__
+#define ELF_DATA ELFDATA2MSB
+#else
+#define ELF_DATA ELFDATA2LSB
+#endif
+#define ELF_ARCH EM_ARM
+
+#define USE_ELF_CORE_DUMP
+#define ELF_EXEC_PAGESIZE 4096
+
+#define ELF_ET_DYN_BASE (2 * TASK_SIZE / 3)
+
+#define ELF_PLAT_INIT(_r, load_addr) (_r)->ARM_r0 = 0
+
+#define ELF_HWCAP (elf_hwcap)
+
+#define ELF_PLATFORM_SIZE 8
+
+#define ELF_PLATFORM (elf_platform)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/errno.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/errno.h
new file mode 100644
index 000000000..6be70488e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/errno.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ARM_ERRNO_H
+#define _ARM_ERRNO_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fcntl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fcntl.h
new file mode 100644
index 000000000..42351eae3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fcntl.h
@@ -0,0 +1,22 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ARM_FCNTL_H
+#define _ARM_FCNTL_H
+
+#define O_DIRECTORY 040000
+#define O_NOFOLLOW 0100000
+#define O_DIRECT 0200000
+#define O_LARGEFILE 0400000
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fpstate.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fpstate.h
new file mode 100644
index 000000000..b362b1494
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/fpstate.h
@@ -0,0 +1,68 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_FPSTATE_H
+#define __ASM_ARM_FPSTATE_H
+
+#ifndef __ASSEMBLY__
+
+struct vfp_hard_struct {
+ __u64 fpregs[16];
+#if __LINUX_ARM_ARCH__ < 6
+ __u32 fpmx_state;
+#endif
+ __u32 fpexc;
+ __u32 fpscr;
+
+ __u32 fpinst;
+ __u32 fpinst2;
+};
+
+union vfp_state {
+ struct vfp_hard_struct hard;
+};
+
+#define FP_HARD_SIZE 35
+
+struct fp_hard_struct {
+ unsigned int save[FP_HARD_SIZE];
+};
+
+#define FP_SOFT_SIZE 35
+
+struct fp_soft_struct {
+ unsigned int save[FP_SOFT_SIZE];
+};
+
+#define IWMMXT_SIZE 0x98
+
+struct iwmmxt_struct {
+ unsigned int save[IWMMXT_SIZE / sizeof(unsigned int)];
+};
+
+union fp_state {
+ struct fp_hard_struct hard;
+ struct fp_soft_struct soft;
+};
+
+#define FP_SIZE (sizeof(union fp_state) / sizeof(int))
+
+struct crunch_state {
+ unsigned int mvdx[16][2];
+ unsigned int mvax[4][3];
+ unsigned int dspsc[2];
+};
+
+#define CRUNCH_SIZE sizeof(struct crunch_state)
+
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/glue.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/glue.h
new file mode 100644
index 000000000..1327b59d8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/glue.h
@@ -0,0 +1,11 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardirq.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardirq.h
new file mode 100644
index 000000000..54207e325
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardirq.h
@@ -0,0 +1,38 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_HARDIRQ_H
+#define __ASM_HARDIRQ_H
+
+#include
+#include
+#include
+
+typedef struct {
+ unsigned int __softirq_pending;
+ unsigned int local_timer_irqs;
+} ____cacheline_aligned irq_cpustat_t;
+
+#include
+
+#if NR_IRQS > 256
+#define HARDIRQ_BITS 9
+#else
+#define HARDIRQ_BITS 8
+#endif
+
+#if 1 << HARDIRQ_BITS < NR_IRQS
+#error HARDIRQ_BITS is too low!
+#endif
+
+#define __ARCH_IRQ_EXIT_IRQS_DISABLED 1
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardware.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardware.h
new file mode 100644
index 000000000..0b381d14e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hardware.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_HARDWARE_H
+#define __ASM_HARDWARE_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hw_irq.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hw_irq.h
new file mode 100644
index 000000000..a34b3902e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/hw_irq.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ARCH_ARM_HW_IRQ_H
+#define _ARCH_ARM_HW_IRQ_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ide.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ide.h
new file mode 100644
index 000000000..f52d5ca50
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ide.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_IDE_H
+#define __ASMARM_IDE_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/io.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/io.h
new file mode 100644
index 000000000..6794022dc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/io.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_IO_H
+#define __ASM_ARM_IO_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctl.h
new file mode 100644
index 000000000..6e446b6f6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctl.h
@@ -0,0 +1,12 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#include
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctls.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctls.h
new file mode 100644
index 000000000..9df82bc2a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ioctls.h
@@ -0,0 +1,88 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_IOCTLS_H
+#define __ASM_ARM_IOCTLS_H
+
+#include
+
+#define TCGETS 0x5401
+#define TCSETS 0x5402
+#define TCSETSW 0x5403
+#define TCSETSF 0x5404
+#define TCGETA 0x5405
+#define TCSETA 0x5406
+#define TCSETAW 0x5407
+#define TCSETAF 0x5408
+#define TCSBRK 0x5409
+#define TCXONC 0x540A
+#define TCFLSH 0x540B
+#define TIOCEXCL 0x540C
+#define TIOCNXCL 0x540D
+#define TIOCSCTTY 0x540E
+#define TIOCGPGRP 0x540F
+#define TIOCSPGRP 0x5410
+#define TIOCOUTQ 0x5411
+#define TIOCSTI 0x5412
+#define TIOCGWINSZ 0x5413
+#define TIOCSWINSZ 0x5414
+#define TIOCMGET 0x5415
+#define TIOCMBIS 0x5416
+#define TIOCMBIC 0x5417
+#define TIOCMSET 0x5418
+#define TIOCGSOFTCAR 0x5419
+#define TIOCSSOFTCAR 0x541A
+#define FIONREAD 0x541B
+#define TIOCINQ FIONREAD
+#define TIOCLINUX 0x541C
+#define TIOCCONS 0x541D
+#define TIOCGSERIAL 0x541E
+#define TIOCSSERIAL 0x541F
+#define TIOCPKT 0x5420
+#define FIONBIO 0x5421
+#define TIOCNOTTY 0x5422
+#define TIOCSETD 0x5423
+#define TIOCGETD 0x5424
+#define TCSBRKP 0x5425
+#define TIOCSBRK 0x5427
+#define TIOCCBRK 0x5428
+#define TIOCGSID 0x5429
+#define TIOCGPTN _IOR('T',0x30, unsigned int)
+#define TIOCSPTLCK _IOW('T',0x31, int)
+
+#define FIONCLEX 0x5450
+#define FIOCLEX 0x5451
+#define FIOASYNC 0x5452
+#define TIOCSERCONFIG 0x5453
+#define TIOCSERGWILD 0x5454
+#define TIOCSERSWILD 0x5455
+#define TIOCGLCKTRMIOS 0x5456
+#define TIOCSLCKTRMIOS 0x5457
+#define TIOCSERGSTRUCT 0x5458
+#define TIOCSERGETLSR 0x5459
+#define TIOCSERGETMULTI 0x545A
+#define TIOCSERSETMULTI 0x545B
+
+#define TIOCMIWAIT 0x545C
+#define TIOCGICOUNT 0x545D
+#define FIOQSIZE 0x545E
+
+#define TIOCPKT_DATA 0
+#define TIOCPKT_FLUSHREAD 1
+#define TIOCPKT_FLUSHWRITE 2
+#define TIOCPKT_STOP 4
+#define TIOCPKT_START 8
+#define TIOCPKT_NOSTOP 16
+#define TIOCPKT_DOSTOP 32
+
+#define TIOCSER_TEMT 0x01
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ipcbuf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ipcbuf.h
new file mode 100644
index 000000000..0e4750779
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ipcbuf.h
@@ -0,0 +1,30 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_IPCBUF_H
+#define __ASMARM_IPCBUF_H
+
+struct ipc64_perm
+{
+ __kernel_key_t key;
+ __kernel_uid32_t uid;
+ __kernel_gid32_t gid;
+ __kernel_uid32_t cuid;
+ __kernel_gid32_t cgid;
+ __kernel_mode_t mode;
+ unsigned short __pad1;
+ unsigned short seq;
+ unsigned short __pad2;
+ unsigned long __unused1;
+ unsigned long __unused2;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/irq.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/irq.h
new file mode 100644
index 000000000..2085a2148
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/irq.h
@@ -0,0 +1,45 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_IRQ_H
+#define __ASM_ARM_IRQ_H
+
+#include
+
+#ifndef irq_canonicalize
+#define irq_canonicalize(i) (i)
+#endif
+
+#ifndef NR_IRQS
+#define NR_IRQS 128
+#endif
+
+#ifndef NO_IRQ
+#define NO_IRQ ((unsigned int)(-1))
+#endif
+
+struct irqaction;
+
+#define __IRQT_FALEDGE IRQ_TYPE_EDGE_FALLING
+#define __IRQT_RISEDGE IRQ_TYPE_EDGE_RISING
+#define __IRQT_LOWLVL IRQ_TYPE_LEVEL_LOW
+#define __IRQT_HIGHLVL IRQ_TYPE_LEVEL_HIGH
+
+#define IRQT_NOEDGE (0)
+#define IRQT_RISING (__IRQT_RISEDGE)
+#define IRQT_FALLING (__IRQT_FALEDGE)
+#define IRQT_BOTHEDGE (__IRQT_RISEDGE|__IRQT_FALEDGE)
+#define IRQT_LOW (__IRQT_LOWLVL)
+#define IRQT_HIGH (__IRQT_HIGHLVL)
+#define IRQT_PROBE IRQ_TYPE_PROBE
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/linkage.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/linkage.h
new file mode 100644
index 000000000..1fb628ea0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/linkage.h
@@ -0,0 +1,18 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_LINKAGE_H
+#define __ASM_LINKAGE_H
+
+#define __ALIGN .align 0
+#define __ALIGN_STR ".align 0"
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/local.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/local.h
new file mode 100644
index 000000000..10d6a6051
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/local.h
@@ -0,0 +1,12 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#include
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/locks.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/locks.h
new file mode 100644
index 000000000..f48485cbf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/locks.h
@@ -0,0 +1,55 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_PROC_LOCKS_H
+#define __ASM_PROC_LOCKS_H
+
+#if __LINUX_ARM_ARCH__ >= 6
+
+#define __down_op(ptr,fail) ({ __asm__ __volatile__( "@ down_op\n" "1: ldrex lr, [%0]\n" " sub lr, lr, %1\n" " strex ip, lr, [%0]\n" " teq ip, #0\n" " bne 1b\n" " teq lr, #0\n" " movmi ip, %0\n" " blmi " #fail : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); smp_mb(); })
+
+#define __down_op_ret(ptr,fail) ({ unsigned int ret; __asm__ __volatile__( "@ down_op_ret\n" "1: ldrex lr, [%1]\n" " sub lr, lr, %2\n" " strex ip, lr, [%1]\n" " teq ip, #0\n" " bne 1b\n" " teq lr, #0\n" " movmi ip, %1\n" " movpl ip, #0\n" " blmi " #fail "\n" " mov %0, ip" : "=&r" (ret) : "r" (ptr), "I" (1) : "ip", "lr", "cc"); smp_mb(); ret; })
+
+#define __up_op(ptr,wake) ({ smp_mb(); __asm__ __volatile__( "@ up_op\n" "1: ldrex lr, [%0]\n" " add lr, lr, %1\n" " strex ip, lr, [%0]\n" " teq ip, #0\n" " bne 1b\n" " cmp lr, #0\n" " movle ip, %0\n" " blle " #wake : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); })
+
+#define RW_LOCK_BIAS 0x01000000
+#define RW_LOCK_BIAS_STR "0x01000000"
+
+#define __down_op_write(ptr,fail) ({ __asm__ __volatile__( "@ down_op_write\n" "1: ldrex lr, [%0]\n" " sub lr, lr, %1\n" " strex ip, lr, [%0]\n" " teq ip, #0\n" " bne 1b\n" " teq lr, #0\n" " movne ip, %0\n" " blne " #fail : : "r" (ptr), "I" (RW_LOCK_BIAS) : "ip", "lr", "cc"); smp_mb(); })
+
+#define __up_op_write(ptr,wake) ({ smp_mb(); __asm__ __volatile__( "@ up_op_write\n" "1: ldrex lr, [%0]\n" " adds lr, lr, %1\n" " strex ip, lr, [%0]\n" " teq ip, #0\n" " bne 1b\n" " movcs ip, %0\n" " blcs " #wake : : "r" (ptr), "I" (RW_LOCK_BIAS) : "ip", "lr", "cc"); })
+
+#define __down_op_read(ptr,fail) __down_op(ptr, fail)
+
+#define __up_op_read(ptr,wake) ({ smp_mb(); __asm__ __volatile__( "@ up_op_read\n" "1: ldrex lr, [%0]\n" " add lr, lr, %1\n" " strex ip, lr, [%0]\n" " teq ip, #0\n" " bne 1b\n" " teq lr, #0\n" " moveq ip, %0\n" " bleq " #wake : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); })
+
+#else
+
+#define __down_op(ptr,fail) ({ __asm__ __volatile__( "@ down_op\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%0]\n" " subs lr, lr, %1\n" " str lr, [%0]\n" " msr cpsr_c, ip\n" " movmi ip, %0\n" " blmi " #fail : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); smp_mb(); })
+
+#define __down_op_ret(ptr,fail) ({ unsigned int ret; __asm__ __volatile__( "@ down_op_ret\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%1]\n" " subs lr, lr, %2\n" " str lr, [%1]\n" " msr cpsr_c, ip\n" " movmi ip, %1\n" " movpl ip, #0\n" " blmi " #fail "\n" " mov %0, ip" : "=&r" (ret) : "r" (ptr), "I" (1) : "ip", "lr", "cc"); smp_mb(); ret; })
+
+#define __up_op(ptr,wake) ({ smp_mb(); __asm__ __volatile__( "@ up_op\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%0]\n" " adds lr, lr, %1\n" " str lr, [%0]\n" " msr cpsr_c, ip\n" " movle ip, %0\n" " blle " #wake : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); })
+
+#define RW_LOCK_BIAS 0x01000000
+#define RW_LOCK_BIAS_STR "0x01000000"
+
+#define __down_op_write(ptr,fail) ({ __asm__ __volatile__( "@ down_op_write\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%0]\n" " subs lr, lr, %1\n" " str lr, [%0]\n" " msr cpsr_c, ip\n" " movne ip, %0\n" " blne " #fail : : "r" (ptr), "I" (RW_LOCK_BIAS) : "ip", "lr", "cc"); smp_mb(); })
+
+#define __up_op_write(ptr,wake) ({ __asm__ __volatile__( "@ up_op_write\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%0]\n" " adds lr, lr, %1\n" " str lr, [%0]\n" " msr cpsr_c, ip\n" " movcs ip, %0\n" " blcs " #wake : : "r" (ptr), "I" (RW_LOCK_BIAS) : "ip", "lr", "cc"); smp_mb(); })
+
+#define __down_op_read(ptr,fail) __down_op(ptr, fail)
+
+#define __up_op_read(ptr,wake) ({ smp_mb(); __asm__ __volatile__( "@ up_op_read\n" " mrs ip, cpsr\n" " orr lr, ip, #128\n" " msr cpsr_c, lr\n" " ldr lr, [%0]\n" " adds lr, lr, %1\n" " str lr, [%0]\n" " msr cpsr_c, ip\n" " moveq ip, %0\n" " bleq " #wake : : "r" (ptr), "I" (1) : "ip", "lr", "cc"); })
+
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mc146818rtc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mc146818rtc.h
new file mode 100644
index 000000000..5a8672422
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mc146818rtc.h
@@ -0,0 +1,26 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_MC146818RTC_H
+#define _ASM_MC146818RTC_H
+
+#include
+#include
+
+#ifndef RTC_PORT
+#define RTC_PORT(x) (0x70 + (x))
+#define RTC_ALWAYS_BCD 1
+#endif
+
+#define CMOS_READ(addr) ({ outb_p((addr),RTC_PORT(0)); inb_p(RTC_PORT(1)); })
+#define CMOS_WRITE(val, addr) ({ outb_p((addr),RTC_PORT(0)); outb_p((val),RTC_PORT(1)); })
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/memory.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/memory.h
new file mode 100644
index 000000000..c1137a778
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/memory.h
@@ -0,0 +1,95 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_MEMORY_H
+#define __ASM_ARM_MEMORY_H
+
+#ifndef __ASSEMBLY__
+#define UL(x) (x##UL)
+#else
+#define UL(x) (x)
+#endif
+
+#include
+#include
+#include
+
+#ifndef TASK_SIZE
+#define TASK_SIZE (CONFIG_DRAM_SIZE)
+#endif
+
+#ifndef TASK_UNMAPPED_BASE
+#define TASK_UNMAPPED_BASE UL(0x00000000)
+#endif
+
+#ifndef PHYS_OFFSET
+#define PHYS_OFFSET (CONFIG_DRAM_BASE)
+#endif
+
+#ifndef END_MEM
+#define END_MEM (CONFIG_DRAM_BASE + CONFIG_DRAM_SIZE)
+#endif
+
+#ifndef PAGE_OFFSET
+#define PAGE_OFFSET (PHYS_OFFSET)
+#endif
+
+#define MODULE_END (END_MEM)
+#define MODULE_START (PHYS_OFFSET)
+
+#ifndef CONSISTENT_DMA_SIZE
+#define CONSISTENT_DMA_SIZE SZ_2M
+#endif
+
+#ifndef __virt_to_phys
+#define __virt_to_phys(x) ((x) - PAGE_OFFSET + PHYS_OFFSET)
+#define __phys_to_virt(x) ((x) - PHYS_OFFSET + PAGE_OFFSET)
+#endif
+
+#define __phys_to_pfn(paddr) ((paddr) >> PAGE_SHIFT)
+#define __pfn_to_phys(pfn) ((pfn) << PAGE_SHIFT)
+
+#ifndef __ASSEMBLY__
+
+#ifndef ISA_DMA_THRESHOLD
+#define ISA_DMA_THRESHOLD (0xffffffffULL)
+#endif
+
+#ifndef arch_adjust_zones
+#define arch_adjust_zones(node,size,holes) do { } while (0)
+#endif
+
+#define PHYS_PFN_OFFSET (PHYS_OFFSET >> PAGE_SHIFT)
+
+#define __pa(x) __virt_to_phys((unsigned long)(x))
+#define __va(x) ((void *)__phys_to_virt((unsigned long)(x)))
+#define pfn_to_kaddr(pfn) __va((pfn) << PAGE_SHIFT)
+#define ARCH_PFN_OFFSET PHYS_PFN_OFFSET
+#define pfn_valid(pfn) ((pfn) >= PHYS_PFN_OFFSET && (pfn) < (PHYS_PFN_OFFSET + max_mapnr))
+#define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT)
+#define virt_addr_valid(kaddr) ((unsigned long)(kaddr) >= PAGE_OFFSET && (unsigned long)(kaddr) < (unsigned long)high_memory)
+#define PHYS_TO_NID(addr) (0)
+#define page_to_phys(page) (page_to_pfn(page) << PAGE_SHIFT)
+#ifndef __arch_page_to_dma
+#define page_to_dma(dev, page) ((dma_addr_t)__virt_to_bus((unsigned long)page_address(page)))
+#define dma_to_virt(dev, addr) ((void *)__bus_to_virt(addr))
+#define virt_to_dma(dev, addr) ((dma_addr_t)__virt_to_bus((unsigned long)(addr)))
+#else
+#define page_to_dma(dev, page) (__arch_page_to_dma(dev, page))
+#define dma_to_virt(dev, addr) (__arch_dma_to_virt(dev, addr))
+#define virt_to_dma(dev, addr) (__arch_virt_to_dma(dev, addr))
+#endif
+#ifndef arch_is_coherent
+#define arch_is_coherent() 0
+#endif
+#endif
+#include
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mman.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mman.h
new file mode 100644
index 000000000..8f71d1b60
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mman.h
@@ -0,0 +1,28 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARM_MMAN_H__
+#define __ARM_MMAN_H__
+
+#include
+
+#define MAP_GROWSDOWN 0x0100
+#define MAP_DENYWRITE 0x0800
+#define MAP_EXECUTABLE 0x1000
+#define MAP_LOCKED 0x2000
+#define MAP_NORESERVE 0x4000
+#define MAP_POPULATE 0x8000
+#define MAP_NONBLOCK 0x10000
+
+#define MCL_CURRENT 1
+#define MCL_FUTURE 2
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/module.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/module.h
new file mode 100644
index 000000000..68b806a33
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/module.h
@@ -0,0 +1,26 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_ARM_MODULE_H
+#define _ASM_ARM_MODULE_H
+
+struct mod_arch_specific
+{
+ int foo;
+};
+
+#define Elf_Shdr Elf32_Shdr
+#define Elf_Sym Elf32_Sym
+#define Elf_Ehdr Elf32_Ehdr
+
+#define MODULE_ARCH_VERMAGIC "ARMv" __stringify(__LINUX_ARM_ARCH__) " "
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/msgbuf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/msgbuf.h
new file mode 100644
index 000000000..84d614c7e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/msgbuf.h
@@ -0,0 +1,32 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_MSGBUF_H
+#define _ASMARM_MSGBUF_H
+
+struct msqid64_ds {
+ struct ipc64_perm msg_perm;
+ __kernel_time_t msg_stime;
+ unsigned long __unused1;
+ __kernel_time_t msg_rtime;
+ unsigned long __unused2;
+ __kernel_time_t msg_ctime;
+ unsigned long __unused3;
+ unsigned long msg_cbytes;
+ unsigned long msg_qnum;
+ unsigned long msg_qbytes;
+ __kernel_pid_t msg_lspid;
+ __kernel_pid_t msg_lrpid;
+ unsigned long __unused4;
+ unsigned long __unused5;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mtd-xip.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mtd-xip.h
new file mode 100644
index 000000000..6c53f6f5f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/mtd-xip.h
@@ -0,0 +1,20 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARM_MTD_XIP_H__
+#define __ARM_MTD_XIP_H__
+
+#include
+#include
+
+#define xip_iprefetch() do { asm volatile (".rep 8; nop; .endr"); } while (0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/page.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/page.h
new file mode 100644
index 000000000..f9803437e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/page.h
@@ -0,0 +1,19 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_PAGE_H
+#define _ASMARM_PAGE_H
+
+#define PAGE_SHIFT 12
+#define PAGE_SIZE (1UL << PAGE_SHIFT)
+#define PAGE_MASK (~(PAGE_SIZE-1))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/param.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/param.h
new file mode 100644
index 000000000..6814fe386
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/param.h
@@ -0,0 +1,25 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_PARAM_H
+#define __ASM_PARAM_H
+
+#define HZ 100
+
+#define EXEC_PAGESIZE 4096
+
+#ifndef NOGROUP
+#define NOGROUP (-1)
+#endif
+
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/percpu.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/percpu.h
new file mode 100644
index 000000000..2500345ef
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/percpu.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARM_PERCPU
+#define __ARM_PERCPU
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgalloc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgalloc.h
new file mode 100644
index 000000000..5d45e650d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgalloc.h
@@ -0,0 +1,23 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_PGALLOC_H
+#define _ASMARM_PGALLOC_H
+
+#include
+#include
+#include
+#include
+#include
+
+#define check_pgt_cache() do { } while (0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable-hwdef.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable-hwdef.h
new file mode 100644
index 000000000..47e867595
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable-hwdef.h
@@ -0,0 +1,70 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_PGTABLE_HWDEF_H
+#define _ASMARM_PGTABLE_HWDEF_H
+
+#define PMD_TYPE_MASK (3 << 0)
+#define PMD_TYPE_FAULT (0 << 0)
+#define PMD_TYPE_TABLE (1 << 0)
+#define PMD_TYPE_SECT (2 << 0)
+#define PMD_BIT4 (1 << 4)
+#define PMD_DOMAIN(x) ((x) << 5)
+#define PMD_PROTECTION (1 << 9)
+
+#define PMD_SECT_BUFFERABLE (1 << 2)
+#define PMD_SECT_CACHEABLE (1 << 3)
+#define PMD_SECT_XN (1 << 4)
+#define PMD_SECT_AP_WRITE (1 << 10)
+#define PMD_SECT_AP_READ (1 << 11)
+#define PMD_SECT_TEX(x) ((x) << 12)
+#define PMD_SECT_APX (1 << 15)
+#define PMD_SECT_S (1 << 16)
+#define PMD_SECT_nG (1 << 17)
+#define PMD_SECT_SUPER (1 << 18)
+
+#define PMD_SECT_UNCACHED (0)
+#define PMD_SECT_BUFFERED (PMD_SECT_BUFFERABLE)
+#define PMD_SECT_WT (PMD_SECT_CACHEABLE)
+#define PMD_SECT_WB (PMD_SECT_CACHEABLE | PMD_SECT_BUFFERABLE)
+#define PMD_SECT_MINICACHE (PMD_SECT_TEX(1) | PMD_SECT_CACHEABLE)
+#define PMD_SECT_WBWA (PMD_SECT_TEX(1) | PMD_SECT_CACHEABLE | PMD_SECT_BUFFERABLE)
+#define PMD_SECT_NONSHARED_DEV (PMD_SECT_TEX(2))
+
+#define PTE_TYPE_MASK (3 << 0)
+#define PTE_TYPE_FAULT (0 << 0)
+#define PTE_TYPE_LARGE (1 << 0)
+#define PTE_TYPE_SMALL (2 << 0)
+#define PTE_TYPE_EXT (3 << 0)
+#define PTE_BUFFERABLE (1 << 2)
+#define PTE_CACHEABLE (1 << 3)
+
+#define PTE_EXT_XN (1 << 0)
+#define PTE_EXT_AP_MASK (3 << 4)
+#define PTE_EXT_AP0 (1 << 4)
+#define PTE_EXT_AP1 (2 << 4)
+#define PTE_EXT_AP_UNO_SRO (0 << 4)
+#define PTE_EXT_AP_UNO_SRW (PTE_EXT_AP0)
+#define PTE_EXT_AP_URO_SRW (PTE_EXT_AP1)
+#define PTE_EXT_AP_URW_SRW (PTE_EXT_AP1|PTE_EXT_AP0)
+#define PTE_EXT_TEX(x) ((x) << 6)
+#define PTE_EXT_APX (1 << 9)
+#define PTE_EXT_COHERENT (1 << 9)
+#define PTE_EXT_SHARED (1 << 10)
+#define PTE_EXT_NG (1 << 11)
+
+#define PTE_SMALL_AP_MASK (0xff << 4)
+#define PTE_SMALL_AP_UNO_SRO (0x00 << 4)
+#define PTE_SMALL_AP_UNO_SRW (0x55 << 4)
+#define PTE_SMALL_AP_URO_SRW (0xaa << 4)
+#define PTE_SMALL_AP_URW_SRW (0xff << 4)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable.h
new file mode 100644
index 000000000..cbac6115a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/pgtable.h
@@ -0,0 +1,20 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_PGTABLE_H
+#define _ASMARM_PGTABLE_H
+
+#include
+#include
+
+#include "pgtable-nommu.h"
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/poll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/poll.h
new file mode 100644
index 000000000..c5b80a5ff
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/poll.h
@@ -0,0 +1,36 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASMARM_POLL_H
+#define __ASMARM_POLL_H
+
+#define POLLIN 0x0001
+#define POLLPRI 0x0002
+#define POLLOUT 0x0004
+#define POLLERR 0x0008
+#define POLLHUP 0x0010
+#define POLLNVAL 0x0020
+
+#define POLLRDNORM 0x0040
+#define POLLRDBAND 0x0080
+#define POLLWRNORM 0x0100
+#define POLLWRBAND 0x0200
+#define POLLMSG 0x0400
+#define POLLREMOVE 0x1000
+#define POLLRDHUP 0x2000
+
+struct pollfd {
+ int fd;
+ short events;
+ short revents;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/posix_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/posix_types.h
new file mode 100644
index 000000000..bc852174f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/posix_types.h
@@ -0,0 +1,70 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARCH_ARM_POSIX_TYPES_H
+#define __ARCH_ARM_POSIX_TYPES_H
+
+typedef unsigned long __kernel_ino_t;
+typedef unsigned short __kernel_mode_t;
+typedef unsigned short __kernel_nlink_t;
+typedef long __kernel_off_t;
+typedef int __kernel_pid_t;
+typedef unsigned short __kernel_ipc_pid_t;
+typedef unsigned short __kernel_uid_t;
+typedef unsigned short __kernel_gid_t;
+typedef unsigned int __kernel_size_t;
+typedef int __kernel_ssize_t;
+typedef int __kernel_ptrdiff_t;
+typedef long __kernel_time_t;
+typedef long __kernel_suseconds_t;
+typedef long __kernel_clock_t;
+typedef int __kernel_timer_t;
+typedef int __kernel_clockid_t;
+typedef int __kernel_daddr_t;
+typedef char * __kernel_caddr_t;
+typedef unsigned short __kernel_uid16_t;
+typedef unsigned short __kernel_gid16_t;
+typedef unsigned int __kernel_uid32_t;
+typedef unsigned int __kernel_gid32_t;
+
+typedef unsigned short __kernel_old_uid_t;
+typedef unsigned short __kernel_old_gid_t;
+typedef unsigned short __kernel_old_dev_t;
+
+#ifdef __GNUC__
+typedef long long __kernel_loff_t;
+#endif
+
+typedef struct {
+#ifdef __USE_ALL
+ int val[2];
+#else
+ int __val[2];
+#endif
+} __kernel_fsid_t;
+
+#if !defined(__GLIBC__) || __GLIBC__ < 2
+
+#undef __FD_SET
+#define __FD_SET(fd, fdsetp) (((fd_set *)(fdsetp))->fds_bits[(fd) >> 5] |= (1<<((fd) & 31)))
+
+#undef __FD_CLR
+#define __FD_CLR(fd, fdsetp) (((fd_set *)(fdsetp))->fds_bits[(fd) >> 5] &= ~(1<<((fd) & 31)))
+
+#undef __FD_ISSET
+#define __FD_ISSET(fd, fdsetp) ((((fd_set *)(fdsetp))->fds_bits[(fd) >> 5] & (1<<((fd) & 31))) != 0)
+
+#undef __FD_ZERO
+#define __FD_ZERO(fdsetp) (memset (fdsetp, 0, sizeof (*(fd_set *)(fdsetp))))
+
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/proc-fns.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/proc-fns.h
new file mode 100644
index 000000000..4a560d06e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/proc-fns.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_PROCFNS_H
+#define __ASM_PROCFNS_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/processor.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/processor.h
new file mode 100644
index 000000000..f93cbc14e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/processor.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_PROCESSOR_H
+#define __ASM_ARM_PROCESSOR_H
+
+#define current_text_addr() ({ __label__ _l; _l: &&_l;})
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/procinfo.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/procinfo.h
new file mode 100644
index 000000000..d774e0b6d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/procinfo.h
@@ -0,0 +1,51 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_PROCINFO_H
+#define __ASM_PROCINFO_H
+
+#ifndef __ASSEMBLY__
+
+struct cpu_tlb_fns;
+struct cpu_user_fns;
+struct cpu_cache_fns;
+struct processor;
+
+struct proc_info_list {
+ unsigned int cpu_val;
+ unsigned int cpu_mask;
+ unsigned long __cpu_mm_mmu_flags;
+ unsigned long __cpu_io_mmu_flags;
+ unsigned long __cpu_flush;
+ const char *arch_name;
+ const char *elf_name;
+ unsigned int elf_hwcap;
+ const char *cpu_name;
+ struct processor *proc;
+ struct cpu_tlb_fns *tlb;
+ struct cpu_user_fns *user;
+ struct cpu_cache_fns *cache;
+};
+
+#endif
+
+#define HWCAP_SWP 1
+#define HWCAP_HALF 2
+#define HWCAP_THUMB 4
+#define HWCAP_26BIT 8
+#define HWCAP_FAST_MULT 16
+#define HWCAP_FPA 32
+#define HWCAP_VFP 64
+#define HWCAP_EDSP 128
+#define HWCAP_JAVA 256
+#define HWCAP_IWMMXT 512
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ptrace.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ptrace.h
new file mode 100644
index 000000000..c6dfea10a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/ptrace.h
@@ -0,0 +1,95 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_PTRACE_H
+#define __ASM_ARM_PTRACE_H
+
+#define PTRACE_GETREGS 12
+#define PTRACE_SETREGS 13
+#define PTRACE_GETFPREGS 14
+#define PTRACE_SETFPREGS 15
+
+#define PTRACE_GETWMMXREGS 18
+#define PTRACE_SETWMMXREGS 19
+
+#define PTRACE_OLDSETOPTIONS 21
+
+#define PTRACE_GET_THREAD_AREA 22
+
+#define PTRACE_SET_SYSCALL 23
+
+#define PTRACE_GETCRUNCHREGS 25
+#define PTRACE_SETCRUNCHREGS 26
+
+#define USR26_MODE 0x00000000
+#define FIQ26_MODE 0x00000001
+#define IRQ26_MODE 0x00000002
+#define SVC26_MODE 0x00000003
+#define USR_MODE 0x00000010
+#define FIQ_MODE 0x00000011
+#define IRQ_MODE 0x00000012
+#define SVC_MODE 0x00000013
+#define ABT_MODE 0x00000017
+#define UND_MODE 0x0000001b
+#define SYSTEM_MODE 0x0000001f
+#define MODE32_BIT 0x00000010
+#define MODE_MASK 0x0000001f
+#define PSR_T_BIT 0x00000020
+#define PSR_F_BIT 0x00000040
+#define PSR_I_BIT 0x00000080
+#define PSR_J_BIT 0x01000000
+#define PSR_Q_BIT 0x08000000
+#define PSR_V_BIT 0x10000000
+#define PSR_C_BIT 0x20000000
+#define PSR_Z_BIT 0x40000000
+#define PSR_N_BIT 0x80000000
+#define PCMASK 0
+
+#define PSR_f 0xff000000
+#define PSR_s 0x00ff0000
+#define PSR_x 0x0000ff00
+#define PSR_c 0x000000ff
+
+#ifndef __ASSEMBLY__
+
+struct pt_regs {
+ long uregs[18];
+};
+
+#define ARM_cpsr uregs[16]
+#define ARM_pc uregs[15]
+#define ARM_lr uregs[14]
+#define ARM_sp uregs[13]
+#define ARM_ip uregs[12]
+#define ARM_fp uregs[11]
+#define ARM_r10 uregs[10]
+#define ARM_r9 uregs[9]
+#define ARM_r8 uregs[8]
+#define ARM_r7 uregs[7]
+#define ARM_r6 uregs[6]
+#define ARM_r5 uregs[5]
+#define ARM_r4 uregs[4]
+#define ARM_r3 uregs[3]
+#define ARM_r2 uregs[2]
+#define ARM_r1 uregs[1]
+#define ARM_r0 uregs[0]
+#define ARM_ORIG_r0 uregs[17]
+
+#define pc_pointer(v) ((v) & ~PCMASK)
+
+#define instruction_pointer(regs) (pc_pointer((regs)->ARM_pc))
+
+#define profile_pc(regs) instruction_pointer(regs)
+
+#endif
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/resource.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/resource.h
new file mode 100644
index 000000000..7546dd4cd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/resource.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ARM_RESOURCE_H
+#define _ARM_RESOURCE_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/scatterlist.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/scatterlist.h
new file mode 100644
index 000000000..a2c06cae6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/scatterlist.h
@@ -0,0 +1,28 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SCATTERLIST_H
+#define _ASMARM_SCATTERLIST_H
+
+#include
+#include
+
+struct scatterlist {
+ struct page *page;
+ unsigned int offset;
+ dma_addr_t dma_address;
+ unsigned int length;
+};
+
+#define sg_dma_address(sg) ((sg)->dma_address)
+#define sg_dma_len(sg) ((sg)->length)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/semaphore.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/semaphore.h
new file mode 100644
index 000000000..7c5618a3a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/semaphore.h
@@ -0,0 +1,36 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_SEMAPHORE_H
+#define __ASM_ARM_SEMAPHORE_H
+
+#include
+#include
+#include
+#include
+
+#include
+#include
+
+struct semaphore {
+ atomic_t count;
+ int sleepers;
+ wait_queue_head_t wait;
+};
+
+#define __SEMAPHORE_INIT(name, cnt) { .count = ATOMIC_INIT(cnt), .wait = __WAIT_QUEUE_HEAD_INITIALIZER((name).wait), }
+
+#define __DECLARE_SEMAPHORE_GENERIC(name,count) struct semaphore name = __SEMAPHORE_INIT(name,count)
+
+#define DECLARE_MUTEX(name) __DECLARE_SEMAPHORE_GENERIC(name,1)
+#define DECLARE_MUTEX_LOCKED(name) __DECLARE_SEMAPHORE_GENERIC(name,0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sembuf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sembuf.h
new file mode 100644
index 000000000..a2f5dd096
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sembuf.h
@@ -0,0 +1,26 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SEMBUF_H
+#define _ASMARM_SEMBUF_H
+
+struct semid64_ds {
+ struct ipc64_perm sem_perm;
+ __kernel_time_t sem_otime;
+ unsigned long __unused1;
+ __kernel_time_t sem_ctime;
+ unsigned long __unused2;
+ unsigned long sem_nsems;
+ unsigned long __unused3;
+ unsigned long __unused4;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmbuf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmbuf.h
new file mode 100644
index 000000000..1d4d78c10
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmbuf.h
@@ -0,0 +1,43 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SHMBUF_H
+#define _ASMARM_SHMBUF_H
+
+struct shmid64_ds {
+ struct ipc64_perm shm_perm;
+ size_t shm_segsz;
+ __kernel_time_t shm_atime;
+ unsigned long __unused1;
+ __kernel_time_t shm_dtime;
+ unsigned long __unused2;
+ __kernel_time_t shm_ctime;
+ unsigned long __unused3;
+ __kernel_pid_t shm_cpid;
+ __kernel_pid_t shm_lpid;
+ unsigned long shm_nattch;
+ unsigned long __unused4;
+ unsigned long __unused5;
+};
+
+struct shminfo64 {
+ unsigned long shmmax;
+ unsigned long shmmin;
+ unsigned long shmmni;
+ unsigned long shmseg;
+ unsigned long shmall;
+ unsigned long __unused1;
+ unsigned long __unused2;
+ unsigned long __unused3;
+ unsigned long __unused4;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmparam.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmparam.h
new file mode 100644
index 000000000..ea53a8d57
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/shmparam.h
@@ -0,0 +1,19 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SHMPARAM_H
+#define _ASMARM_SHMPARAM_H
+
+#define SHMLBA (4 * PAGE_SIZE)
+
+#define __ARCH_FORCE_SHMLBA
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sigcontext.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sigcontext.h
new file mode 100644
index 000000000..3c4fcf3de
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sigcontext.h
@@ -0,0 +1,39 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SIGCONTEXT_H
+#define _ASMARM_SIGCONTEXT_H
+
+struct sigcontext {
+ unsigned long trap_no;
+ unsigned long error_code;
+ unsigned long oldmask;
+ unsigned long arm_r0;
+ unsigned long arm_r1;
+ unsigned long arm_r2;
+ unsigned long arm_r3;
+ unsigned long arm_r4;
+ unsigned long arm_r5;
+ unsigned long arm_r6;
+ unsigned long arm_r7;
+ unsigned long arm_r8;
+ unsigned long arm_r9;
+ unsigned long arm_r10;
+ unsigned long arm_fp;
+ unsigned long arm_ip;
+ unsigned long arm_sp;
+ unsigned long arm_lr;
+ unsigned long arm_pc;
+ unsigned long arm_cpsr;
+ unsigned long fault_address;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/siginfo.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/siginfo.h
new file mode 100644
index 000000000..225685ee2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/siginfo.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SIGINFO_H
+#define _ASMARM_SIGINFO_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/signal.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/signal.h
new file mode 100644
index 000000000..212d9f169
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/signal.h
@@ -0,0 +1,103 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SIGNAL_H
+#define _ASMARM_SIGNAL_H
+
+#include
+
+struct siginfo;
+
+#define NSIG 32
+typedef unsigned long sigset_t;
+
+#define SIGHUP 1
+#define SIGINT 2
+#define SIGQUIT 3
+#define SIGILL 4
+#define SIGTRAP 5
+#define SIGABRT 6
+#define SIGIOT 6
+#define SIGBUS 7
+#define SIGFPE 8
+#define SIGKILL 9
+#define SIGUSR1 10
+#define SIGSEGV 11
+#define SIGUSR2 12
+#define SIGPIPE 13
+#define SIGALRM 14
+#define SIGTERM 15
+#define SIGSTKFLT 16
+#define SIGCHLD 17
+#define SIGCONT 18
+#define SIGSTOP 19
+#define SIGTSTP 20
+#define SIGTTIN 21
+#define SIGTTOU 22
+#define SIGURG 23
+#define SIGXCPU 24
+#define SIGXFSZ 25
+#define SIGVTALRM 26
+#define SIGPROF 27
+#define SIGWINCH 28
+#define SIGIO 29
+#define SIGPOLL SIGIO
+
+#define SIGPWR 30
+#define SIGSYS 31
+#define SIGUNUSED 31
+
+#define SIGRTMIN 32
+#define SIGRTMAX _NSIG
+
+#define SIGSWI 32
+
+#define SA_NOCLDSTOP 0x00000001
+#define SA_NOCLDWAIT 0x00000002
+#define SA_SIGINFO 0x00000004
+#define SA_THIRTYTWO 0x02000000
+#define SA_RESTORER 0x04000000
+#define SA_ONSTACK 0x08000000
+#define SA_RESTART 0x10000000
+#define SA_NODEFER 0x40000000
+#define SA_RESETHAND 0x80000000
+
+#define SA_NOMASK SA_NODEFER
+#define SA_ONESHOT SA_RESETHAND
+
+#define SS_ONSTACK 1
+#define SS_DISABLE 2
+
+#define MINSIGSTKSZ 2048
+#define SIGSTKSZ 8192
+
+#include
+
+struct sigaction {
+ union {
+ __sighandler_t _sa_handler;
+ void (*_sa_sigaction)(int, struct siginfo *, void *);
+ } _u;
+ sigset_t sa_mask;
+ unsigned long sa_flags;
+ void (*sa_restorer)(void);
+};
+
+#define sa_handler _u._sa_handler
+#define sa_sigaction _u._sa_sigaction
+
+typedef struct sigaltstack {
+ void __user *ss_sp;
+ int ss_flags;
+ size_t ss_size;
+} stack_t;
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sizes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sizes.h
new file mode 100644
index 000000000..90c1c71d8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sizes.h
@@ -0,0 +1,39 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __sizes_h
+#define __sizes_h 1
+
+#define SZ_1K 0x00000400
+#define SZ_4K 0x00001000
+#define SZ_8K 0x00002000
+#define SZ_16K 0x00004000
+#define SZ_64K 0x00010000
+#define SZ_128K 0x00020000
+#define SZ_256K 0x00040000
+#define SZ_512K 0x00080000
+
+#define SZ_1M 0x00100000
+#define SZ_2M 0x00200000
+#define SZ_4M 0x00400000
+#define SZ_8M 0x00800000
+#define SZ_16M 0x01000000
+#define SZ_32M 0x02000000
+#define SZ_64M 0x04000000
+#define SZ_128M 0x08000000
+#define SZ_256M 0x10000000
+#define SZ_512M 0x20000000
+
+#define SZ_1G 0x40000000
+#define SZ_2G 0x80000000
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/smp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/smp.h
new file mode 100644
index 000000000..e6c1e41d2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/smp.h
@@ -0,0 +1,34 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_SMP_H
+#define __ASM_ARM_SMP_H
+
+#include
+#include
+#include
+
+#include
+
+#error " included in non-SMP build"
+
+#define raw_smp_processor_id() (current_thread_info()->cpu)
+
+#define PROC_CHANGE_PENALTY 15
+
+struct seq_file;
+
+struct secondary_data {
+ unsigned long pgdir;
+ void *stack;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/socket.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/socket.h
new file mode 100644
index 000000000..1f0050ae1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/socket.h
@@ -0,0 +1,61 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SOCKET_H
+#define _ASMARM_SOCKET_H
+
+#include
+
+#define SOL_SOCKET 1
+
+#define SO_DEBUG 1
+#define SO_REUSEADDR 2
+#define SO_TYPE 3
+#define SO_ERROR 4
+#define SO_DONTROUTE 5
+#define SO_BROADCAST 6
+#define SO_SNDBUF 7
+#define SO_RCVBUF 8
+#define SO_SNDBUFFORCE 32
+#define SO_RCVBUFFORCE 33
+#define SO_KEEPALIVE 9
+#define SO_OOBINLINE 10
+#define SO_NO_CHECK 11
+#define SO_PRIORITY 12
+#define SO_LINGER 13
+#define SO_BSDCOMPAT 14
+
+#define SO_PASSCRED 16
+#define SO_PEERCRED 17
+#define SO_RCVLOWAT 18
+#define SO_SNDLOWAT 19
+#define SO_RCVTIMEO 20
+#define SO_SNDTIMEO 21
+
+#define SO_SECURITY_AUTHENTICATION 22
+#define SO_SECURITY_ENCRYPTION_TRANSPORT 23
+#define SO_SECURITY_ENCRYPTION_NETWORK 24
+
+#define SO_BINDTODEVICE 25
+
+#define SO_ATTACH_FILTER 26
+#define SO_DETACH_FILTER 27
+
+#define SO_PEERNAME 28
+#define SO_TIMESTAMP 29
+#define SCM_TIMESTAMP SO_TIMESTAMP
+
+#define SO_ACCEPTCONN 30
+
+#define SO_PEERSEC 31
+#define SO_PASSSEC 34
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sockios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sockios.h
new file mode 100644
index 000000000..cab86b8ef
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/sockios.h
@@ -0,0 +1,22 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ARCH_ARM_SOCKIOS_H
+#define __ARCH_ARM_SOCKIOS_H
+
+#define FIOSETOWN 0x8901
+#define SIOCSPGRP 0x8902
+#define FIOGETOWN 0x8903
+#define SIOCGPGRP 0x8904
+#define SIOCATMARK 0x8905
+#define SIOCGSTAMP 0x8906
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock.h
new file mode 100644
index 000000000..3ae21735d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock.h
@@ -0,0 +1,27 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_SPINLOCK_H
+#define __ASM_SPINLOCK_H
+
+#if __LINUX_ARM_ARCH__ < 6
+#error SMP not supported on pre-ARMv6 CPUs
+#endif
+
+#define __raw_spin_is_locked(x) ((x)->lock != 0)
+#define __raw_spin_unlock_wait(lock) do { while (__raw_spin_is_locked(lock)) cpu_relax(); } while (0)
+
+#define __raw_spin_lock_flags(lock, flags) __raw_spin_lock(lock)
+
+#define rwlock_is_locked(x) (*((volatile unsigned int *)(x)) != 0)
+#define __raw_write_can_lock(x) ((x)->lock == 0x80000000)
+#define __raw_read_can_lock(x) ((x)->lock < 0x80000000)
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock_types.h
new file mode 100644
index 000000000..ee77f201c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/spinlock_types.h
@@ -0,0 +1,31 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_SPINLOCK_TYPES_H
+#define __ASM_SPINLOCK_TYPES_H
+
+#ifndef __LINUX_SPINLOCK_TYPES_H
+#error "please don't include this file directly"
+#endif
+
+typedef struct {
+ volatile unsigned int lock;
+} raw_spinlock_t;
+
+#define __RAW_SPIN_LOCK_UNLOCKED { 0 }
+
+typedef struct {
+ volatile unsigned int lock;
+} raw_rwlock_t;
+
+#define __RAW_RW_LOCK_UNLOCKED { 0 }
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/stat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/stat.h
new file mode 100644
index 000000000..49b85f960
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/stat.h
@@ -0,0 +1,93 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_STAT_H
+#define _ASMARM_STAT_H
+
+struct __old_kernel_stat {
+ unsigned short st_dev;
+ unsigned short st_ino;
+ unsigned short st_mode;
+ unsigned short st_nlink;
+ unsigned short st_uid;
+ unsigned short st_gid;
+ unsigned short st_rdev;
+ unsigned long st_size;
+ unsigned long st_atime;
+ unsigned long st_mtime;
+ unsigned long st_ctime;
+};
+
+#define STAT_HAVE_NSEC
+
+struct stat {
+#ifdef __ARMEB__
+ unsigned short st_dev;
+ unsigned short __pad1;
+#else
+ unsigned long st_dev;
+#endif
+ unsigned long st_ino;
+ unsigned short st_mode;
+ unsigned short st_nlink;
+ unsigned short st_uid;
+ unsigned short st_gid;
+#ifdef __ARMEB__
+ unsigned short st_rdev;
+ unsigned short __pad2;
+#else
+ unsigned long st_rdev;
+#endif
+ unsigned long st_size;
+ unsigned long st_blksize;
+ unsigned long st_blocks;
+ unsigned long st_atime;
+ unsigned long st_atime_nsec;
+ unsigned long st_mtime;
+ unsigned long st_mtime_nsec;
+ unsigned long st_ctime;
+ unsigned long st_ctime_nsec;
+ unsigned long __unused4;
+ unsigned long __unused5;
+};
+
+struct stat64 {
+ unsigned long long st_dev;
+ unsigned char __pad0[4];
+
+#define STAT64_HAS_BROKEN_ST_INO 1
+ unsigned long __st_ino;
+ unsigned int st_mode;
+ unsigned int st_nlink;
+
+ unsigned long st_uid;
+ unsigned long st_gid;
+
+ unsigned long long st_rdev;
+ unsigned char __pad3[4];
+
+ long long st_size;
+ unsigned long st_blksize;
+ unsigned long long st_blocks;
+
+ unsigned long st_atime;
+ unsigned long st_atime_nsec;
+
+ unsigned long st_mtime;
+ unsigned long st_mtime_nsec;
+
+ unsigned long st_ctime;
+ unsigned long st_ctime_nsec;
+
+ unsigned long long st_ino;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/statfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/statfs.h
new file mode 100644
index 000000000..7963eab26
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/statfs.h
@@ -0,0 +1,43 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_STATFS_H
+#define _ASMARM_STATFS_H
+
+struct statfs {
+ __u32 f_type;
+ __u32 f_bsize;
+ __u32 f_blocks;
+ __u32 f_bfree;
+ __u32 f_bavail;
+ __u32 f_files;
+ __u32 f_ffree;
+ __kernel_fsid_t f_fsid;
+ __u32 f_namelen;
+ __u32 f_frsize;
+ __u32 f_spare[5];
+};
+
+struct statfs64 {
+ __u32 f_type;
+ __u32 f_bsize;
+ __u64 f_blocks;
+ __u64 f_bfree;
+ __u64 f_bavail;
+ __u64 f_files;
+ __u64 f_ffree;
+ __kernel_fsid_t f_fsid;
+ __u32 f_namelen;
+ __u32 f_frsize;
+ __u32 f_spare[5];
+} __attribute__ ((packed,aligned(4)));
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/suspend.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/suspend.h
new file mode 100644
index 000000000..156c171b7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/suspend.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_SUSPEND_H
+#define _ASMARM_SUSPEND_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/system.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/system.h
new file mode 100644
index 000000000..8e8503940
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/system.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_SYSTEM_H
+#define __ASM_ARM_SYSTEM_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termbits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termbits.h
new file mode 100644
index 000000000..640bd275e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termbits.h
@@ -0,0 +1,174 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_TERMBITS_H
+#define __ASM_ARM_TERMBITS_H
+
+typedef unsigned char cc_t;
+typedef unsigned int speed_t;
+typedef unsigned int tcflag_t;
+
+#define NCCS 19
+struct termios {
+ tcflag_t c_iflag;
+ tcflag_t c_oflag;
+ tcflag_t c_cflag;
+ tcflag_t c_lflag;
+ cc_t c_line;
+ cc_t c_cc[NCCS];
+};
+
+#define VINTR 0
+#define VQUIT 1
+#define VERASE 2
+#define VKILL 3
+#define VEOF 4
+#define VTIME 5
+#define VMIN 6
+#define VSWTC 7
+#define VSTART 8
+#define VSTOP 9
+#define VSUSP 10
+#define VEOL 11
+#define VREPRINT 12
+#define VDISCARD 13
+#define VWERASE 14
+#define VLNEXT 15
+#define VEOL2 16
+
+#define IGNBRK 0000001
+#define BRKINT 0000002
+#define IGNPAR 0000004
+#define PARMRK 0000010
+#define INPCK 0000020
+#define ISTRIP 0000040
+#define INLCR 0000100
+#define IGNCR 0000200
+#define ICRNL 0000400
+#define IUCLC 0001000
+#define IXON 0002000
+#define IXANY 0004000
+#define IXOFF 0010000
+#define IMAXBEL 0020000
+#define IUTF8 0040000
+
+#define OPOST 0000001
+#define OLCUC 0000002
+#define ONLCR 0000004
+#define OCRNL 0000010
+#define ONOCR 0000020
+#define ONLRET 0000040
+#define OFILL 0000100
+#define OFDEL 0000200
+#define NLDLY 0000400
+#define NL0 0000000
+#define NL1 0000400
+#define CRDLY 0003000
+#define CR0 0000000
+#define CR1 0001000
+#define CR2 0002000
+#define CR3 0003000
+#define TABDLY 0014000
+#define TAB0 0000000
+#define TAB1 0004000
+#define TAB2 0010000
+#define TAB3 0014000
+#define XTABS 0014000
+#define BSDLY 0020000
+#define BS0 0000000
+#define BS1 0020000
+#define VTDLY 0040000
+#define VT0 0000000
+#define VT1 0040000
+#define FFDLY 0100000
+#define FF0 0000000
+#define FF1 0100000
+
+#define CBAUD 0010017
+#define B0 0000000
+#define B50 0000001
+#define B75 0000002
+#define B110 0000003
+#define B134 0000004
+#define B150 0000005
+#define B200 0000006
+#define B300 0000007
+#define B600 0000010
+#define B1200 0000011
+#define B1800 0000012
+#define B2400 0000013
+#define B4800 0000014
+#define B9600 0000015
+#define B19200 0000016
+#define B38400 0000017
+#define EXTA B19200
+#define EXTB B38400
+#define CSIZE 0000060
+#define CS5 0000000
+#define CS6 0000020
+#define CS7 0000040
+#define CS8 0000060
+#define CSTOPB 0000100
+#define CREAD 0000200
+#define PARENB 0000400
+#define PARODD 0001000
+#define HUPCL 0002000
+#define CLOCAL 0004000
+#define CBAUDEX 0010000
+#define B57600 0010001
+#define B115200 0010002
+#define B230400 0010003
+#define B460800 0010004
+#define B500000 0010005
+#define B576000 0010006
+#define B921600 0010007
+#define B1000000 0010010
+#define B1152000 0010011
+#define B1500000 0010012
+#define B2000000 0010013
+#define B2500000 0010014
+#define B3000000 0010015
+#define B3500000 0010016
+#define B4000000 0010017
+#define CIBAUD 002003600000
+#define CMSPAR 010000000000
+#define CRTSCTS 020000000000
+
+#define ISIG 0000001
+#define ICANON 0000002
+#define XCASE 0000004
+#define ECHO 0000010
+#define ECHOE 0000020
+#define ECHOK 0000040
+#define ECHONL 0000100
+#define NOFLSH 0000200
+#define TOSTOP 0000400
+#define ECHOCTL 0001000
+#define ECHOPRT 0002000
+#define ECHOKE 0004000
+#define FLUSHO 0010000
+#define PENDIN 0040000
+#define IEXTEN 0100000
+
+#define TCOOFF 0
+#define TCOON 1
+#define TCIOFF 2
+#define TCION 3
+
+#define TCIFLUSH 0
+#define TCOFLUSH 1
+#define TCIOFLUSH 2
+
+#define TCSANOW 0
+#define TCSADRAIN 1
+#define TCSAFLUSH 2
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termios.h
new file mode 100644
index 000000000..ba43ac272
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/termios.h
@@ -0,0 +1,67 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_TERMIOS_H
+#define __ASM_ARM_TERMIOS_H
+
+#include
+#include
+
+struct winsize {
+ unsigned short ws_row;
+ unsigned short ws_col;
+ unsigned short ws_xpixel;
+ unsigned short ws_ypixel;
+};
+
+#define NCC 8
+struct termio {
+ unsigned short c_iflag;
+ unsigned short c_oflag;
+ unsigned short c_cflag;
+ unsigned short c_lflag;
+ unsigned char c_line;
+ unsigned char c_cc[NCC];
+};
+
+#define TIOCM_LE 0x001
+#define TIOCM_DTR 0x002
+#define TIOCM_RTS 0x004
+#define TIOCM_ST 0x008
+#define TIOCM_SR 0x010
+#define TIOCM_CTS 0x020
+#define TIOCM_CAR 0x040
+#define TIOCM_RNG 0x080
+#define TIOCM_DSR 0x100
+#define TIOCM_CD TIOCM_CAR
+#define TIOCM_RI TIOCM_RNG
+#define TIOCM_OUT1 0x2000
+#define TIOCM_OUT2 0x4000
+#define TIOCM_LOOP 0x8000
+
+#define N_TTY 0
+#define N_SLIP 1
+#define N_MOUSE 2
+#define N_PPP 3
+#define N_STRIP 4
+#define N_AX25 5
+#define N_X25 6
+#define N_6PACK 7
+#define N_MASC 8
+#define N_R3964 9
+#define N_PROFIBUS_FDL 10
+#define N_IRDA 11
+#define N_SMSBLOCK 12
+#define N_HDLC 13
+#define N_SYNC_PPP 14
+#define N_HCI 15
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/thread_info.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/thread_info.h
new file mode 100644
index 000000000..a30d2dc7a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/thread_info.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_THREAD_INFO_H
+#define __ASM_ARM_THREAD_INFO_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/timex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/timex.h
new file mode 100644
index 000000000..110c471a2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/timex.h
@@ -0,0 +1,19 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_TIMEX_H
+#define _ASMARM_TIMEX_H
+
+#include
+
+typedef unsigned long cycles_t;
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/tlbflush.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/tlbflush.h
new file mode 100644
index 000000000..70a23dc8a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/tlbflush.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_TLBFLUSH_H
+#define _ASMARM_TLBFLUSH_H
+
+#define tlb_flush(tlb) ((void) tlb)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/topology.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/topology.h
new file mode 100644
index 000000000..9eccfd414
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/topology.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_ARM_TOPOLOGY_H
+#define _ASM_ARM_TOPOLOGY_H
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/types.h
new file mode 100644
index 000000000..ec60f100c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/types.h
@@ -0,0 +1,36 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_TYPES_H
+#define __ASM_ARM_TYPES_H
+
+#ifndef __ASSEMBLY__
+
+typedef unsigned short umode_t;
+
+typedef __signed__ char __s8;
+typedef unsigned char __u8;
+
+typedef __signed__ short __s16;
+typedef unsigned short __u16;
+
+typedef __signed__ int __s32;
+typedef unsigned int __u32;
+
+#if defined(__GNUC__) && !defined(__STRICT_ANSI__)
+typedef __signed__ long long __s64;
+typedef unsigned long long __u64;
+#endif
+
+#endif
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/uaccess.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/uaccess.h
new file mode 100644
index 000000000..21fc3f293
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/uaccess.h
@@ -0,0 +1,77 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASMARM_UACCESS_H
+#define _ASMARM_UACCESS_H
+
+#include
+#include
+#include
+#include
+#include
+
+#define VERIFY_READ 0
+#define VERIFY_WRITE 1
+
+struct exception_table_entry
+{
+ unsigned long insn, fixup;
+};
+
+#define KERNEL_DS 0x00000000
+#define get_ds() (KERNEL_DS)
+
+#define USER_DS KERNEL_DS
+
+#define segment_eq(a,b) (1)
+#define __addr_ok(addr) (1)
+#define __range_ok(addr,size) (0)
+#define get_fs() (KERNEL_DS)
+
+#define get_user(x,p) __get_user(x,p)
+#define put_user(x,p) __put_user(x,p)
+#define access_ok(type,addr,size) (__range_ok(addr,size) == 0)
+#define __get_user(x,ptr) ({ long __gu_err = 0; __get_user_err((x),(ptr),__gu_err); __gu_err; })
+#define __get_user_error(x,ptr,err) ({ __get_user_err((x),(ptr),err); (void) 0; })
+#define __get_user_err(x,ptr,err) do { unsigned long __gu_addr = (unsigned long)(ptr); unsigned long __gu_val; __chk_user_ptr(ptr); switch (sizeof(*(ptr))) { case 1: __get_user_asm_byte(__gu_val,__gu_addr,err); break; case 2: __get_user_asm_half(__gu_val,__gu_addr,err); break; case 4: __get_user_asm_word(__gu_val,__gu_addr,err); break; default: (__gu_val) = __get_user_bad(); } (x) = (__typeof__(*(ptr)))__gu_val; } while (0)
+#define __get_user_asm_byte(x,addr,err) __asm__ __volatile__( "1: ldrbt %1,[%2],#0\n" "2:\n" " .section .fixup,\"ax\"\n" " .align 2\n" "3: mov %0, %3\n" " mov %1, #0\n" " b 2b\n" " .previous\n" " .section __ex_table,\"a\"\n" " .align 3\n" " .long 1b, 3b\n" " .previous" : "+r" (err), "=&r" (x) : "r" (addr), "i" (-EFAULT) : "cc")
+#ifndef __ARMEB__
+#define __get_user_asm_half(x,__gu_addr,err) ({ unsigned long __b1, __b2; __get_user_asm_byte(__b1, __gu_addr, err); __get_user_asm_byte(__b2, __gu_addr + 1, err); (x) = __b1 | (__b2 << 8); })
+#else
+#define __get_user_asm_half(x,__gu_addr,err) ({ unsigned long __b1, __b2; __get_user_asm_byte(__b1, __gu_addr, err); __get_user_asm_byte(__b2, __gu_addr + 1, err); (x) = (__b1 << 8) | __b2; })
+#endif
+#define __get_user_asm_word(x,addr,err) __asm__ __volatile__( "1: ldrt %1,[%2],#0\n" "2:\n" " .section .fixup,\"ax\"\n" " .align 2\n" "3: mov %0, %3\n" " mov %1, #0\n" " b 2b\n" " .previous\n" " .section __ex_table,\"a\"\n" " .align 3\n" " .long 1b, 3b\n" " .previous" : "+r" (err), "=&r" (x) : "r" (addr), "i" (-EFAULT) : "cc")
+#define __put_user(x,ptr) ({ long __pu_err = 0; __put_user_err((x),(ptr),__pu_err); __pu_err; })
+#define __put_user_error(x,ptr,err) ({ __put_user_err((x),(ptr),err); (void) 0; })
+#define __put_user_err(x,ptr,err) do { unsigned long __pu_addr = (unsigned long)(ptr); __typeof__(*(ptr)) __pu_val = (x); __chk_user_ptr(ptr); switch (sizeof(*(ptr))) { case 1: __put_user_asm_byte(__pu_val,__pu_addr,err); break; case 2: __put_user_asm_half(__pu_val,__pu_addr,err); break; case 4: __put_user_asm_word(__pu_val,__pu_addr,err); break; case 8: __put_user_asm_dword(__pu_val,__pu_addr,err); break; default: __put_user_bad(); } } while (0)
+#define __put_user_asm_byte(x,__pu_addr,err) __asm__ __volatile__( "1: strbt %1,[%2],#0\n" "2:\n" " .section .fixup,\"ax\"\n" " .align 2\n" "3: mov %0, %3\n" " b 2b\n" " .previous\n" " .section __ex_table,\"a\"\n" " .align 3\n" " .long 1b, 3b\n" " .previous" : "+r" (err) : "r" (x), "r" (__pu_addr), "i" (-EFAULT) : "cc")
+#ifndef __ARMEB__
+#define __put_user_asm_half(x,__pu_addr,err) ({ unsigned long __temp = (unsigned long)(x); __put_user_asm_byte(__temp, __pu_addr, err); __put_user_asm_byte(__temp >> 8, __pu_addr + 1, err); })
+#else
+#define __put_user_asm_half(x,__pu_addr,err) ({ unsigned long __temp = (unsigned long)(x); __put_user_asm_byte(__temp >> 8, __pu_addr, err); __put_user_asm_byte(__temp, __pu_addr + 1, err); })
+#endif
+#define __put_user_asm_word(x,__pu_addr,err) __asm__ __volatile__( "1: strt %1,[%2],#0\n" "2:\n" " .section .fixup,\"ax\"\n" " .align 2\n" "3: mov %0, %3\n" " b 2b\n" " .previous\n" " .section __ex_table,\"a\"\n" " .align 3\n" " .long 1b, 3b\n" " .previous" : "+r" (err) : "r" (x), "r" (__pu_addr), "i" (-EFAULT) : "cc")
+#ifndef __ARMEB__
+#define __reg_oper0 "%R2"
+#define __reg_oper1 "%Q2"
+#else
+#define __reg_oper0 "%Q2"
+#define __reg_oper1 "%R2"
+#endif
+#define __put_user_asm_dword(x,__pu_addr,err) __asm__ __volatile__( "1: strt " __reg_oper1 ", [%1], #4\n" "2: strt " __reg_oper0 ", [%1], #0\n" "3:\n" " .section .fixup,\"ax\"\n" " .align 2\n" "4: mov %0, %3\n" " b 3b\n" " .previous\n" " .section __ex_table,\"a\"\n" " .align 3\n" " .long 1b, 4b\n" " .long 2b, 4b\n" " .previous" : "+r" (err), "+r" (__pu_addr) : "r" (x), "i" (-EFAULT) : "cc")
+#define __copy_from_user(to,from,n) (memcpy(to, (void __force *)from, n), 0)
+#define __copy_to_user(to,from,n) (memcpy((void __force *)to, from, n), 0)
+#define __clear_user(addr,n) (memset((void __force *)addr, 0, n), 0)
+
+#define __copy_to_user_inatomic __copy_to_user
+#define __copy_from_user_inatomic __copy_from_user
+#define strlen_user(s) strnlen_user(s, ~0UL >> 1)
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unaligned.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unaligned.h
new file mode 100644
index 000000000..8b9b096d9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unaligned.h
@@ -0,0 +1,38 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_UNALIGNED_H
+#define __ASM_ARM_UNALIGNED_H
+
+#include
+
+#define __get_unaligned_2_le(__p) (__p[0] | __p[1] << 8)
+
+#define __get_unaligned_2_be(__p) (__p[0] << 8 | __p[1])
+
+#define __get_unaligned_4_le(__p) (__p[0] | __p[1] << 8 | __p[2] << 16 | __p[3] << 24)
+
+#define __get_unaligned_4_be(__p) (__p[0] << 24 | __p[1] << 16 | __p[2] << 8 | __p[3])
+
+#define __get_unaligned_le(ptr) ({ __typeof__(*(ptr)) __v; __u8 *__p = (__u8 *)(ptr); switch (sizeof(*(ptr))) { case 1: __v = *(ptr); break; case 2: __v = __get_unaligned_2_le(__p); break; case 4: __v = __get_unaligned_4_le(__p); break; case 8: { unsigned int __v1, __v2; __v2 = __get_unaligned_4_le((__p+4)); __v1 = __get_unaligned_4_le(__p); __v = ((unsigned long long)__v2 << 32 | __v1); } break; default: __v = __bug_unaligned_x(__p); break; } __v; })
+
+#define __get_unaligned_be(ptr) ({ __typeof__(*(ptr)) __v; __u8 *__p = (__u8 *)(ptr); switch (sizeof(*(ptr))) { case 1: __v = *(ptr); break; case 2: __v = __get_unaligned_2_be(__p); break; case 4: __v = __get_unaligned_4_be(__p); break; case 8: { unsigned int __v1, __v2; __v2 = __get_unaligned_4_be(__p); __v1 = __get_unaligned_4_be((__p+4)); __v = ((unsigned long long)__v2 << 32 | __v1); } break; default: __v = __bug_unaligned_x(__p); break; } __v; })
+
+#define __put_unaligned_le(val,ptr) ({ switch (sizeof(*(ptr))) { case 1: *(ptr) = (val); break; case 2: __put_unaligned_2_le((val),(__u8 *)(ptr)); break; case 4: __put_unaligned_4_le((val),(__u8 *)(ptr)); break; case 8: __put_unaligned_8_le((val),(__u8 *)(ptr)); break; default: __bug_unaligned_x(ptr); break; } (void) 0; })
+#define __put_unaligned_be(val,ptr) ({ switch (sizeof(*(ptr))) { case 1: *(ptr) = (val); break; case 2: __put_unaligned_2_be((val),(__u8 *)(ptr)); break; case 4: __put_unaligned_4_be((val),(__u8 *)(ptr)); break; case 8: __put_unaligned_8_be((val),(__u8 *)(ptr)); break; default: __bug_unaligned_x(ptr); break; } (void) 0; })
+#ifndef __ARMEB__
+#define get_unaligned __get_unaligned_le
+#define put_unaligned __put_unaligned_le
+#else
+#define get_unaligned __get_unaligned_be
+#define put_unaligned __put_unaligned_be
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unistd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unistd.h
new file mode 100644
index 000000000..9a30ddcb4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/unistd.h
@@ -0,0 +1,359 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_ARM_UNISTD_H
+#define __ASM_ARM_UNISTD_H
+
+#define __NR_OABI_SYSCALL_BASE 0x900000
+
+#if defined(__thumb__) || defined(__ARM_EABI__)
+#define __NR_SYSCALL_BASE 0
+#else
+#define __NR_SYSCALL_BASE __NR_OABI_SYSCALL_BASE
+#endif
+
+#define __NR_restart_syscall (__NR_SYSCALL_BASE+ 0)
+#define __NR_exit (__NR_SYSCALL_BASE+ 1)
+#define __NR_fork (__NR_SYSCALL_BASE+ 2)
+#define __NR_read (__NR_SYSCALL_BASE+ 3)
+#define __NR_write (__NR_SYSCALL_BASE+ 4)
+#define __NR_open (__NR_SYSCALL_BASE+ 5)
+#define __NR_close (__NR_SYSCALL_BASE+ 6)
+
+#define __NR_creat (__NR_SYSCALL_BASE+ 8)
+#define __NR_link (__NR_SYSCALL_BASE+ 9)
+#define __NR_unlink (__NR_SYSCALL_BASE+ 10)
+#define __NR_execve (__NR_SYSCALL_BASE+ 11)
+#define __NR_chdir (__NR_SYSCALL_BASE+ 12)
+#define __NR_time (__NR_SYSCALL_BASE+ 13)
+#define __NR_mknod (__NR_SYSCALL_BASE+ 14)
+#define __NR_chmod (__NR_SYSCALL_BASE+ 15)
+#define __NR_lchown (__NR_SYSCALL_BASE+ 16)
+
+#define __NR_lseek (__NR_SYSCALL_BASE+ 19)
+#define __NR_getpid (__NR_SYSCALL_BASE+ 20)
+#define __NR_mount (__NR_SYSCALL_BASE+ 21)
+#define __NR_umount (__NR_SYSCALL_BASE+ 22)
+#define __NR_setuid (__NR_SYSCALL_BASE+ 23)
+#define __NR_getuid (__NR_SYSCALL_BASE+ 24)
+#define __NR_stime (__NR_SYSCALL_BASE+ 25)
+#define __NR_ptrace (__NR_SYSCALL_BASE+ 26)
+#define __NR_alarm (__NR_SYSCALL_BASE+ 27)
+
+#define __NR_pause (__NR_SYSCALL_BASE+ 29)
+#define __NR_utime (__NR_SYSCALL_BASE+ 30)
+
+#define __NR_access (__NR_SYSCALL_BASE+ 33)
+#define __NR_nice (__NR_SYSCALL_BASE+ 34)
+
+#define __NR_sync (__NR_SYSCALL_BASE+ 36)
+#define __NR_kill (__NR_SYSCALL_BASE+ 37)
+#define __NR_rename (__NR_SYSCALL_BASE+ 38)
+#define __NR_mkdir (__NR_SYSCALL_BASE+ 39)
+#define __NR_rmdir (__NR_SYSCALL_BASE+ 40)
+#define __NR_dup (__NR_SYSCALL_BASE+ 41)
+#define __NR_pipe (__NR_SYSCALL_BASE+ 42)
+#define __NR_times (__NR_SYSCALL_BASE+ 43)
+
+#define __NR_brk (__NR_SYSCALL_BASE+ 45)
+#define __NR_setgid (__NR_SYSCALL_BASE+ 46)
+#define __NR_getgid (__NR_SYSCALL_BASE+ 47)
+
+#define __NR_geteuid (__NR_SYSCALL_BASE+ 49)
+#define __NR_getegid (__NR_SYSCALL_BASE+ 50)
+#define __NR_acct (__NR_SYSCALL_BASE+ 51)
+#define __NR_umount2 (__NR_SYSCALL_BASE+ 52)
+
+#define __NR_ioctl (__NR_SYSCALL_BASE+ 54)
+#define __NR_fcntl (__NR_SYSCALL_BASE+ 55)
+
+#define __NR_setpgid (__NR_SYSCALL_BASE+ 57)
+
+#define __NR_umask (__NR_SYSCALL_BASE+ 60)
+#define __NR_chroot (__NR_SYSCALL_BASE+ 61)
+#define __NR_ustat (__NR_SYSCALL_BASE+ 62)
+#define __NR_dup2 (__NR_SYSCALL_BASE+ 63)
+#define __NR_getppid (__NR_SYSCALL_BASE+ 64)
+#define __NR_getpgrp (__NR_SYSCALL_BASE+ 65)
+#define __NR_setsid (__NR_SYSCALL_BASE+ 66)
+#define __NR_sigaction (__NR_SYSCALL_BASE+ 67)
+
+#define __NR_setreuid (__NR_SYSCALL_BASE+ 70)
+#define __NR_setregid (__NR_SYSCALL_BASE+ 71)
+#define __NR_sigsuspend (__NR_SYSCALL_BASE+ 72)
+#define __NR_sigpending (__NR_SYSCALL_BASE+ 73)
+#define __NR_sethostname (__NR_SYSCALL_BASE+ 74)
+#define __NR_setrlimit (__NR_SYSCALL_BASE+ 75)
+#define __NR_getrlimit (__NR_SYSCALL_BASE+ 76)
+#define __NR_getrusage (__NR_SYSCALL_BASE+ 77)
+#define __NR_gettimeofday (__NR_SYSCALL_BASE+ 78)
+#define __NR_settimeofday (__NR_SYSCALL_BASE+ 79)
+#define __NR_getgroups (__NR_SYSCALL_BASE+ 80)
+#define __NR_setgroups (__NR_SYSCALL_BASE+ 81)
+#define __NR_select (__NR_SYSCALL_BASE+ 82)
+#define __NR_symlink (__NR_SYSCALL_BASE+ 83)
+
+#define __NR_readlink (__NR_SYSCALL_BASE+ 85)
+#define __NR_uselib (__NR_SYSCALL_BASE+ 86)
+#define __NR_swapon (__NR_SYSCALL_BASE+ 87)
+#define __NR_reboot (__NR_SYSCALL_BASE+ 88)
+#define __NR_readdir (__NR_SYSCALL_BASE+ 89)
+#define __NR_mmap (__NR_SYSCALL_BASE+ 90)
+#define __NR_munmap (__NR_SYSCALL_BASE+ 91)
+#define __NR_truncate (__NR_SYSCALL_BASE+ 92)
+#define __NR_ftruncate (__NR_SYSCALL_BASE+ 93)
+#define __NR_fchmod (__NR_SYSCALL_BASE+ 94)
+#define __NR_fchown (__NR_SYSCALL_BASE+ 95)
+#define __NR_getpriority (__NR_SYSCALL_BASE+ 96)
+#define __NR_setpriority (__NR_SYSCALL_BASE+ 97)
+
+#define __NR_statfs (__NR_SYSCALL_BASE+ 99)
+#define __NR_fstatfs (__NR_SYSCALL_BASE+100)
+
+#define __NR_socketcall (__NR_SYSCALL_BASE+102)
+#define __NR_syslog (__NR_SYSCALL_BASE+103)
+#define __NR_setitimer (__NR_SYSCALL_BASE+104)
+#define __NR_getitimer (__NR_SYSCALL_BASE+105)
+#define __NR_stat (__NR_SYSCALL_BASE+106)
+#define __NR_lstat (__NR_SYSCALL_BASE+107)
+#define __NR_fstat (__NR_SYSCALL_BASE+108)
+
+#define __NR_vhangup (__NR_SYSCALL_BASE+111)
+
+#define __NR_syscall (__NR_SYSCALL_BASE+113)
+#define __NR_wait4 (__NR_SYSCALL_BASE+114)
+#define __NR_swapoff (__NR_SYSCALL_BASE+115)
+#define __NR_sysinfo (__NR_SYSCALL_BASE+116)
+#define __NR_ipc (__NR_SYSCALL_BASE+117)
+#define __NR_fsync (__NR_SYSCALL_BASE+118)
+#define __NR_sigreturn (__NR_SYSCALL_BASE+119)
+#define __NR_clone (__NR_SYSCALL_BASE+120)
+#define __NR_setdomainname (__NR_SYSCALL_BASE+121)
+#define __NR_uname (__NR_SYSCALL_BASE+122)
+
+#define __NR_adjtimex (__NR_SYSCALL_BASE+124)
+#define __NR_mprotect (__NR_SYSCALL_BASE+125)
+#define __NR_sigprocmask (__NR_SYSCALL_BASE+126)
+
+#define __NR_init_module (__NR_SYSCALL_BASE+128)
+#define __NR_delete_module (__NR_SYSCALL_BASE+129)
+
+#define __NR_quotactl (__NR_SYSCALL_BASE+131)
+#define __NR_getpgid (__NR_SYSCALL_BASE+132)
+#define __NR_fchdir (__NR_SYSCALL_BASE+133)
+#define __NR_bdflush (__NR_SYSCALL_BASE+134)
+#define __NR_sysfs (__NR_SYSCALL_BASE+135)
+#define __NR_personality (__NR_SYSCALL_BASE+136)
+
+#define __NR_setfsuid (__NR_SYSCALL_BASE+138)
+#define __NR_setfsgid (__NR_SYSCALL_BASE+139)
+#define __NR__llseek (__NR_SYSCALL_BASE+140)
+#define __NR_getdents (__NR_SYSCALL_BASE+141)
+#define __NR__newselect (__NR_SYSCALL_BASE+142)
+#define __NR_flock (__NR_SYSCALL_BASE+143)
+#define __NR_msync (__NR_SYSCALL_BASE+144)
+#define __NR_readv (__NR_SYSCALL_BASE+145)
+#define __NR_writev (__NR_SYSCALL_BASE+146)
+#define __NR_getsid (__NR_SYSCALL_BASE+147)
+#define __NR_fdatasync (__NR_SYSCALL_BASE+148)
+#define __NR__sysctl (__NR_SYSCALL_BASE+149)
+#define __NR_mlock (__NR_SYSCALL_BASE+150)
+#define __NR_munlock (__NR_SYSCALL_BASE+151)
+#define __NR_mlockall (__NR_SYSCALL_BASE+152)
+#define __NR_munlockall (__NR_SYSCALL_BASE+153)
+#define __NR_sched_setparam (__NR_SYSCALL_BASE+154)
+#define __NR_sched_getparam (__NR_SYSCALL_BASE+155)
+#define __NR_sched_setscheduler (__NR_SYSCALL_BASE+156)
+#define __NR_sched_getscheduler (__NR_SYSCALL_BASE+157)
+#define __NR_sched_yield (__NR_SYSCALL_BASE+158)
+#define __NR_sched_get_priority_max (__NR_SYSCALL_BASE+159)
+#define __NR_sched_get_priority_min (__NR_SYSCALL_BASE+160)
+#define __NR_sched_rr_get_interval (__NR_SYSCALL_BASE+161)
+#define __NR_nanosleep (__NR_SYSCALL_BASE+162)
+#define __NR_mremap (__NR_SYSCALL_BASE+163)
+#define __NR_setresuid (__NR_SYSCALL_BASE+164)
+#define __NR_getresuid (__NR_SYSCALL_BASE+165)
+
+#define __NR_poll (__NR_SYSCALL_BASE+168)
+#define __NR_nfsservctl (__NR_SYSCALL_BASE+169)
+#define __NR_setresgid (__NR_SYSCALL_BASE+170)
+#define __NR_getresgid (__NR_SYSCALL_BASE+171)
+#define __NR_prctl (__NR_SYSCALL_BASE+172)
+#define __NR_rt_sigreturn (__NR_SYSCALL_BASE+173)
+#define __NR_rt_sigaction (__NR_SYSCALL_BASE+174)
+#define __NR_rt_sigprocmask (__NR_SYSCALL_BASE+175)
+#define __NR_rt_sigpending (__NR_SYSCALL_BASE+176)
+#define __NR_rt_sigtimedwait (__NR_SYSCALL_BASE+177)
+#define __NR_rt_sigqueueinfo (__NR_SYSCALL_BASE+178)
+#define __NR_rt_sigsuspend (__NR_SYSCALL_BASE+179)
+#define __NR_pread64 (__NR_SYSCALL_BASE+180)
+#define __NR_pwrite64 (__NR_SYSCALL_BASE+181)
+#define __NR_chown (__NR_SYSCALL_BASE+182)
+#define __NR_getcwd (__NR_SYSCALL_BASE+183)
+#define __NR_capget (__NR_SYSCALL_BASE+184)
+#define __NR_capset (__NR_SYSCALL_BASE+185)
+#define __NR_sigaltstack (__NR_SYSCALL_BASE+186)
+#define __NR_sendfile (__NR_SYSCALL_BASE+187)
+
+#define __NR_vfork (__NR_SYSCALL_BASE+190)
+#define __NR_ugetrlimit (__NR_SYSCALL_BASE+191)
+#define __NR_mmap2 (__NR_SYSCALL_BASE+192)
+#define __NR_truncate64 (__NR_SYSCALL_BASE+193)
+#define __NR_ftruncate64 (__NR_SYSCALL_BASE+194)
+#define __NR_stat64 (__NR_SYSCALL_BASE+195)
+#define __NR_lstat64 (__NR_SYSCALL_BASE+196)
+#define __NR_fstat64 (__NR_SYSCALL_BASE+197)
+#define __NR_lchown32 (__NR_SYSCALL_BASE+198)
+#define __NR_getuid32 (__NR_SYSCALL_BASE+199)
+#define __NR_getgid32 (__NR_SYSCALL_BASE+200)
+#define __NR_geteuid32 (__NR_SYSCALL_BASE+201)
+#define __NR_getegid32 (__NR_SYSCALL_BASE+202)
+#define __NR_setreuid32 (__NR_SYSCALL_BASE+203)
+#define __NR_setregid32 (__NR_SYSCALL_BASE+204)
+#define __NR_getgroups32 (__NR_SYSCALL_BASE+205)
+#define __NR_setgroups32 (__NR_SYSCALL_BASE+206)
+#define __NR_fchown32 (__NR_SYSCALL_BASE+207)
+#define __NR_setresuid32 (__NR_SYSCALL_BASE+208)
+#define __NR_getresuid32 (__NR_SYSCALL_BASE+209)
+#define __NR_setresgid32 (__NR_SYSCALL_BASE+210)
+#define __NR_getresgid32 (__NR_SYSCALL_BASE+211)
+#define __NR_chown32 (__NR_SYSCALL_BASE+212)
+#define __NR_setuid32 (__NR_SYSCALL_BASE+213)
+#define __NR_setgid32 (__NR_SYSCALL_BASE+214)
+#define __NR_setfsuid32 (__NR_SYSCALL_BASE+215)
+#define __NR_setfsgid32 (__NR_SYSCALL_BASE+216)
+#define __NR_getdents64 (__NR_SYSCALL_BASE+217)
+#define __NR_pivot_root (__NR_SYSCALL_BASE+218)
+#define __NR_mincore (__NR_SYSCALL_BASE+219)
+#define __NR_madvise (__NR_SYSCALL_BASE+220)
+#define __NR_fcntl64 (__NR_SYSCALL_BASE+221)
+
+#define __NR_gettid (__NR_SYSCALL_BASE+224)
+#define __NR_readahead (__NR_SYSCALL_BASE+225)
+#define __NR_setxattr (__NR_SYSCALL_BASE+226)
+#define __NR_lsetxattr (__NR_SYSCALL_BASE+227)
+#define __NR_fsetxattr (__NR_SYSCALL_BASE+228)
+#define __NR_getxattr (__NR_SYSCALL_BASE+229)
+#define __NR_lgetxattr (__NR_SYSCALL_BASE+230)
+#define __NR_fgetxattr (__NR_SYSCALL_BASE+231)
+#define __NR_listxattr (__NR_SYSCALL_BASE+232)
+#define __NR_llistxattr (__NR_SYSCALL_BASE+233)
+#define __NR_flistxattr (__NR_SYSCALL_BASE+234)
+#define __NR_removexattr (__NR_SYSCALL_BASE+235)
+#define __NR_lremovexattr (__NR_SYSCALL_BASE+236)
+#define __NR_fremovexattr (__NR_SYSCALL_BASE+237)
+#define __NR_tkill (__NR_SYSCALL_BASE+238)
+#define __NR_sendfile64 (__NR_SYSCALL_BASE+239)
+#define __NR_futex (__NR_SYSCALL_BASE+240)
+#define __NR_sched_setaffinity (__NR_SYSCALL_BASE+241)
+#define __NR_sched_getaffinity (__NR_SYSCALL_BASE+242)
+#define __NR_io_setup (__NR_SYSCALL_BASE+243)
+#define __NR_io_destroy (__NR_SYSCALL_BASE+244)
+#define __NR_io_getevents (__NR_SYSCALL_BASE+245)
+#define __NR_io_submit (__NR_SYSCALL_BASE+246)
+#define __NR_io_cancel (__NR_SYSCALL_BASE+247)
+#define __NR_exit_group (__NR_SYSCALL_BASE+248)
+#define __NR_lookup_dcookie (__NR_SYSCALL_BASE+249)
+#define __NR_epoll_create (__NR_SYSCALL_BASE+250)
+#define __NR_epoll_ctl (__NR_SYSCALL_BASE+251)
+#define __NR_epoll_wait (__NR_SYSCALL_BASE+252)
+#define __NR_remap_file_pages (__NR_SYSCALL_BASE+253)
+
+#define __NR_set_tid_address (__NR_SYSCALL_BASE+256)
+#define __NR_timer_create (__NR_SYSCALL_BASE+257)
+#define __NR_timer_settime (__NR_SYSCALL_BASE+258)
+#define __NR_timer_gettime (__NR_SYSCALL_BASE+259)
+#define __NR_timer_getoverrun (__NR_SYSCALL_BASE+260)
+#define __NR_timer_delete (__NR_SYSCALL_BASE+261)
+#define __NR_clock_settime (__NR_SYSCALL_BASE+262)
+#define __NR_clock_gettime (__NR_SYSCALL_BASE+263)
+#define __NR_clock_getres (__NR_SYSCALL_BASE+264)
+#define __NR_clock_nanosleep (__NR_SYSCALL_BASE+265)
+#define __NR_statfs64 (__NR_SYSCALL_BASE+266)
+#define __NR_fstatfs64 (__NR_SYSCALL_BASE+267)
+#define __NR_tgkill (__NR_SYSCALL_BASE+268)
+#define __NR_utimes (__NR_SYSCALL_BASE+269)
+#define __NR_arm_fadvise64_64 (__NR_SYSCALL_BASE+270)
+#define __NR_pciconfig_iobase (__NR_SYSCALL_BASE+271)
+#define __NR_pciconfig_read (__NR_SYSCALL_BASE+272)
+#define __NR_pciconfig_write (__NR_SYSCALL_BASE+273)
+#define __NR_mq_open (__NR_SYSCALL_BASE+274)
+#define __NR_mq_unlink (__NR_SYSCALL_BASE+275)
+#define __NR_mq_timedsend (__NR_SYSCALL_BASE+276)
+#define __NR_mq_timedreceive (__NR_SYSCALL_BASE+277)
+#define __NR_mq_notify (__NR_SYSCALL_BASE+278)
+#define __NR_mq_getsetattr (__NR_SYSCALL_BASE+279)
+#define __NR_waitid (__NR_SYSCALL_BASE+280)
+#define __NR_socket (__NR_SYSCALL_BASE+281)
+#define __NR_bind (__NR_SYSCALL_BASE+282)
+#define __NR_connect (__NR_SYSCALL_BASE+283)
+#define __NR_listen (__NR_SYSCALL_BASE+284)
+#define __NR_accept (__NR_SYSCALL_BASE+285)
+#define __NR_getsockname (__NR_SYSCALL_BASE+286)
+#define __NR_getpeername (__NR_SYSCALL_BASE+287)
+#define __NR_socketpair (__NR_SYSCALL_BASE+288)
+#define __NR_send (__NR_SYSCALL_BASE+289)
+#define __NR_sendto (__NR_SYSCALL_BASE+290)
+#define __NR_recv (__NR_SYSCALL_BASE+291)
+#define __NR_recvfrom (__NR_SYSCALL_BASE+292)
+#define __NR_shutdown (__NR_SYSCALL_BASE+293)
+#define __NR_setsockopt (__NR_SYSCALL_BASE+294)
+#define __NR_getsockopt (__NR_SYSCALL_BASE+295)
+#define __NR_sendmsg (__NR_SYSCALL_BASE+296)
+#define __NR_recvmsg (__NR_SYSCALL_BASE+297)
+#define __NR_semop (__NR_SYSCALL_BASE+298)
+#define __NR_semget (__NR_SYSCALL_BASE+299)
+#define __NR_semctl (__NR_SYSCALL_BASE+300)
+#define __NR_msgsnd (__NR_SYSCALL_BASE+301)
+#define __NR_msgrcv (__NR_SYSCALL_BASE+302)
+#define __NR_msgget (__NR_SYSCALL_BASE+303)
+#define __NR_msgctl (__NR_SYSCALL_BASE+304)
+#define __NR_shmat (__NR_SYSCALL_BASE+305)
+#define __NR_shmdt (__NR_SYSCALL_BASE+306)
+#define __NR_shmget (__NR_SYSCALL_BASE+307)
+#define __NR_shmctl (__NR_SYSCALL_BASE+308)
+#define __NR_add_key (__NR_SYSCALL_BASE+309)
+#define __NR_request_key (__NR_SYSCALL_BASE+310)
+#define __NR_keyctl (__NR_SYSCALL_BASE+311)
+#define __NR_semtimedop (__NR_SYSCALL_BASE+312)
+#define __NR_vserver (__NR_SYSCALL_BASE+313)
+#define __NR_ioprio_set (__NR_SYSCALL_BASE+314)
+#define __NR_ioprio_get (__NR_SYSCALL_BASE+315)
+#define __NR_inotify_init (__NR_SYSCALL_BASE+316)
+#define __NR_inotify_add_watch (__NR_SYSCALL_BASE+317)
+#define __NR_inotify_rm_watch (__NR_SYSCALL_BASE+318)
+#define __NR_mbind (__NR_SYSCALL_BASE+319)
+#define __NR_get_mempolicy (__NR_SYSCALL_BASE+320)
+#define __NR_set_mempolicy (__NR_SYSCALL_BASE+321)
+
+#define __ARM_NR_BASE (__NR_SYSCALL_BASE+0x0f0000)
+#define __ARM_NR_breakpoint (__ARM_NR_BASE+1)
+#define __ARM_NR_cacheflush (__ARM_NR_BASE+2)
+#define __ARM_NR_usr26 (__ARM_NR_BASE+3)
+#define __ARM_NR_usr32 (__ARM_NR_BASE+4)
+#define __ARM_NR_set_tls (__ARM_NR_BASE+5)
+
+#if defined(__ARM_EABI__) && !defined(__KERNEL__)
+#undef __NR_time
+#undef __NR_umount
+#undef __NR_stime
+#undef __NR_alarm
+#undef __NR_utime
+#undef __NR_getrlimit
+#undef __NR_select
+#undef __NR_readdir
+#undef __NR_mmap
+#undef __NR_socketcall
+#undef __NR_syscall
+#undef __NR_ipc
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/user.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/user.h
new file mode 100644
index 000000000..5f258505f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/user.h
@@ -0,0 +1,61 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ARM_USER_H
+#define _ARM_USER_H
+
+#include
+#include
+
+struct user_fp {
+ struct fp_reg {
+ unsigned int sign1:1;
+ unsigned int unused:15;
+ unsigned int sign2:1;
+ unsigned int exponent:14;
+ unsigned int j:1;
+ unsigned int mantissa1:31;
+ unsigned int mantissa0:32;
+ } fpregs[8];
+ unsigned int fpsr:32;
+ unsigned int fpcr:32;
+ unsigned char ftype[8];
+ unsigned int init_flag;
+};
+
+struct user{
+
+ struct pt_regs regs;
+
+ int u_fpvalid;
+
+ unsigned long int u_tsize;
+ unsigned long int u_dsize;
+ unsigned long int u_ssize;
+ unsigned long start_code;
+ unsigned long start_stack;
+ long int signal;
+ int reserved;
+ struct pt_regs * u_ar0;
+
+ unsigned long magic;
+ char u_comm[32];
+ int u_debugreg[8];
+ struct user_fp u_fp;
+ struct user_fp_struct * u_fp0;
+
+};
+#define NBPG PAGE_SIZE
+#define UPAGES 1
+#define HOST_TEXT_START_ADDR (u.start_code)
+#define HOST_STACK_END_ADDR (u.start_stack + u.u_ssize * NBPG)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/vga.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/vga.h
new file mode 100644
index 000000000..7875dbf8f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/asm/vga.h
@@ -0,0 +1,23 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef ASMARM_VGA_H
+#define ASMARM_VGA_H
+
+#include
+#include
+
+#define VGA_MAP_MEM(x,s) (PCIMEM_BASE + (x))
+
+#define vga_readb(x) (*((volatile unsigned char *)x))
+#define vga_writeb(x,y) (*((volatile unsigned char *)y) = (x))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/assert.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/assert.h
new file mode 120000
index 000000000..1572c5b88
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/assert.h
@@ -0,0 +1 @@
+../../../common/include/assert.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/byteswap.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/byteswap.h
new file mode 120000
index 000000000..153ee73e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/byteswap.h
@@ -0,0 +1 @@
+../../../common/include/byteswap.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/cstddef b/ndk/build/platforms/android-1.5/arch-arm/usr/include/cstddef
new file mode 120000
index 000000000..cec20fd6e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/cstddef
@@ -0,0 +1 @@
+../../../common/include/cstddef
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/ctype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/ctype.h
new file mode 120000
index 000000000..f1b315cab
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/ctype.h
@@ -0,0 +1 @@
+../../../common/include/ctype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/dirent.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/dirent.h
new file mode 120000
index 000000000..315be039a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/dirent.h
@@ -0,0 +1 @@
+../../../common/include/dirent.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/dlfcn.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/dlfcn.h
new file mode 120000
index 000000000..5748e5a26
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/dlfcn.h
@@ -0,0 +1 @@
+../../../common/include/dlfcn.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/elf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/elf.h
new file mode 120000
index 000000000..f4e2f5eb3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/elf.h
@@ -0,0 +1 @@
+../../../common/include/elf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/endian.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/endian.h
new file mode 100644
index 000000000..04204ed4c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/endian.h
@@ -0,0 +1,10 @@
+/* $OpenBSD: endian.h,v 1.3 2005/12/13 00:35:23 millert Exp $ */
+
+#ifdef __ARMEB__
+#define _BYTE_ORDER _BIG_ENDIAN
+#else
+#define _BYTE_ORDER _LITTLE_ENDIAN
+#endif
+#define __STRICT_ALIGNMENT
+#include
+#include
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/err.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/err.h
new file mode 120000
index 000000000..de8181626
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/err.h
@@ -0,0 +1 @@
+../../../common/include/err.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/errno.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/errno.h
new file mode 120000
index 000000000..2e638ba63
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/errno.h
@@ -0,0 +1 @@
+../../../common/include/errno.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/fcntl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/fcntl.h
new file mode 120000
index 000000000..cb8c1df93
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/fcntl.h
@@ -0,0 +1 @@
+../../../common/include/fcntl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/features.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/features.h
new file mode 120000
index 000000000..6587ebdd6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/features.h
@@ -0,0 +1 @@
+../../../common/include/features.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/fnmatch.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/fnmatch.h
new file mode 120000
index 000000000..52c0687c3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/fnmatch.h
@@ -0,0 +1 @@
+../../../common/include/fnmatch.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/getopt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/getopt.h
new file mode 120000
index 000000000..857cf2752
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/getopt.h
@@ -0,0 +1 @@
+../../../common/include/getopt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/grp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/grp.h
new file mode 120000
index 000000000..c5994517a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/grp.h
@@ -0,0 +1 @@
+../../../common/include/grp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/inttypes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/inttypes.h
new file mode 120000
index 000000000..5283d6086
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/inttypes.h
@@ -0,0 +1 @@
+../../../common/include/inttypes.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/jni.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/jni.h
new file mode 120000
index 000000000..e49af212e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/jni.h
@@ -0,0 +1 @@
+../../../common/include/jni.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/lastlog.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/lastlog.h
new file mode 120000
index 000000000..fe63cd385
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/lastlog.h
@@ -0,0 +1 @@
+../../../common/include/lastlog.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/libgen.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/libgen.h
new file mode 120000
index 000000000..0f626b66b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/libgen.h
@@ -0,0 +1 @@
+../../../common/include/libgen.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/limits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/limits.h
new file mode 120000
index 000000000..60f67bfa1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/limits.h
@@ -0,0 +1 @@
+../../../common/include/limits.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/a.out.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/a.out.h
new file mode 120000
index 000000000..e1bffda7f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/a.out.h
@@ -0,0 +1 @@
+../../../../common/include/linux/a.out.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/aio_abi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/aio_abi.h
new file mode 120000
index 000000000..cd9448541
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/aio_abi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/aio_abi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/akm8976.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/akm8976.h
new file mode 120000
index 000000000..1d8b8583e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/akm8976.h
@@ -0,0 +1 @@
+../../../../common/include/linux/akm8976.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_alarm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_alarm.h
new file mode 120000
index 000000000..383aabd96
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_alarm.h
@@ -0,0 +1 @@
+../../../../common/include/linux/android_alarm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_pmem.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_pmem.h
new file mode 120000
index 000000000..2485ad888
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_pmem.h
@@ -0,0 +1 @@
+../../../../common/include/linux/android_pmem.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_power.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_power.h
new file mode 120000
index 000000000..05f970a62
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/android_power.h
@@ -0,0 +1 @@
+../../../../common/include/linux/android_power.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/apm_bios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/apm_bios.h
new file mode 120000
index 000000000..cbcfb5a05
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/apm_bios.h
@@ -0,0 +1 @@
+../../../../common/include/linux/apm_bios.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ashmem.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ashmem.h
new file mode 120000
index 000000000..3cc18816b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ashmem.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ashmem.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ata.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ata.h
new file mode 120000
index 000000000..4640b5f21
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ata.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ata.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atm.h
new file mode 120000
index 000000000..377242f13
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atm.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmapi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmapi.h
new file mode 120000
index 000000000..0d7f0859e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmapi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atmapi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmdev.h
new file mode 120000
index 000000000..f1f9a5fe6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmdev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atmdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmioc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmioc.h
new file mode 120000
index 000000000..3b1e71165
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmioc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atmioc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmppp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmppp.h
new file mode 120000
index 000000000..785c8fb8b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmppp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atmppp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmsap.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmsap.h
new file mode 120000
index 000000000..bc0f5a875
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/atmsap.h
@@ -0,0 +1 @@
+../../../../common/include/linux/atmsap.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/attribute_container.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/attribute_container.h
new file mode 120000
index 000000000..38344818f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/attribute_container.h
@@ -0,0 +1 @@
+../../../../common/include/linux/attribute_container.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auto_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auto_fs.h
new file mode 120000
index 000000000..8d3e7b9ad
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auto_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/auto_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/autoconf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/autoconf.h
new file mode 120000
index 000000000..41a58f5e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/autoconf.h
@@ -0,0 +1 @@
+../../../../common/include/linux/autoconf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auxvec.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auxvec.h
new file mode 120000
index 000000000..56022200b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/auxvec.h
@@ -0,0 +1 @@
+../../../../common/include/linux/auxvec.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/backing-dev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/backing-dev.h
new file mode 120000
index 000000000..427296e09
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/backing-dev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/backing-dev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binder.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binder.h
new file mode 120000
index 000000000..39fcca70d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binder.h
@@ -0,0 +1 @@
+../../../../common/include/linux/binder.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binfmts.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binfmts.h
new file mode 120000
index 000000000..d938c2fb3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/binfmts.h
@@ -0,0 +1 @@
+../../../../common/include/linux/binfmts.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bio.h
new file mode 120000
index 000000000..9a8ee715b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/bio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitmap.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitmap.h
new file mode 120000
index 000000000..5db6297d9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitmap.h
@@ -0,0 +1 @@
+../../../../common/include/linux/bitmap.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitops.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitops.h
new file mode 120000
index 000000000..5d0fcbbb0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/bitops.h
@@ -0,0 +1 @@
+../../../../common/include/linux/bitops.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkdev.h
new file mode 120000
index 000000000..fb45957cd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkdev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/blkdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkpg.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkpg.h
new file mode 120000
index 000000000..bc5f38fe1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blkpg.h
@@ -0,0 +1 @@
+../../../../common/include/linux/blkpg.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blockgroup_lock.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blockgroup_lock.h
new file mode 120000
index 000000000..587f7f17f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/blockgroup_lock.h
@@ -0,0 +1 @@
+../../../../common/include/linux/blockgroup_lock.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/big_endian.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/big_endian.h
new file mode 120000
index 000000000..ce9724603
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/big_endian.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/byteorder/big_endian.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/generic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/generic.h
new file mode 120000
index 000000000..d86570164
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/generic.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/byteorder/generic.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/little_endian.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/little_endian.h
new file mode 120000
index 000000000..9b117fa2f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/little_endian.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/byteorder/little_endian.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swab.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swab.h
new file mode 120000
index 000000000..b3da56ea4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swab.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/byteorder/swab.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swabb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swabb.h
new file mode 120000
index 000000000..d6d7ade85
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/byteorder/swabb.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/byteorder/swabb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cache.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cache.h
new file mode 120000
index 000000000..74ed7c9d0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cache.h
@@ -0,0 +1 @@
+../../../../common/include/linux/cache.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/calc64.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/calc64.h
new file mode 120000
index 000000000..e12ad5436
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/calc64.h
@@ -0,0 +1 @@
+../../../../common/include/linux/calc64.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capability.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capability.h
new file mode 120000
index 000000000..9674918fc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capability.h
@@ -0,0 +1 @@
+../../../../common/include/linux/capability.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capi.h
new file mode 120000
index 000000000..e937bc117
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/capi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/capi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdev.h
new file mode 120000
index 000000000..aa3f937f3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/cdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdrom.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdrom.h
new file mode 120000
index 000000000..f8a7cfe7c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cdrom.h
@@ -0,0 +1 @@
+../../../../common/include/linux/cdrom.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/circ_buf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/circ_buf.h
new file mode 120000
index 000000000..ada0bcad6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/circ_buf.h
@@ -0,0 +1 @@
+../../../../common/include/linux/circ_buf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/clk.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/clk.h
new file mode 120000
index 000000000..246f4ad3c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/clk.h
@@ -0,0 +1 @@
+../../../../common/include/linux/clk.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda.h
new file mode 120000
index 000000000..e577be554
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda.h
@@ -0,0 +1 @@
+../../../../common/include/linux/coda.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda_fs_i.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda_fs_i.h
new file mode 120000
index 000000000..bd7a50761
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/coda_fs_i.h
@@ -0,0 +1 @@
+../../../../common/include/linux/coda_fs_i.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compat.h
new file mode 120000
index 000000000..c323a3266
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compat.h
@@ -0,0 +1 @@
+../../../../common/include/linux/compat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler-gcc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler-gcc.h
new file mode 120000
index 000000000..6609cf6e0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler-gcc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/compiler-gcc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler.h
new file mode 120000
index 000000000..c3c0a7ce7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/compiler.h
@@ -0,0 +1 @@
+../../../../common/include/linux/compiler.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/completion.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/completion.h
new file mode 120000
index 000000000..af2804448
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/completion.h
@@ -0,0 +1 @@
+../../../../common/include/linux/completion.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/config.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/config.h
new file mode 120000
index 000000000..71028f693
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/config.h
@@ -0,0 +1 @@
+../../../../common/include/linux/config.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/console_struct.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/console_struct.h
new file mode 120000
index 000000000..7aa851410
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/console_struct.h
@@ -0,0 +1 @@
+../../../../common/include/linux/console_struct.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpu.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpu.h
new file mode 120000
index 000000000..2608247f7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpu.h
@@ -0,0 +1 @@
+../../../../common/include/linux/cpu.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpumask.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpumask.h
new file mode 120000
index 000000000..c8f6de001
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/cpumask.h
@@ -0,0 +1 @@
+../../../../common/include/linux/cpumask.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ctype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ctype.h
new file mode 120000
index 000000000..e008d1e0d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ctype.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ctype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dccp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dccp.h
new file mode 120000
index 000000000..bc11d4009
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dccp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/dccp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/debug_locks.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/debug_locks.h
new file mode 120000
index 000000000..561a5bc27
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/debug_locks.h
@@ -0,0 +1 @@
+../../../../common/include/linux/debug_locks.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/delay.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/delay.h
new file mode 120000
index 000000000..d934a131b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/delay.h
@@ -0,0 +1 @@
+../../../../common/include/linux/delay.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/device.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/device.h
new file mode 120000
index 000000000..2440aba4b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/device.h
@@ -0,0 +1 @@
+../../../../common/include/linux/device.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dirent.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dirent.h
new file mode 120000
index 000000000..f16f4a4e3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dirent.h
@@ -0,0 +1 @@
+../../../../common/include/linux/dirent.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dm-ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dm-ioctl.h
new file mode 120000
index 000000000..d7305d2d1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dm-ioctl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/dm-ioctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dma-mapping.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dma-mapping.h
new file mode 120000
index 000000000..d8f5664b9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dma-mapping.h
@@ -0,0 +1 @@
+../../../../common/include/linux/dma-mapping.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dmaengine.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dmaengine.h
new file mode 120000
index 000000000..31efa05eb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/dmaengine.h
@@ -0,0 +1 @@
+../../../../common/include/linux/dmaengine.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_dir.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_dir.h
new file mode 120000
index 000000000..5aae574e0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_dir.h
@@ -0,0 +1 @@
+../../../../common/include/linux/efs_dir.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_i.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_i.h
new file mode 120000
index 000000000..1ea12f651
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_i.h
@@ -0,0 +1 @@
+../../../../common/include/linux/efs_fs_i.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_sb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_sb.h
new file mode 120000
index 000000000..9ece7e1c1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/efs_fs_sb.h
@@ -0,0 +1 @@
+../../../../common/include/linux/efs_fs_sb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elevator.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elevator.h
new file mode 120000
index 000000000..a15375fc0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elevator.h
@@ -0,0 +1 @@
+../../../../common/include/linux/elevator.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf-em.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf-em.h
new file mode 120000
index 000000000..a70534cae
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf-em.h
@@ -0,0 +1 @@
+../../../../common/include/linux/elf-em.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf.h
new file mode 120000
index 000000000..4455674a5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/elf.h
@@ -0,0 +1 @@
+../../../../common/include/linux/elf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/err.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/err.h
new file mode 120000
index 000000000..7bc3976af
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/err.h
@@ -0,0 +1 @@
+../../../../common/include/linux/err.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errno.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errno.h
new file mode 120000
index 000000000..17901cf06
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errno.h
@@ -0,0 +1 @@
+../../../../common/include/linux/errno.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errqueue.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errqueue.h
new file mode 120000
index 000000000..f8576790e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/errqueue.h
@@ -0,0 +1 @@
+../../../../common/include/linux/errqueue.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/etherdevice.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/etherdevice.h
new file mode 120000
index 000000000..c6fc65782
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/etherdevice.h
@@ -0,0 +1 @@
+../../../../common/include/linux/etherdevice.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext2_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext2_fs.h
new file mode 120000
index 000000000..6d1ef488a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext2_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ext2_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext3_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext3_fs.h
new file mode 120000
index 000000000..401d88443
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ext3_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ext3_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fadvise.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fadvise.h
new file mode 120000
index 000000000..28391d0af
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fadvise.h
@@ -0,0 +1 @@
+../../../../common/include/linux/fadvise.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fb.h
new file mode 120000
index 000000000..678e85bb1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fb.h
@@ -0,0 +1 @@
+../../../../common/include/linux/fb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fcntl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fcntl.h
new file mode 120000
index 000000000..628a4814b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fcntl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/fcntl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fd.h
new file mode 120000
index 000000000..27d6d086d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fd.h
@@ -0,0 +1 @@
+../../../../common/include/linux/fd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/file.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/file.h
new file mode 120000
index 000000000..d063b5ed0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/file.h
@@ -0,0 +1 @@
+../../../../common/include/linux/file.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/filter.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/filter.h
new file mode 120000
index 000000000..54c78a329
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/filter.h
@@ -0,0 +1 @@
+../../../../common/include/linux/filter.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fs.h
new file mode 120000
index 000000000..c72717dac
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ftape.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ftape.h
new file mode 120000
index 000000000..59efd2b7d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ftape.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ftape.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/futex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/futex.h
new file mode 120000
index 000000000..cbfdedb03
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/futex.h
@@ -0,0 +1 @@
+../../../../common/include/linux/futex.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/genhd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/genhd.h
new file mode 120000
index 000000000..4182ac660
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/genhd.h
@@ -0,0 +1 @@
+../../../../common/include/linux/genhd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/gfp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/gfp.h
new file mode 120000
index 000000000..955489ee2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/gfp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/gfp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hardirq.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hardirq.h
new file mode 120000
index 000000000..01128bd24
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hardirq.h
@@ -0,0 +1 @@
+../../../../common/include/linux/hardirq.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdlc/ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdlc/ioctl.h
new file mode 120000
index 000000000..7679e3621
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdlc/ioctl.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/hdlc/ioctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdreg.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdreg.h
new file mode 120000
index 000000000..35aea046e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdreg.h
@@ -0,0 +1 @@
+../../../../common/include/linux/hdreg.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdsmart.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdsmart.h
new file mode 120000
index 000000000..383f58c00
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hdsmart.h
@@ -0,0 +1 @@
+../../../../common/include/linux/hdsmart.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/highmem.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/highmem.h
new file mode 120000
index 000000000..0f41fc760
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/highmem.h
@@ -0,0 +1 @@
+../../../../common/include/linux/highmem.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hil.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hil.h
new file mode 120000
index 000000000..2bee8bb42
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/hil.h
@@ -0,0 +1 @@
+../../../../common/include/linux/hil.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/i2c.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/i2c.h
new file mode 120000
index 000000000..514ff4367
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/i2c.h
@@ -0,0 +1 @@
+../../../../common/include/linux/i2c.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/icmp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/icmp.h
new file mode 120000
index 000000000..87771a7d3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/icmp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/icmp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if.h
new file mode 120000
index 000000000..176aae68b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arcnet.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arcnet.h
new file mode 120000
index 000000000..0d04ae329
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arcnet.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_arcnet.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arp.h
new file mode 120000
index 000000000..536a14260
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_arp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_arp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_bridge.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_bridge.h
new file mode 120000
index 000000000..ad36ad55a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_bridge.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_bridge.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ether.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ether.h
new file mode 120000
index 000000000..4dc3348b9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ether.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_ether.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fc.h
new file mode 120000
index 000000000..087ec1999
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_fc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fddi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fddi.h
new file mode 120000
index 000000000..6c439adaa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_fddi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_fddi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_hippi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_hippi.h
new file mode 120000
index 000000000..f4febf917
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_hippi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_hippi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_packet.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_packet.h
new file mode 120000
index 000000000..d48d404e6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_packet.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_packet.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ppp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ppp.h
new file mode 120000
index 000000000..1c0292e64
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_ppp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_ppp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tr.h
new file mode 120000
index 000000000..115cd174f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tr.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_tr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tun.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tun.h
new file mode 120000
index 000000000..f127941ae
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_tun.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_tun.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_vlan.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_vlan.h
new file mode 120000
index 000000000..f20fce094
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/if_vlan.h
@@ -0,0 +1 @@
+../../../../common/include/linux/if_vlan.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in.h
new file mode 120000
index 000000000..0e127e07b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in.h
@@ -0,0 +1 @@
+../../../../common/include/linux/in.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in6.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in6.h
new file mode 120000
index 000000000..18c31307b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/in6.h
@@ -0,0 +1 @@
+../../../../common/include/linux/in6.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/init.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/init.h
new file mode 120000
index 000000000..488bb0a26
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/init.h
@@ -0,0 +1 @@
+../../../../common/include/linux/init.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/inotify.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/inotify.h
new file mode 120000
index 000000000..41670ad7b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/inotify.h
@@ -0,0 +1 @@
+../../../../common/include/linux/inotify.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/input.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/input.h
new file mode 120000
index 000000000..423edd7e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/input.h
@@ -0,0 +1 @@
+../../../../common/include/linux/input.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/interrupt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/interrupt.h
new file mode 120000
index 000000000..b5cd63cad
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/interrupt.h
@@ -0,0 +1 @@
+../../../../common/include/linux/interrupt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioctl.h
new file mode 120000
index 000000000..b30e47983
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioctl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ioctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioport.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioport.h
new file mode 120000
index 000000000..d90526dfd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioport.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ioport.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioprio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioprio.h
new file mode 120000
index 000000000..1634241b6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ioprio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ioprio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ip.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ip.h
new file mode 120000
index 000000000..e89967ba5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ip.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ip.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipc.h
new file mode 120000
index 000000000..60f3881f3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ipc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_msgdefs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_msgdefs.h
new file mode 120000
index 000000000..2cfe5ac1d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_msgdefs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ipmi_msgdefs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_smi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_smi.h
new file mode 120000
index 000000000..9a796a2ee
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipmi_smi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ipmi_smi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipx.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipx.h
new file mode 120000
index 000000000..dd5d4b97c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ipx.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ipx.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq.h
new file mode 120000
index 000000000..aa6cf1a29
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq.h
@@ -0,0 +1 @@
+../../../../common/include/linux/irq.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq_cpustat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq_cpustat.h
new file mode 120000
index 000000000..4a329b48e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irq_cpustat.h
@@ -0,0 +1 @@
+../../../../common/include/linux/irq_cpustat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqflags.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqflags.h
new file mode 120000
index 000000000..fa8088652
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqflags.h
@@ -0,0 +1 @@
+../../../../common/include/linux/irqflags.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqreturn.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqreturn.h
new file mode 120000
index 000000000..739fa623b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/irqreturn.h
@@ -0,0 +1 @@
+../../../../common/include/linux/irqreturn.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jbd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jbd.h
new file mode 120000
index 000000000..9594286b1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jbd.h
@@ -0,0 +1 @@
+../../../../common/include/linux/jbd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jiffies.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jiffies.h
new file mode 120000
index 000000000..5accf6acc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/jiffies.h
@@ -0,0 +1 @@
+../../../../common/include/linux/jiffies.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kd.h
new file mode 120000
index 000000000..e7005fac5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kd.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kdev_t.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kdev_t.h
new file mode 120000
index 000000000..fffcdac06
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kdev_t.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kdev_t.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel.h
new file mode 120000
index 000000000..4b3447cca
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kernel.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel_stat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel_stat.h
new file mode 120000
index 000000000..2f1598bb2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernel_stat.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kernel_stat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernelcapi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernelcapi.h
new file mode 120000
index 000000000..78f09ac7d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kernelcapi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kernelcapi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kexec.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kexec.h
new file mode 120000
index 000000000..883b34ff3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kexec.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kexec.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/key.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/key.h
new file mode 120000
index 000000000..a43f262aa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/key.h
@@ -0,0 +1 @@
+../../../../common/include/linux/key.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keyboard.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keyboard.h
new file mode 120000
index 000000000..f1e952c42
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keyboard.h
@@ -0,0 +1 @@
+../../../../common/include/linux/keyboard.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keychord.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keychord.h
new file mode 120000
index 000000000..4af7a30ab
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/keychord.h
@@ -0,0 +1 @@
+../../../../common/include/linux/keychord.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/klist.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/klist.h
new file mode 120000
index 000000000..6c121e739
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/klist.h
@@ -0,0 +1 @@
+../../../../common/include/linux/klist.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kmod.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kmod.h
new file mode 120000
index 000000000..0fc11ced5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kmod.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kmod.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kobject.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kobject.h
new file mode 120000
index 000000000..1e2eb82c7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kobject.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kobject.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kref.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kref.h
new file mode 120000
index 000000000..84f0760c4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/kref.h
@@ -0,0 +1 @@
+../../../../common/include/linux/kref.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ktime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ktime.h
new file mode 120000
index 000000000..bd9e539b4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ktime.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ktime.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/limits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/limits.h
new file mode 120000
index 000000000..998a2f3b8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/limits.h
@@ -0,0 +1 @@
+../../../../common/include/linux/limits.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/linkage.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/linkage.h
new file mode 120000
index 000000000..9981e4936
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/linkage.h
@@ -0,0 +1 @@
+../../../../common/include/linux/linkage.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/list.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/list.h
new file mode 120000
index 000000000..8b5214fb0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/list.h
@@ -0,0 +1 @@
+../../../../common/include/linux/list.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/nlm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/nlm.h
new file mode 120000
index 000000000..1f7029766
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/nlm.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/lockd/nlm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/xdr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/xdr.h
new file mode 120000
index 000000000..59987cff5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockd/xdr.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/lockd/xdr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockdep.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockdep.h
new file mode 120000
index 000000000..6a6ae87ee
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/lockdep.h
@@ -0,0 +1 @@
+../../../../common/include/linux/lockdep.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/loop.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/loop.h
new file mode 120000
index 000000000..6c9121574
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/loop.h
@@ -0,0 +1 @@
+../../../../common/include/linux/loop.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/magic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/magic.h
new file mode 120000
index 000000000..afafcfd7b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/magic.h
@@ -0,0 +1 @@
+../../../../common/include/linux/magic.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/major.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/major.h
new file mode 120000
index 000000000..f08b244ee
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/major.h
@@ -0,0 +1 @@
+../../../../common/include/linux/major.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mc146818rtc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mc146818rtc.h
new file mode 120000
index 000000000..42867412d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mc146818rtc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mc146818rtc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mca.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mca.h
new file mode 120000
index 000000000..1f34bde51
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mca.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mca.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempolicy.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempolicy.h
new file mode 120000
index 000000000..2690b14b9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempolicy.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mempolicy.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempool.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempool.h
new file mode 120000
index 000000000..eaed02685
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mempool.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mempool.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/miscdevice.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/miscdevice.h
new file mode 120000
index 000000000..7de33424a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/miscdevice.h
@@ -0,0 +1 @@
+../../../../common/include/linux/miscdevice.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mm.h
new file mode 120000
index 000000000..111cc153c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mm.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/card.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/card.h
new file mode 120000
index 000000000..0a25330b5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/card.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mmc/card.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/host.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/host.h
new file mode 120000
index 000000000..61ab0f6cf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/host.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mmc/host.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/mmc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/mmc.h
new file mode 120000
index 000000000..ca8b23ea8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmc/mmc.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mmc/mmc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmzone.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmzone.h
new file mode 120000
index 000000000..6bd8d9785
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mmzone.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mmzone.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mod_devicetable.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mod_devicetable.h
new file mode 120000
index 000000000..1104eb522
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mod_devicetable.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mod_devicetable.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/module.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/module.h
new file mode 120000
index 000000000..93b3b1909
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/module.h
@@ -0,0 +1 @@
+../../../../common/include/linux/module.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/moduleparam.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/moduleparam.h
new file mode 120000
index 000000000..1f544b760
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/moduleparam.h
@@ -0,0 +1 @@
+../../../../common/include/linux/moduleparam.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mount.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mount.h
new file mode 120000
index 000000000..5ac8a4235
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mount.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mount.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msdos_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msdos_fs.h
new file mode 120000
index 000000000..de01ab35a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msdos_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/msdos_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msg.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msg.h
new file mode 120000
index 000000000..4b5c4f953
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msg.h
@@ -0,0 +1 @@
+../../../../common/include/linux/msg.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_adsp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_adsp.h
new file mode 120000
index 000000000..620ab8d77
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_adsp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/msm_adsp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_audio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_audio.h
new file mode 120000
index 000000000..730a8315d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_audio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/msm_audio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_mdp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_mdp.h
new file mode 120000
index 000000000..d4ff40924
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/msm_mdp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/msm_mdp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mt9t013.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mt9t013.h
new file mode 120000
index 000000000..8a2b5c084
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mt9t013.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mt9t013.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/bbm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/bbm.h
new file mode 120000
index 000000000..d2d24c5df
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/bbm.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/bbm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/blktrans.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/blktrans.h
new file mode 120000
index 000000000..f16b49794
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/blktrans.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/blktrans.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi.h
new file mode 120000
index 000000000..468e5e890
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/cfi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi_endian.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi_endian.h
new file mode 120000
index 000000000..3f9e2873b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/cfi_endian.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/cfi_endian.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/compatmac.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/compatmac.h
new file mode 120000
index 000000000..ed024580d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/compatmac.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/compatmac.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/flashchip.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/flashchip.h
new file mode 120000
index 000000000..96a349d27
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/flashchip.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/flashchip.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/map.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/map.h
new file mode 120000
index 000000000..fee246522
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/map.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/map.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/mtd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/mtd.h
new file mode 120000
index 000000000..7821ca4a5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/mtd.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/mtd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand.h
new file mode 120000
index 000000000..00fe26e8b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/nand.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand_ecc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand_ecc.h
new file mode 120000
index 000000000..3c780f277
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nand_ecc.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/nand_ecc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nftl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nftl.h
new file mode 120000
index 000000000..b68add435
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/nftl.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/nftl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/onenand_regs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/onenand_regs.h
new file mode 120000
index 000000000..cf98f5ec6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/onenand_regs.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/onenand_regs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/partitions.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/partitions.h
new file mode 120000
index 000000000..1943ac43c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtd/partitions.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/mtd/partitions.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtio.h
new file mode 120000
index 000000000..e4a665b05
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mtio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mtio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex-debug.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex-debug.h
new file mode 120000
index 000000000..b03b89e56
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex-debug.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mutex-debug.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex.h
new file mode 120000
index 000000000..adaf51cd0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/mutex.h
@@ -0,0 +1 @@
+../../../../common/include/linux/mutex.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp.h
new file mode 120000
index 000000000..36de989a2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ncp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_mount.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_mount.h
new file mode 120000
index 000000000..d8e6b48a7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_mount.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ncp_mount.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_no.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_no.h
new file mode 120000
index 000000000..4e59a2b8d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ncp_no.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ncp_no.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/net.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/net.h
new file mode 120000
index 000000000..9ff68ce83
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/net.h
@@ -0,0 +1 @@
+../../../../common/include/linux/net.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netdevice.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netdevice.h
new file mode 120000
index 000000000..103b2df7a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netdevice.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netdevice.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter.h
new file mode 120000
index 000000000..81c93281c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netfilter.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_common.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_common.h
new file mode 120000
index 000000000..840faca97
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_common.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nf_conntrack_common.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_ftp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_ftp.h
new file mode 120000
index 000000000..3a8e544a4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_ftp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nf_conntrack_ftp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_sctp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_sctp.h
new file mode 120000
index 000000000..17c5b2569
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_sctp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nf_conntrack_sctp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tcp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tcp.h
new file mode 120000
index 000000000..483187dbb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tcp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nf_conntrack_tcp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tuple_common.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tuple_common.h
new file mode 120000
index 000000000..2335e586e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nf_conntrack_tuple_common.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nf_conntrack_tuple_common.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink.h
new file mode 120000
index 000000000..434215d46
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nfnetlink.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink_conntrack.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink_conntrack.h
new file mode 120000
index 000000000..87cc812d7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/nfnetlink_conntrack.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/nfnetlink_conntrack.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/x_tables.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/x_tables.h
new file mode 120000
index 000000000..d2b974679
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/x_tables.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/x_tables.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CLASSIFY.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CLASSIFY.h
new file mode 120000
index 000000000..a3b868a81
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CLASSIFY.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_CLASSIFY.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNMARK.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNMARK.h
new file mode 120000
index 000000000..2b7e19817
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNMARK.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_CONNMARK.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNSECMARK.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNSECMARK.h
new file mode 120000
index 000000000..725dafb93
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_CONNSECMARK.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_CONNSECMARK.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_MARK.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_MARK.h
new file mode 120000
index 000000000..eaf3cd75c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_MARK.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_MARK.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_NFQUEUE.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_NFQUEUE.h
new file mode 120000
index 000000000..851f5718b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_NFQUEUE.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_NFQUEUE.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_SECMARK.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_SECMARK.h
new file mode 120000
index 000000000..02dfc1b95
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_SECMARK.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_SECMARK.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_comment.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_comment.h
new file mode 120000
index 000000000..141f426b7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_comment.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_comment.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connbytes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connbytes.h
new file mode 120000
index 000000000..7e67ee902
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connbytes.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_connbytes.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connmark.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connmark.h
new file mode 120000
index 000000000..2f70b9481
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_connmark.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_connmark.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_conntrack.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_conntrack.h
new file mode 120000
index 000000000..04a17298d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_conntrack.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_conntrack.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_dccp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_dccp.h
new file mode 120000
index 000000000..6bdc874fe
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_dccp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_dccp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_esp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_esp.h
new file mode 120000
index 000000000..a27d0ccc1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_esp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_esp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_helper.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_helper.h
new file mode 120000
index 000000000..6b958dbe0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_helper.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_helper.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_length.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_length.h
new file mode 120000
index 000000000..680ef6be9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_length.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_length.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_limit.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_limit.h
new file mode 120000
index 000000000..24bce989f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_limit.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_limit.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mac.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mac.h
new file mode 120000
index 000000000..24af1fc8e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mac.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_mac.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mark.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mark.h
new file mode 120000
index 000000000..6ec390fb7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_mark.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_mark.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_multiport.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_multiport.h
new file mode 120000
index 000000000..80b337dd5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_multiport.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_multiport.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_physdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_physdev.h
new file mode 120000
index 000000000..c6ad18cc8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_physdev.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_physdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_pkttype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_pkttype.h
new file mode 120000
index 000000000..3551c0dc5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_pkttype.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_pkttype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_quota.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_quota.h
new file mode 120000
index 000000000..fc9f8b079
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_quota.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_quota.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_realm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_realm.h
new file mode 120000
index 000000000..7c0e5f6ba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_realm.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_realm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_sctp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_sctp.h
new file mode 120000
index 000000000..cede7c74f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_sctp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_sctp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_state.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_state.h
new file mode 120000
index 000000000..3f2ee9136
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_state.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_state.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_statistic.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_statistic.h
new file mode 120000
index 000000000..dc1fe251b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_statistic.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_statistic.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_string.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_string.h
new file mode 120000
index 000000000..c19bebeda
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_string.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_string.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpmss.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpmss.h
new file mode 120000
index 000000000..90cf9d5bf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpmss.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_tcpmss.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpudp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpudp.h
new file mode 120000
index 000000000..4e3f6b5f6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter/xt_tcpudp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter/xt_tcpudp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp.h
new file mode 120000
index 000000000..e6172effe
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netfilter_arp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp/arp_tables.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp/arp_tables.h
new file mode 120000
index 000000000..b31b8c2ae
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_arp/arp_tables.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_arp/arp_tables.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_bridge.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_bridge.h
new file mode 120000
index 000000000..f58204037
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_bridge.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netfilter_bridge.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4.h
new file mode 120000
index 000000000..1daca652d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netfilter_ipv4.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack.h
new file mode 120000
index 000000000..841b2e901
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_conntrack.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack_tuple.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack_tuple.h
new file mode 120000
index 000000000..109ccef8a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_conntrack_tuple.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_conntrack_tuple.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat.h
new file mode 120000
index 000000000..9b17b2278
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_nat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat_rule.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat_rule.h
new file mode 120000
index 000000000..fe78e7fec
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_nat_rule.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_nat_rule.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_queue.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_queue.h
new file mode 120000
index 000000000..3ea52cae2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_queue.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_queue.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_tables.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_tables.h
new file mode 120000
index 000000000..0f8460d18
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ip_tables.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ip_tables.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_CLASSIFY.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_CLASSIFY.h
new file mode 120000
index 000000000..f9084380b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_CLASSIFY.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_CLASSIFY.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_DSCP.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_DSCP.h
new file mode 120000
index 000000000..29058d280
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_DSCP.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_DSCP.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ECN.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ECN.h
new file mode 120000
index 000000000..fc1128cea
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ECN.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_ECN.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_LOG.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_LOG.h
new file mode 120000
index 000000000..b5dbb5581
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_LOG.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_LOG.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_NFQUEUE.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_NFQUEUE.h
new file mode 120000
index 000000000..36862063a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_NFQUEUE.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_NFQUEUE.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_REJECT.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_REJECT.h
new file mode 120000
index 000000000..b3f1023c4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_REJECT.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_REJECT.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TCPMSS.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TCPMSS.h
new file mode 120000
index 000000000..fd24f6aba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TCPMSS.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_TCPMSS.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TOS.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TOS.h
new file mode 120000
index 000000000..bb1a24334
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TOS.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_TOS.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TTL.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TTL.h
new file mode 120000
index 000000000..0ad13036f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_TTL.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_TTL.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ULOG.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ULOG.h
new file mode 120000
index 000000000..9cc45e518
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ULOG.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_ULOG.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_addrtype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_addrtype.h
new file mode 120000
index 000000000..3b37d0bb5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_addrtype.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_addrtype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ah.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ah.h
new file mode 120000
index 000000000..4b846fa70
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_ah.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_ah.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_comment.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_comment.h
new file mode 120000
index 000000000..96a07eacc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_comment.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_comment.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_connbytes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_connbytes.h
new file mode 120000
index 000000000..76120e8e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_connbytes.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_connbytes.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dccp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dccp.h
new file mode 120000
index 000000000..9be071cc5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dccp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_dccp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dscp_.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dscp_.h
new file mode 120000
index 000000000..75879c3e3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_dscp_.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_dscp_.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_esp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_esp.h
new file mode 120000
index 000000000..9830294ab
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_esp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_esp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_hashlimit.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_hashlimit.h
new file mode 120000
index 000000000..67cbcc107
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_hashlimit.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_hashlimit.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_helper.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_helper.h
new file mode 120000
index 000000000..b7039dc2f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_helper.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_helper.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_iprange.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_iprange.h
new file mode 120000
index 000000000..d225d28f8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_iprange.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_iprange.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_length.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_length.h
new file mode 120000
index 000000000..268a39e9d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_length.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_length.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_mac.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_mac.h
new file mode 120000
index 000000000..f3cae5b51
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_mac.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_mac.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_owner.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_owner.h
new file mode 120000
index 000000000..b082109fd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_owner.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_owner.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_physdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_physdev.h
new file mode 120000
index 000000000..47258d47e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_physdev.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_physdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_pkttype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_pkttype.h
new file mode 120000
index 000000000..dc938c1a7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_pkttype.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_pkttype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_realm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_realm.h
new file mode 120000
index 000000000..c07b56d4a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_realm.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_realm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_recent.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_recent.h
new file mode 120000
index 000000000..531cb5651
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_recent.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_recent.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_sctp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_sctp.h
new file mode 120000
index 000000000..341f347af
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_sctp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_sctp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_state.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_state.h
new file mode 120000
index 000000000..da5187b15
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_state.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_state.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_string.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_string.h
new file mode 120000
index 000000000..12d23d4ea
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_string.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_string.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_tos_.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_tos_.h
new file mode 120000
index 000000000..35348cc2f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv4/ipt_tos_.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv4/ipt_tos_.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6.h
new file mode 120000
index 000000000..0a37d5bbb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netfilter_ipv6.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6_tables.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6_tables.h
new file mode 120000
index 000000000..dbabff240
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6_tables.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6_tables.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_HL.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_HL.h
new file mode 120000
index 000000000..9ade85712
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_HL.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_HL.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_LOG.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_LOG.h
new file mode 120000
index 000000000..c7b27c9aa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_LOG.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_LOG.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_REJECT.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_REJECT.h
new file mode 120000
index 000000000..fcee66dc4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_REJECT.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_REJECT.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ah.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ah.h
new file mode 120000
index 000000000..79151b022
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ah.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_ah.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_esp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_esp.h
new file mode 120000
index 000000000..4f116b79c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_esp.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_esp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_frag.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_frag.h
new file mode 120000
index 000000000..7375205b3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_frag.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_frag.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_hl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_hl.h
new file mode 120000
index 000000000..d9ed35331
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_hl.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_hl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ipv6header.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ipv6header.h
new file mode 120000
index 000000000..d3bc0ae41
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_ipv6header.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_ipv6header.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_length.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_length.h
new file mode 120000
index 000000000..cc583e5d0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_length.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_length.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_mac.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_mac.h
new file mode 120000
index 000000000..edb21e39a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_mac.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_mac.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_opts.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_opts.h
new file mode 120000
index 000000000..7dd0aec0e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_opts.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_opts.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_owner.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_owner.h
new file mode 120000
index 000000000..cd6bbca6b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_owner.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_owner.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_physdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_physdev.h
new file mode 120000
index 000000000..72d42c880
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_physdev.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_physdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_rt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_rt.h
new file mode 120000
index 000000000..0ade394ff
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netfilter_ipv6/ip6t_rt.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/netfilter_ipv6/ip6t_rt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netlink.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netlink.h
new file mode 120000
index 000000000..91610b861
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/netlink.h
@@ -0,0 +1 @@
+../../../../common/include/linux/netlink.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs.h
new file mode 120000
index 000000000..a0554782a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs2.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs2.h
new file mode 120000
index 000000000..c3a950933
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs2.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfs2.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs3.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs3.h
new file mode 120000
index 000000000..4cd8d7ade
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs3.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfs3.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs4.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs4.h
new file mode 120000
index 000000000..464985910
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs4.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfs4.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs_xdr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs_xdr.h
new file mode 120000
index 000000000..2f6de25fb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfs_xdr.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfs_xdr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsacl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsacl.h
new file mode 120000
index 000000000..c44aa13fa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsacl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nfsacl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/auth.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/auth.h
new file mode 120000
index 000000000..f68aa51e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/auth.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/auth.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/const.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/const.h
new file mode 120000
index 000000000..fe65cf427
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/const.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/const.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/debug.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/debug.h
new file mode 120000
index 000000000..789ca95eb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/debug.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/debug.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/export.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/export.h
new file mode 120000
index 000000000..811763b24
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/export.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/export.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/interface.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/interface.h
new file mode 120000
index 000000000..b19512d57
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/interface.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/interface.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/nfsfh.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/nfsfh.h
new file mode 120000
index 000000000..9f3e60d56
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/nfsfh.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/nfsfh.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/stats.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/stats.h
new file mode 120000
index 000000000..744e2fbfa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/stats.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/stats.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/xdr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/xdr.h
new file mode 120000
index 000000000..46d7928a1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nfsd/xdr.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/nfsd/xdr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/node.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/node.h
new file mode 120000
index 000000000..e67c59fd8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/node.h
@@ -0,0 +1 @@
+../../../../common/include/linux/node.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nodemask.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nodemask.h
new file mode 120000
index 000000000..356c720f0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nodemask.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nodemask.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/notifier.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/notifier.h
new file mode 120000
index 000000000..a0dfdcf8c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/notifier.h
@@ -0,0 +1 @@
+../../../../common/include/linux/notifier.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/numa.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/numa.h
new file mode 120000
index 000000000..f0549f072
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/numa.h
@@ -0,0 +1 @@
+../../../../common/include/linux/numa.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nvram.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nvram.h
new file mode 120000
index 000000000..e2bce317d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/nvram.h
@@ -0,0 +1 @@
+../../../../common/include/linux/nvram.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/omap_csmi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/omap_csmi.h
new file mode 120000
index 000000000..0d2c516c2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/omap_csmi.h
@@ -0,0 +1 @@
+../../../../common/include/linux/omap_csmi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pagemap.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pagemap.h
new file mode 120000
index 000000000..354550422
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pagemap.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pagemap.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/param.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/param.h
new file mode 120000
index 000000000..edd8f981e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/param.h
@@ -0,0 +1 @@
+../../../../common/include/linux/param.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/patchkey.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/patchkey.h
new file mode 120000
index 000000000..628a75c67
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/patchkey.h
@@ -0,0 +1 @@
+../../../../common/include/linux/patchkey.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci.h
new file mode 120000
index 000000000..22b0ec713
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pci.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_ids.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_ids.h
new file mode 120000
index 000000000..c3475fb74
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_ids.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pci_ids.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_regs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_regs.h
new file mode 120000
index 000000000..853c226f2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pci_regs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pci_regs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu.h
new file mode 120000
index 000000000..93d6b27f7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu.h
@@ -0,0 +1 @@
+../../../../common/include/linux/percpu.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu_counter.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu_counter.h
new file mode 120000
index 000000000..6c839d41c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/percpu_counter.h
@@ -0,0 +1 @@
+../../../../common/include/linux/percpu_counter.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/personality.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/personality.h
new file mode 120000
index 000000000..0d6b659dd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/personality.h
@@ -0,0 +1 @@
+../../../../common/include/linux/personality.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pfkeyv2.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pfkeyv2.h
new file mode 120000
index 000000000..321bbb616
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pfkeyv2.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pfkeyv2.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_cls.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_cls.h
new file mode 120000
index 000000000..58e889925
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_cls.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pkt_cls.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_sched.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_sched.h
new file mode 120000
index 000000000..77b5a4728
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pkt_sched.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pkt_sched.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/platform_device.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/platform_device.h
new file mode 120000
index 000000000..baa7b5520
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/platform_device.h
@@ -0,0 +1 @@
+../../../../common/include/linux/platform_device.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/plist.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/plist.h
new file mode 120000
index 000000000..4d4e54223
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/plist.h
@@ -0,0 +1 @@
+../../../../common/include/linux/plist.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pm.h
new file mode 120000
index 000000000..1a4339ee0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pm.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pnp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pnp.h
new file mode 120000
index 000000000..d7e1bb975
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/pnp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/pnp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/poll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/poll.h
new file mode 120000
index 000000000..23c4b3fd6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/poll.h
@@ -0,0 +1 @@
+../../../../common/include/linux/poll.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_acl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_acl.h
new file mode 120000
index 000000000..29ae7cda4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_acl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/posix_acl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_types.h
new file mode 120000
index 000000000..bcbcf00a4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/posix_types.h
@@ -0,0 +1 @@
+../../../../common/include/linux/posix_types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppdev.h
new file mode 120000
index 000000000..3b386a67d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppdev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ppdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppp_defs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppp_defs.h
new file mode 120000
index 000000000..309a3d075
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ppp_defs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ppp_defs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/prctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/prctl.h
new file mode 120000
index 000000000..8bbe96c1b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/prctl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/prctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/preempt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/preempt.h
new file mode 120000
index 000000000..9b59fe3e7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/preempt.h
@@ -0,0 +1 @@
+../../../../common/include/linux/preempt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/proc_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/proc_fs.h
new file mode 120000
index 000000000..6d310c456
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/proc_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/proc_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ptrace.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ptrace.h
new file mode 120000
index 000000000..2617a6c40
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ptrace.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ptrace.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qic117.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qic117.h
new file mode 120000
index 000000000..722306458
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qic117.h
@@ -0,0 +1 @@
+../../../../common/include/linux/qic117.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qnxtypes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qnxtypes.h
new file mode 120000
index 000000000..5c767a32d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/qnxtypes.h
@@ -0,0 +1 @@
+../../../../common/include/linux/qnxtypes.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/quota.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/quota.h
new file mode 120000
index 000000000..ed683653e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/quota.h
@@ -0,0 +1 @@
+../../../../common/include/linux/quota.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md.h
new file mode 120000
index 000000000..e8599ef80
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/raid/md.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_k.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_k.h
new file mode 120000
index 000000000..20f8ca614
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_k.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/raid/md_k.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_p.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_p.h
new file mode 120000
index 000000000..f631a38fa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_p.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/raid/md_p.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_u.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_u.h
new file mode 120000
index 000000000..931271cc2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/md_u.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/raid/md_u.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/xor.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/xor.h
new file mode 120000
index 000000000..b02a69a83
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/raid/xor.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/raid/xor.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/random.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/random.h
new file mode 120000
index 000000000..008878406
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/random.h
@@ -0,0 +1 @@
+../../../../common/include/linux/random.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rbtree.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rbtree.h
new file mode 120000
index 000000000..f606d94c8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rbtree.h
@@ -0,0 +1 @@
+../../../../common/include/linux/rbtree.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rcupdate.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rcupdate.h
new file mode 120000
index 000000000..e93235d1e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rcupdate.h
@@ -0,0 +1 @@
+../../../../common/include/linux/rcupdate.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/reboot.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/reboot.h
new file mode 120000
index 000000000..c3b86f4ea
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/reboot.h
@@ -0,0 +1 @@
+../../../../common/include/linux/reboot.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/relay.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/relay.h
new file mode 120000
index 000000000..c354e197f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/relay.h
@@ -0,0 +1 @@
+../../../../common/include/linux/relay.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/resource.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/resource.h
new file mode 120000
index 000000000..80a9f86da
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/resource.h
@@ -0,0 +1 @@
+../../../../common/include/linux/resource.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/route.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/route.h
new file mode 120000
index 000000000..c81b22022
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/route.h
@@ -0,0 +1 @@
+../../../../common/include/linux/route.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtc.h
new file mode 120000
index 000000000..eaeecd393
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/rtc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtnetlink.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtnetlink.h
new file mode 120000
index 000000000..064a3d26d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rtnetlink.h
@@ -0,0 +1 @@
+../../../../common/include/linux/rtnetlink.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rwsem.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rwsem.h
new file mode 120000
index 000000000..68eab47c6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/rwsem.h
@@ -0,0 +1 @@
+../../../../common/include/linux/rwsem.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sched.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sched.h
new file mode 120000
index 000000000..e8ff88bd3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sched.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sched.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sem.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sem.h
new file mode 120000
index 000000000..53484182c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sem.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sem.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seq_file.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seq_file.h
new file mode 120000
index 000000000..2c25e6cde
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seq_file.h
@@ -0,0 +1 @@
+../../../../common/include/linux/seq_file.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seqlock.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seqlock.h
new file mode 120000
index 000000000..345108e8e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/seqlock.h
@@ -0,0 +1 @@
+../../../../common/include/linux/seqlock.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_core.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_core.h
new file mode 120000
index 000000000..be40c9a2b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_core.h
@@ -0,0 +1 @@
+../../../../common/include/linux/serial_core.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_reg.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_reg.h
new file mode 120000
index 000000000..60bd1372e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serial_reg.h
@@ -0,0 +1 @@
+../../../../common/include/linux/serial_reg.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serio.h
new file mode 120000
index 000000000..4d3b062df
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/serio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/serio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/shm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/shm.h
new file mode 120000
index 000000000..4cd2df015
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/shm.h
@@ -0,0 +1 @@
+../../../../common/include/linux/shm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/signal.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/signal.h
new file mode 120000
index 000000000..10e9b014a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/signal.h
@@ -0,0 +1 @@
+../../../../common/include/linux/signal.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/skbuff.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/skbuff.h
new file mode 120000
index 000000000..5ff49831f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/skbuff.h
@@ -0,0 +1 @@
+../../../../common/include/linux/skbuff.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/slab.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/slab.h
new file mode 120000
index 000000000..04f089dd1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/slab.h
@@ -0,0 +1 @@
+../../../../common/include/linux/slab.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smb.h
new file mode 120000
index 000000000..3f1cf22e0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smb.h
@@ -0,0 +1 @@
+../../../../common/include/linux/smb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp.h
new file mode 120000
index 000000000..bfa5942b3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/smp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp_lock.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp_lock.h
new file mode 120000
index 000000000..76d4cb0b8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/smp_lock.h
@@ -0,0 +1 @@
+../../../../common/include/linux/smp_lock.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/socket.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/socket.h
new file mode 120000
index 000000000..edc366ff6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/socket.h
@@ -0,0 +1 @@
+../../../../common/include/linux/socket.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sockios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sockios.h
new file mode 120000
index 000000000..793adfbbf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sockios.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sockios.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/soundcard.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/soundcard.h
new file mode 120000
index 000000000..ca3757974
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/soundcard.h
@@ -0,0 +1 @@
+../../../../common/include/linux/soundcard.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock.h
new file mode 120000
index 000000000..305c46d0e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_smp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_smp.h
new file mode 120000
index 000000000..45bfb4efc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_smp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock_api_smp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_up.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_up.h
new file mode 120000
index 000000000..b54532e73
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_api_up.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock_api_up.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types.h
new file mode 120000
index 000000000..39611b77a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock_types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types_up.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types_up.h
new file mode 120000
index 000000000..d5384d730
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_types_up.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock_types_up.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_up.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_up.h
new file mode 120000
index 000000000..46b3c0e9d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/spinlock_up.h
@@ -0,0 +1 @@
+../../../../common/include/linux/spinlock_up.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stacktrace.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stacktrace.h
new file mode 120000
index 000000000..4c1823250
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stacktrace.h
@@ -0,0 +1 @@
+../../../../common/include/linux/stacktrace.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stat.h
new file mode 120000
index 000000000..842159b62
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stat.h
@@ -0,0 +1 @@
+../../../../common/include/linux/stat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/statfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/statfs.h
new file mode 120000
index 000000000..4ac3b012f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/statfs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/statfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stddef.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stddef.h
new file mode 120000
index 000000000..9b398f1dd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stddef.h
@@ -0,0 +1 @@
+../../../../common/include/linux/stddef.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/string.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/string.h
new file mode 120000
index 000000000..414748ff0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/string.h
@@ -0,0 +1 @@
+../../../../common/include/linux/string.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stringify.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stringify.h
new file mode 120000
index 000000000..44dd7ed51
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/stringify.h
@@ -0,0 +1 @@
+../../../../common/include/linux/stringify.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth.h
new file mode 120000
index 000000000..1fbe34fa3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/auth.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth_gss.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth_gss.h
new file mode 120000
index 000000000..7bc8ad118
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/auth_gss.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/auth_gss.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/clnt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/clnt.h
new file mode 120000
index 000000000..7f11a93cc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/clnt.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/clnt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/debug.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/debug.h
new file mode 120000
index 000000000..c95a4295f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/debug.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/debug.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_api.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_api.h
new file mode 120000
index 000000000..e10eba61e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_api.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/gss_api.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_asn1.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_asn1.h
new file mode 120000
index 000000000..e860f8ee3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_asn1.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/gss_asn1.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_err.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_err.h
new file mode 120000
index 000000000..72c7141c5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/gss_err.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/gss_err.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/msg_prot.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/msg_prot.h
new file mode 120000
index 000000000..d9cb9ae63
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/msg_prot.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/msg_prot.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/sched.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/sched.h
new file mode 120000
index 000000000..84791a706
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/sched.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/sched.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/stats.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/stats.h
new file mode 120000
index 000000000..b115bd5f5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/stats.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/stats.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svc.h
new file mode 120000
index 000000000..658a81ed6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svc.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/svc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svcauth.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svcauth.h
new file mode 120000
index 000000000..8c3e841b3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/svcauth.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/svcauth.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/timer.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/timer.h
new file mode 120000
index 000000000..ce8709d36
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/timer.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/timer.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/types.h
new file mode 120000
index 000000000..e7f765658
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/types.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xdr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xdr.h
new file mode 120000
index 000000000..163e6183e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xdr.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/xdr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xprt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xprt.h
new file mode 120000
index 000000000..6d2914847
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sunrpc/xprt.h
@@ -0,0 +1 @@
+../../../../../common/include/linux/sunrpc/xprt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/swap.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/swap.h
new file mode 120000
index 000000000..47db73a63
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/swap.h
@@ -0,0 +1 @@
+../../../../common/include/linux/swap.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysctl.h
new file mode 120000
index 000000000..1252a5337
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysctl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sysctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysdev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysdev.h
new file mode 120000
index 000000000..6691343c6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysdev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sysdev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysfs.h
new file mode 120000
index 000000000..0cbaad865
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/sysfs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/sysfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats.h
new file mode 120000
index 000000000..24a178eb9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats.h
@@ -0,0 +1 @@
+../../../../common/include/linux/taskstats.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats_kern.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats_kern.h
new file mode 120000
index 000000000..20b2c64f1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/taskstats_kern.h
@@ -0,0 +1 @@
+../../../../common/include/linux/taskstats_kern.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tcp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tcp.h
new file mode 120000
index 000000000..417237a30
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tcp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/tcp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/telephony.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/telephony.h
new file mode 120000
index 000000000..44b4c18fa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/telephony.h
@@ -0,0 +1 @@
+../../../../common/include/linux/telephony.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/termios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/termios.h
new file mode 120000
index 000000000..968db97fa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/termios.h
@@ -0,0 +1 @@
+../../../../common/include/linux/termios.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/textsearch.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/textsearch.h
new file mode 120000
index 000000000..e033273f7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/textsearch.h
@@ -0,0 +1 @@
+../../../../common/include/linux/textsearch.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/thread_info.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/thread_info.h
new file mode 120000
index 000000000..11a10110e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/thread_info.h
@@ -0,0 +1 @@
+../../../../common/include/linux/thread_info.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/threads.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/threads.h
new file mode 120000
index 000000000..ef3237e2c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/threads.h
@@ -0,0 +1 @@
+../../../../common/include/linux/threads.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/time.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/time.h
new file mode 120000
index 000000000..206084319
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/time.h
@@ -0,0 +1 @@
+../../../../common/include/linux/time.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timer.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timer.h
new file mode 120000
index 000000000..f81d9079a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timer.h
@@ -0,0 +1 @@
+../../../../common/include/linux/timer.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/times.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/times.h
new file mode 120000
index 000000000..875720140
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/times.h
@@ -0,0 +1 @@
+../../../../common/include/linux/times.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timex.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timex.h
new file mode 120000
index 000000000..49e520b66
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/timex.h
@@ -0,0 +1 @@
+../../../../common/include/linux/timex.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tiocl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tiocl.h
new file mode 120000
index 000000000..ae6102bb4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tiocl.h
@@ -0,0 +1 @@
+../../../../common/include/linux/tiocl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/transport_class.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/transport_class.h
new file mode 120000
index 000000000..735b69b88
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/transport_class.h
@@ -0,0 +1 @@
+../../../../common/include/linux/transport_class.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tty.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tty.h
new file mode 120000
index 000000000..4e874bf8d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/tty.h
@@ -0,0 +1 @@
+../../../../common/include/linux/tty.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/types.h
new file mode 120000
index 000000000..76b251187
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/types.h
@@ -0,0 +1 @@
+../../../../common/include/linux/types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/udp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/udp.h
new file mode 120000
index 000000000..14ee4b2c5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/udp.h
@@ -0,0 +1 @@
+../../../../common/include/linux/udp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_i.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_i.h
new file mode 120000
index 000000000..de767a798
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_i.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ufs_fs_i.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_sb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_sb.h
new file mode 120000
index 000000000..a78b9d3de
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/ufs_fs_sb.h
@@ -0,0 +1 @@
+../../../../common/include/linux/ufs_fs_sb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/uio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/uio.h
new file mode 120000
index 000000000..95a105da6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/uio.h
@@ -0,0 +1 @@
+../../../../common/include/linux/uio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/un.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/un.h
new file mode 120000
index 000000000..6d51e9416
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/un.h
@@ -0,0 +1 @@
+../../../../common/include/linux/un.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/unistd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/unistd.h
new file mode 120000
index 000000000..7ef4a0d1c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/unistd.h
@@ -0,0 +1 @@
+../../../../common/include/linux/unistd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb.h
new file mode 120000
index 000000000..7da27d742
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb.h
@@ -0,0 +1 @@
+../../../../common/include/linux/usb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb_ch9.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb_ch9.h
new file mode 120000
index 000000000..d8a2655c0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usb_ch9.h
@@ -0,0 +1 @@
+../../../../common/include/linux/usb_ch9.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usbdevice_fs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usbdevice_fs.h
new file mode 120000
index 000000000..b4c8de8fb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/usbdevice_fs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/usbdevice_fs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/user.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/user.h
new file mode 120000
index 000000000..2bb072e51
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/user.h
@@ -0,0 +1 @@
+../../../../common/include/linux/user.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utime.h
new file mode 120000
index 000000000..c483c2843
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utime.h
@@ -0,0 +1 @@
+../../../../common/include/linux/utime.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utsname.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utsname.h
new file mode 120000
index 000000000..8b0a09843
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/utsname.h
@@ -0,0 +1 @@
+../../../../common/include/linux/utsname.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/version.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/version.h
new file mode 120000
index 000000000..cb2ac6282
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/version.h
@@ -0,0 +1 @@
+../../../../common/include/linux/version.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vfs.h
new file mode 120000
index 000000000..b81596249
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vfs.h
@@ -0,0 +1 @@
+../../../../common/include/linux/vfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev.h
new file mode 120000
index 000000000..33e8651a1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev.h
@@ -0,0 +1 @@
+../../../../common/include/linux/videodev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev2.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev2.h
new file mode 120000
index 000000000..9127b40f7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/videodev2.h
@@ -0,0 +1 @@
+../../../../common/include/linux/videodev2.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vmalloc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vmalloc.h
new file mode 120000
index 000000000..90410fc80
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vmalloc.h
@@ -0,0 +1 @@
+../../../../common/include/linux/vmalloc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt.h
new file mode 120000
index 000000000..5f1333aae
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt.h
@@ -0,0 +1 @@
+../../../../common/include/linux/vt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt_buffer.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt_buffer.h
new file mode 120000
index 000000000..babe2413d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/vt_buffer.h
@@ -0,0 +1 @@
+../../../../common/include/linux/vt_buffer.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wait.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wait.h
new file mode 120000
index 000000000..ee2730b7a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wait.h
@@ -0,0 +1 @@
+../../../../common/include/linux/wait.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wanrouter.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wanrouter.h
new file mode 120000
index 000000000..1d1b8f151
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wanrouter.h
@@ -0,0 +1 @@
+../../../../common/include/linux/wanrouter.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wireless.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wireless.h
new file mode 120000
index 000000000..43983b512
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/wireless.h
@@ -0,0 +1 @@
+../../../../common/include/linux/wireless.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/workqueue.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/workqueue.h
new file mode 120000
index 000000000..3ce051200
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/workqueue.h
@@ -0,0 +1 @@
+../../../../common/include/linux/workqueue.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/xattr.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/xattr.h
new file mode 120000
index 000000000..8cf8b0bfc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/xattr.h
@@ -0,0 +1 @@
+../../../../common/include/linux/xattr.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zconf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zconf.h
new file mode 120000
index 000000000..4dc29e6ca
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zconf.h
@@ -0,0 +1 @@
+../../../../common/include/linux/zconf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zlib.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zlib.h
new file mode 120000
index 000000000..9d45319cc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zlib.h
@@ -0,0 +1 @@
+../../../../common/include/linux/zlib.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zorro_ids.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zorro_ids.h
new file mode 120000
index 000000000..f2220c097
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/linux/zorro_ids.h
@@ -0,0 +1 @@
+../../../../common/include/linux/zorro_ids.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/locale.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/locale.h
new file mode 120000
index 000000000..26247fdc8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/locale.h
@@ -0,0 +1 @@
+../../../common/include/locale.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/_types.h
new file mode 100644
index 000000000..6d10e12b4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/_types.h
@@ -0,0 +1,127 @@
+/* $OpenBSD: _types.h,v 1.3 2006/02/14 18:12:58 miod Exp $ */
+
+/*-
+ * Copyright (c) 1990, 1993
+ * The Regents of the University of California. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)types.h 8.3 (Berkeley) 1/5/94
+ * @(#)ansi.h 8.2 (Berkeley) 1/4/94
+ */
+
+#ifndef _ARM__TYPES_H_
+#define _ARM__TYPES_H_
+
+
+#if !defined(__ARM_EABI__)
+/* the kernel defines size_t as unsigned int, but g++ wants it to be unsigned long */
+#define _SIZE_T
+#define _SSIZE_T
+#define _PTRDIFF_T
+typedef unsigned long size_t;
+typedef long ssize_t;
+typedef long ptrdiff_t;
+#endif
+
+//#include
+
+/* 7.18.1.1 Exact-width integer types */
+typedef __signed char __int8_t;
+typedef unsigned char __uint8_t;
+typedef short __int16_t;
+typedef unsigned short __uint16_t;
+typedef int __int32_t;
+typedef unsigned int __uint32_t;
+/* LONGLONG */
+typedef long long __int64_t;
+/* LONGLONG */
+typedef unsigned long long __uint64_t;
+
+/* 7.18.1.2 Minimum-width integer types */
+typedef __int8_t __int_least8_t;
+typedef __uint8_t __uint_least8_t;
+typedef __int16_t __int_least16_t;
+typedef __uint16_t __uint_least16_t;
+typedef __int32_t __int_least32_t;
+typedef __uint32_t __uint_least32_t;
+typedef __int64_t __int_least64_t;
+typedef __uint64_t __uint_least64_t;
+
+/* 7.18.1.3 Fastest minimum-width integer types */
+typedef __int32_t __int_fast8_t;
+typedef __uint32_t __uint_fast8_t;
+typedef __int32_t __int_fast16_t;
+typedef __uint32_t __uint_fast16_t;
+typedef __int32_t __int_fast32_t;
+typedef __uint32_t __uint_fast32_t;
+typedef __int64_t __int_fast64_t;
+typedef __uint64_t __uint_fast64_t;
+
+/* 7.18.1.4 Integer types capable of holding object pointers */
+typedef int __intptr_t;
+typedef unsigned int __uintptr_t;
+
+/* 7.18.1.5 Greatest-width integer types */
+typedef __int64_t __intmax_t;
+typedef __uint64_t __uintmax_t;
+
+/* Register size */
+typedef __int32_t __register_t;
+
+/* VM system types */
+typedef unsigned long __vaddr_t;
+typedef unsigned long __paddr_t;
+typedef unsigned long __vsize_t;
+typedef unsigned long __psize_t;
+
+/* Standard system types */
+typedef int __clock_t;
+typedef int __clockid_t;
+typedef long __ptrdiff_t;
+typedef int __time_t;
+typedef int __timer_t;
+#if defined(__GNUC__) && __GNUC__ >= 3
+typedef __builtin_va_list __va_list;
+#else
+typedef char * __va_list;
+#endif
+
+/* Wide character support types */
+#ifndef __cplusplus
+typedef int __wchar_t;
+#endif
+typedef int __wint_t;
+typedef int __rune_t;
+typedef void * __wctrans_t;
+typedef void * __wctype_t;
+
+#ifdef __ARMEB__
+#define _BYTE_ORDER _BIG_ENDIAN
+#else
+#define _BYTE_ORDER _LITTLE_ENDIAN
+#endif
+
+#endif /* _ARM__TYPES_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/asm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/asm.h
new file mode 100644
index 000000000..c7bd017aa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/asm.h
@@ -0,0 +1,130 @@
+/* $OpenBSD: asm.h,v 1.1 2004/02/01 05:09:49 drahn Exp $ */
+/* $NetBSD: asm.h,v 1.4 2001/07/16 05:43:32 matt Exp $ */
+
+/*
+ * Copyright (c) 1990 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * This code is derived from software contributed to Berkeley by
+ * William Jolitz.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * from: @(#)asm.h 5.5 (Berkeley) 5/7/91
+ */
+
+#ifndef _ARM32_ASM_H_
+#define _ARM32_ASM_H_
+
+#ifdef __ELF__
+# define _C_LABEL(x) x
+#else
+# ifdef __STDC__
+# define _C_LABEL(x) _ ## x
+# else
+# define _C_LABEL(x) _/**/x
+# endif
+#endif
+#define _ASM_LABEL(x) x
+
+#ifdef __STDC__
+# define __CONCAT(x,y) x ## y
+# define __STRING(x) #x
+#else
+# define __CONCAT(x,y) x/**/y
+# define __STRING(x) "x"
+#endif
+
+#ifndef _ALIGN_TEXT
+# define _ALIGN_TEXT .align 0
+#endif
+
+/*
+ * gas/arm uses @ as a single comment character and thus cannot be used here
+ * Instead it recognised the # instead of an @ symbols in .type directives
+ * We define a couple of macros so that assembly code will not be dependant
+ * on one or the other.
+ */
+#define _ASM_TYPE_FUNCTION #function
+#define _ASM_TYPE_OBJECT #object
+#define _ENTRY(x) \
+ .text; _ALIGN_TEXT; .globl x; .type x,_ASM_TYPE_FUNCTION; x:
+
+#ifdef GPROF
+# ifdef __ELF__
+# define _PROF_PROLOGUE \
+ mov ip, lr; bl __mcount
+# else
+# define _PROF_PROLOGUE \
+ mov ip,lr; bl mcount
+# endif
+#else
+# define _PROF_PROLOGUE
+#endif
+
+#define ENTRY(y) _ENTRY(_C_LABEL(y)); _PROF_PROLOGUE
+#define ENTRY_NP(y) _ENTRY(_C_LABEL(y))
+#define ASENTRY(y) _ENTRY(_ASM_LABEL(y)); _PROF_PROLOGUE
+#define ASENTRY_NP(y) _ENTRY(_ASM_LABEL(y))
+
+#define ASMSTR .asciz
+
+#if defined(__ELF__) && defined(PIC)
+#ifdef __STDC__
+#define PIC_SYM(x,y) x ## ( ## y ## )
+#else
+#define PIC_SYM(x,y) x/**/(/**/y/**/)
+#endif
+#else
+#define PIC_SYM(x,y) x
+#endif
+
+#ifdef __ELF__
+#define RCSID(x) .section ".ident"; .asciz x
+#else
+#define RCSID(x) .text; .asciz x
+#endif
+
+#ifdef __ELF__
+#define WEAK_ALIAS(alias,sym) \
+ .weak alias; \
+ alias = sym
+#endif
+
+#ifdef __STDC__
+#define WARN_REFERENCES(sym,msg) \
+ .stabs msg ## ,30,0,0,0 ; \
+ .stabs __STRING(_C_LABEL(sym)) ## ,1,0,0,0
+#elif defined(__ELF__)
+#define WARN_REFERENCES(sym,msg) \
+ .stabs msg,30,0,0,0 ; \
+ .stabs __STRING(sym),1,0,0,0
+#else
+#define WARN_REFERENCES(sym,msg) \
+ .stabs msg,30,0,0,0 ; \
+ .stabs __STRING(_/**/sym),1,0,0,0
+#endif /* __STDC__ */
+
+#endif /* !_ARM_ASM_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cdefs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cdefs.h
new file mode 100644
index 000000000..44f1542d6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cdefs.h
@@ -0,0 +1,19 @@
+/* $OpenBSD: cdefs.h,v 1.2 2005/11/24 20:46:44 deraadt Exp $ */
+
+#ifndef _MACHINE_CDEFS_H_
+#define _MACHINE_CDEFS_H_
+
+#if defined(lint)
+#define __indr_reference(sym,alias) __lint_equal__(sym,alias)
+#define __warn_references(sym,msg)
+#define __weak_alias(alias,sym) __lint_equal__(sym,alias)
+#elif defined(__GNUC__) && defined(__STDC__)
+#define __weak_alias(alias,sym) \
+ __asm__(".weak " __STRING(alias) " ; " __STRING(alias) \
+ " = " __STRING(sym));
+#define __warn_references(sym,msg) \
+ __asm__(".section .gnu.warning." __STRING(sym) \
+ " ; .ascii \"" msg "\" ; .text");
+#endif
+
+#endif /* !_MACHINE_CDEFS_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cpu-features.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cpu-features.h
new file mode 100644
index 000000000..f83600648
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/cpu-features.h
@@ -0,0 +1,164 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ARM_MACHINE_CPU_FEATURES_H
+#define _ARM_MACHINE_CPU_FEATURES_H
+
+/* The purpose of this file is to define several macros corresponding
+ * to CPU features that may or may not be available at build time on
+ * on the target CPU.
+ *
+ * This is done to abstract us from the various ARM Architecture
+ * quirks and alphabet soup.
+ *
+ * IMPORTANT: We have no intention to support anything below an ARMv4T !
+ */
+
+/* _ARM_ARCH_REVISION is a number corresponding to the ARM revision
+ * we're going to support
+ *
+ * it looks like our toolchain doesn't define __ARM_ARCH__
+ * so try to guess it.
+ *
+ *
+ *
+ */
+#ifndef __ARM_ARCH__
+
+# if defined __ARM_ARCH_7__ || defined __ARM_ARCH_7A__ || \
+ defined __ARM_ARCH_7R__ || defined __ARM_ARCH_7M__
+
+# define __ARM_ARCH__ 7
+
+# elif defined __ARM_ARCH_6__ || defined __ARM_ARCH_6J__ || \
+ defined __ARM_ARCH_6K__ || defined __ARM_ARCH_6Z__ || \
+ defined __ARM_ARCH_6KZ__ || defined __ARM_ARCH_6T2__
+#
+# define __ARM_ARCH__ 6
+#
+# elif defined __ARM_ARCH_5__ || defined __ARM_ARCH_5T__ || \
+ defined __ARM_ARCH_5TE__ || defined __ARM_ARCH_5TEJ__
+#
+# define __ARM_ARCH__ 5
+#
+# elif defined __ARM_ARCH_4T__
+#
+# define __ARM_ARCH__ 4
+#
+# elif defined __ARM_ARCH_4__
+# error ARMv4 is not supported, please use ARMv4T at a minimum
+# else
+# error Unknown or unsupported ARM architecture
+# endif
+#endif
+
+/* experimental feature used to check that our ARMv4 workarounds
+ * work correctly without a real ARMv4 machine */
+#ifdef BIONIC_EXPERIMENTAL_FORCE_ARMV4
+# undef __ARM_ARCH__
+# define __ARM_ARCH__ 4
+#endif
+
+/* define __ARM_HAVE_5TE if we have the ARMv5TE instructions */
+#if __ARM_ARCH__ > 5
+# define __ARM_HAVE_5TE 1
+#elif __ARM_ARCH__ == 5
+# if defined __ARM_ARCH_5TE__ || defined __ARM_ARCH_5TEJ__
+# define __ARM_HAVE_5TE 1
+# endif
+#endif
+
+/* instructions introduced in ARMv5 */
+#if __ARM_ARCH__ >= 5
+# define __ARM_HAVE_BLX 1
+# define __ARM_HAVE_CLZ 1
+# define __ARM_HAVE_LDC2 1
+# define __ARM_HAVE_MCR2 1
+# define __ARM_HAVE_MRC2 1
+# define __ARM_HAVE_STC2 1
+#endif
+
+/* ARMv5TE introduces a few instructions */
+#if __ARM_HAVE_5TE
+# define __ARM_HAVE_PLD 1
+# define __ARM_HAVE_MCRR 1
+# define __ARM_HAVE_MRRC 1
+#endif
+
+/* define __ARM_HAVE_HALFWORD_MULTIPLY when half-word multiply instructions
+ * this means variants of: smul, smulw, smla, smlaw, smlal
+ */
+#if __ARM_HAVE_5TE
+# define __ARM_HAVE_HALFWORD_MULTIPLY 1
+#endif
+
+/* define __ARM_HAVE_PAIR_LOAD_STORE when 64-bit memory loads and stored
+ * into/from a pair of 32-bit registers is supported throuhg 'ldrd' and 'strd'
+ */
+#if __ARM_HAVE_5TE
+# define __ARM_HAVE_PAIR_LOAD_STORE 1
+#endif
+
+/* define __ARM_HAVE_SATURATED_ARITHMETIC is you have the saturated integer
+ * arithmetic instructions: qdd, qdadd, qsub, qdsub
+ */
+#if __ARM_HAVE_5TE
+# define __ARM_HAVE_SATURATED_ARITHMETIC 1
+#endif
+
+/* define __ARM_HAVE_PC_INTERWORK when a direct assignment to the
+ * pc register will switch into thumb/ARM mode depending on bit 0
+ * of the new instruction address. Before ARMv5, this was not the
+ * case, and you have to write:
+ *
+ * mov r0, []
+ * bx r0
+ *
+ * instead of:
+ *
+ * ldr pc, []
+ *
+ * note that this affects any instruction that explicitely changes the
+ * value of the pc register, including ldm { ...,pc } or 'add pc, #offset'
+ */
+#if __ARM_ARCH__ >= 5
+# define __ARM_HAVE_PC_INTERWORK
+#endif
+
+
+/* Assembly-only macros */
+
+/* define a handy PLD(address) macro since the cache preload
+ * is an optional opcode
+ */
+#if __ARM_HAVE_PLD
+# define PLD(reg,offset) pld [reg, offset]
+#else
+# define PLD(reg,offset) /* nothing */
+#endif
+
+#endif /* _ARM_MACHINE_CPU_FEATURES_H */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/exec.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/exec.h
new file mode 100644
index 000000000..227b20762
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/exec.h
@@ -0,0 +1,50 @@
+/* $OpenBSD: exec.h,v 1.9 2003/04/17 03:42:14 drahn Exp $ */
+/* $NetBSD: exec.h,v 1.6 1994/10/27 04:16:05 cgd Exp $ */
+
+/*
+ * Copyright (c) 1993 Christopher G. Demetriou
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ * derived from this software without specific prior written permission
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef _ARM_EXEC_H_
+#define _ARM_EXEC_H_
+
+#define __LDPGSZ 4096
+
+#define NATIVE_EXEC_ELF
+
+#define ARCH_ELFSIZE 32
+
+#define ELF_TARG_CLASS ELFCLASS32
+#define ELF_TARG_DATA ELFDATA2LSB
+#define ELF_TARG_MACH EM_ARM
+
+#define _NLIST_DO_AOUT
+#define _NLIST_DO_ELF
+
+#define _KERN_DO_AOUT
+#define _KERN_DO_ELF
+
+#endif /* _ARM_EXEC_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/ieee.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/ieee.h
new file mode 100644
index 000000000..5f9b89ecc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/ieee.h
@@ -0,0 +1,191 @@
+/* $OpenBSD: ieee.h,v 1.1 2004/02/01 05:09:49 drahn Exp $ */
+/* $NetBSD: ieee.h,v 1.2 2001/02/21 17:43:50 bjh21 Exp $ */
+
+/*
+ * Copyright (c) 1992, 1993
+ * The Regents of the University of California. All rights reserved.
+ *
+ * This software was developed by the Computer Systems Engineering group
+ * at Lawrence Berkeley Laboratory under DARPA contract BG 91-66 and
+ * contributed to Berkeley.
+ *
+ * All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * This product includes software developed by the University of
+ * California, Lawrence Berkeley Laboratory.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * This product includes software developed by the University of
+ * California, Berkeley and its contributors.
+ * 4. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)ieee.h 8.1 (Berkeley) 6/11/93
+ */
+
+/*
+ * ieee.h defines the machine-dependent layout of the machine's IEEE
+ * floating point.
+ */
+
+/*
+ * Define the number of bits in each fraction and exponent.
+ *
+ * k k+1
+ * Note that 1.0 x 2 == 0.1 x 2 and that denorms are represented
+ *
+ * (-exp_bias+1)
+ * as fractions that look like 0.fffff x 2 . This means that
+ *
+ * -126
+ * the number 0.10000 x 2 , for instance, is the same as the normalized
+ *
+ * -127 -128
+ * float 1.0 x 2 . Thus, to represent 2 , we need one leading zero
+ *
+ * -129
+ * in the fraction; to represent 2 , we need two, and so on. This
+ *
+ * (-exp_bias-fracbits+1)
+ * implies that the smallest denormalized number is 2
+ *
+ * for whichever format we are talking about: for single precision, for
+ *
+ * -126 -149
+ * instance, we get .00000000000000000000001 x 2 , or 1.0 x 2 , and
+ *
+ * -149 == -127 - 23 + 1.
+ */
+
+/*
+ * The ARM has two sets of FP data formats. The FPA supports 32-bit, 64-bit
+ * and 96-bit IEEE formats, with the words in big-endian order. VFP supports
+ * 32-bin and 64-bit IEEE formats with the words in the CPU's native byte
+ * order.
+ *
+ * The FPA also has two packed decimal formats, but we ignore them here.
+ */
+
+#define SNG_EXPBITS 8
+#define SNG_FRACBITS 23
+
+#define DBL_EXPBITS 11
+#define DBL_FRACBITS 52
+
+#ifndef __VFP_FP__
+#define E80_EXPBITS 15
+#define E80_FRACBITS 64
+
+#define EXT_EXPBITS 15
+#define EXT_FRACBITS 112
+#endif
+
+struct ieee_single {
+ u_int sng_frac:23;
+ u_int sng_exponent:8;
+ u_int sng_sign:1;
+};
+
+#ifdef __VFP_FP__
+struct ieee_double {
+#ifdef __ARMEB__
+ u_int dbl_sign:1;
+ u_int dbl_exp:11;
+ u_int dbl_frach:20;
+ u_int dbl_fracl;
+#else /* !__ARMEB__ */
+ u_int dbl_fracl;
+ u_int dbl_frach:20;
+ u_int dbl_exp:11;
+ u_int dbl_sign:1;
+#endif /* !__ARMEB__ */
+};
+#else /* !__VFP_FP__ */
+struct ieee_double {
+ u_int dbl_frach:20;
+ u_int dbl_exp:11;
+ u_int dbl_sign:1;
+ u_int dbl_fracl;
+};
+
+union ieee_double_u {
+ double dblu_d;
+ struct ieee_double dblu_dbl;
+};
+
+
+struct ieee_e80 {
+ u_int e80_exp:15;
+ u_int e80_zero:16;
+ u_int e80_sign:1;
+ u_int e80_frach:31;
+ u_int e80_j:1;
+ u_int e80_fracl;
+};
+
+struct ieee_ext {
+ u_int ext_frach:16;
+ u_int ext_exp:15;
+ u_int ext_sign:1;
+ u_int ext_frachm;
+ u_int ext_fraclm;
+ u_int ext_fracl;
+};
+#endif /* !__VFP_FP__ */
+
+/*
+ * Floats whose exponent is in [1..INFNAN) (of whatever type) are
+ * `normal'. Floats whose exponent is INFNAN are either Inf or NaN.
+ * Floats whose exponent is zero are either zero (iff all fraction
+ * bits are zero) or subnormal values.
+ *
+ * A NaN is a `signalling NaN' if its QUIETNAN bit is clear in its
+ * high fraction; if the bit is set, it is a `quiet NaN'.
+ */
+#define SNG_EXP_INFNAN 255
+#define DBL_EXP_INFNAN 2047
+#ifndef __VFP_FP__
+#define E80_EXP_INFNAN 32767
+#define EXT_EXP_INFNAN 32767
+#endif /* !__VFP_FP__ */
+
+#if 0
+#define SNG_QUIETNAN (1 << 22)
+#define DBL_QUIETNAN (1 << 19)
+#ifndef __VFP_FP__
+#define E80_QUIETNAN (1 << 15)
+#define EXT_QUIETNAN (1 << 15)
+#endif /* !__VFP_FP__ */
+#endif
+
+/*
+ * Exponent biases.
+ */
+#define SNG_EXP_BIAS 127
+#define DBL_EXP_BIAS 1023
+#ifndef __VFP_FP__
+#define E80_EXP_BIAS 16383
+#define EXT_EXP_BIAS 16383
+#endif /* !__VFP_FP__ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/internal_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/internal_types.h
new file mode 100644
index 000000000..7e610b0ec
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/internal_types.h
@@ -0,0 +1,10 @@
+/* $OpenBSD: internal_types.h,v 1.2 2004/05/06 15:53:39 drahn Exp $ */
+/* Public domain */
+#ifndef _ARM_INTERNAL_TYPES_H_
+#define _ARM_INTERNAL_TYPES_H_
+
+#ifdef __CHAR_UNSIGNED__
+#define __machine_has_unsigned_chars
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/kernel.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/kernel.h
new file mode 100644
index 000000000..462b8e3be
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/kernel.h
@@ -0,0 +1,42 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ARCH_ARM_KERNEL_H
+#define _ARCH_ARM_KERNEL_H
+
+/* this file contains kernel-specific definitions that were optimized out of
+ our processed kernel headers, but still useful nonetheless... */
+
+typedef unsigned long __kernel_blkcnt_t;
+typedef unsigned long __kernel_blksize_t;
+
+/* these aren't really defined by the kernel headers though... */
+typedef unsigned long __kernel_fsblkcnt_t;
+typedef unsigned long __kernel_fsfilcnt_t;
+typedef unsigned int __kernel_id_t;
+
+#endif /* _ARCH_ARM_KERNEL_H */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/limits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/limits.h
new file mode 100644
index 000000000..f9c04fae2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/limits.h
@@ -0,0 +1,63 @@
+/* $OpenBSD: limits.h,v 1.3 2006/01/06 22:48:46 millert Exp $ */
+/* $NetBSD: limits.h,v 1.4 2003/04/28 23:16:18 bjh21 Exp $ */
+
+/*
+ * Copyright (c) 1988 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * from: @(#)limits.h 7.2 (Berkeley) 6/28/90
+ */
+
+#ifndef _ARM32_LIMITS_H_
+#define _ARM32_LIMITS_H_
+
+#include
+
+#define MB_LEN_MAX 1 /* no multibyte characters */
+
+#ifndef SIZE_MAX
+#define SIZE_MAX UINT_MAX /* max value for a size_t */
+#endif
+#ifndef SSIZE_MAX
+#define SSIZE_MAX INT_MAX /* max value for a ssize_t */
+#endif
+
+#if __BSD_VISIBLE
+#define SIZE_T_MAX UINT_MAX /* max value for a size_t (historic) */
+
+#define UQUAD_MAX 0xffffffffffffffffULL /* max unsigned quad */
+#define QUAD_MAX 0x7fffffffffffffffLL /* max signed quad */
+#define QUAD_MIN (-0x7fffffffffffffffLL-1) /* min signed quad */
+
+#endif /* __BSD_VISIBLE */
+
+#define LONGLONG_BIT 64
+#define LONGLONG_MIN (-9223372036854775807LL-1)
+#define LONGLONG_MAX 9223372036854775807LL
+#define ULONGLONG_MAX 18446744073709551615ULL
+
+#endif /* _ARM32_LIMITS_H_ */
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/setjmp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/setjmp.h
new file mode 100644
index 000000000..f20cab2e9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/machine/setjmp.h
@@ -0,0 +1,87 @@
+/* $OpenBSD: setjmp.h,v 1.1 2004/02/01 05:09:49 drahn Exp $ */
+/* $NetBSD: setjmp.h,v 1.2 2001/08/25 14:45:59 bjh21 Exp $ */
+
+/*
+ * machine/setjmp.h: machine dependent setjmp-related information.
+ */
+
+#ifdef __ELF__
+#define _JBLEN 64 /* size, in longs, of a jmp_buf */
+#else
+#define _JBLEN 29 /* size, in longs, of a jmp_buf */
+#endif
+
+/*
+ * NOTE: The internal structure of a jmp_buf is *PRIVATE*
+ * This information is provided as there is software
+ * that fiddles with this with obtain the stack pointer
+ * (yes really ! and its commercial !).
+ *
+ * Description of the setjmp buffer
+ *
+ * word 0 magic number (dependant on creator)
+ * 1 - 3 f4 fp register 4
+ * 4 - 6 f5 fp register 5
+ * 7 - 9 f6 fp register 6
+ * 10 - 12 f7 fp register 7
+ * 13 fpsr fp status register
+ * 14 r4 register 4
+ * 15 r5 register 5
+ * 16 r6 register 6
+ * 17 r7 register 7
+ * 18 r8 register 8
+ * 19 r9 register 9
+ * 20 r10 register 10 (sl)
+ * 21 r11 register 11 (fp)
+ * 22 r12 register 12 (ip)
+ * 23 r13 register 13 (sp)
+ * 24 r14 register 14 (lr)
+ * 25 signal mask (dependant on magic)
+ * 26 (con't)
+ * 27 (con't)
+ * 28 (con't)
+ *
+ * The magic number number identifies the jmp_buf and
+ * how the buffer was created as well as providing
+ * a sanity check
+ *
+ * A side note I should mention - Please do not tamper
+ * with the floating point fields. While they are
+ * always saved and restored at the moment this cannot
+ * be garenteed especially if the compiler happens
+ * to be generating soft-float code so no fp
+ * registers will be used.
+ *
+ * Whilst this can be seen an encouraging people to
+ * use the setjmp buffer in this way I think that it
+ * is for the best then if changes occur compiles will
+ * break rather than just having new builds falling over
+ * mysteriously.
+ */
+
+#define _JB_MAGIC__SETJMP 0x4278f500
+#define _JB_MAGIC_SETJMP 0x4278f501
+
+/* Valid for all jmp_buf's */
+
+#define _JB_MAGIC 0
+#define _JB_REG_F4 1
+#define _JB_REG_F5 4
+#define _JB_REG_F6 7
+#define _JB_REG_F7 10
+#define _JB_REG_FPSR 13
+#define _JB_REG_R4 14
+#define _JB_REG_R5 15
+#define _JB_REG_R6 16
+#define _JB_REG_R7 17
+#define _JB_REG_R8 18
+#define _JB_REG_R9 19
+#define _JB_REG_R10 20
+#define _JB_REG_R11 21
+#define _JB_REG_R12 22
+#define _JB_REG_R13 23
+#define _JB_REG_R14 24
+
+/* Only valid with the _JB_MAGIC_SETJMP magic */
+
+#define _JB_SIGMASK 25
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/malloc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/malloc.h
new file mode 120000
index 000000000..78a8006cd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/malloc.h
@@ -0,0 +1 @@
+../../../common/include/malloc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/math.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/math.h
new file mode 120000
index 000000000..0d4bdcd86
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/math.h
@@ -0,0 +1 @@
+../../../common/include/math.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/memory.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/memory.h
new file mode 120000
index 000000000..08375e2b0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/memory.h
@@ -0,0 +1 @@
+../../../common/include/memory.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/mntent.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mntent.h
new file mode 120000
index 000000000..43186c4bc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mntent.h
@@ -0,0 +1 @@
+../../../common/include/mntent.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-abi.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-abi.h
new file mode 120000
index 000000000..19a9a517b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-abi.h
@@ -0,0 +1 @@
+../../../../common/include/mtd/mtd-abi.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-user.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-user.h
new file mode 120000
index 000000000..e22b96b9b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/mtd/mtd-user.h
@@ -0,0 +1 @@
+../../../../common/include/mtd/mtd-user.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/ethertypes.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/ethertypes.h
new file mode 120000
index 000000000..621864d41
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/ethertypes.h
@@ -0,0 +1 @@
+../../../../common/include/net/ethertypes.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if.h
new file mode 120000
index 000000000..c83fdb930
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if.h
@@ -0,0 +1 @@
+../../../../common/include/net/if.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_arp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_arp.h
new file mode 120000
index 000000000..e8e84bbf2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_arp.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_arp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_dl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_dl.h
new file mode 120000
index 000000000..1a27df4bb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_dl.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_dl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ether.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ether.h
new file mode 120000
index 000000000..591c1db04
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ether.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_ether.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ieee1394.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ieee1394.h
new file mode 120000
index 000000000..f0b13ceb0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_ieee1394.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_ieee1394.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_packet.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_packet.h
new file mode 120000
index 000000000..4c5bd8d15
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_packet.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_packet.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_types.h
new file mode 120000
index 000000000..410430f4a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/if_types.h
@@ -0,0 +1 @@
+../../../../common/include/net/if_types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/route.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/route.h
new file mode 120000
index 000000000..ea03206cd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/net/route.h
@@ -0,0 +1 @@
+../../../../common/include/net/route.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netdb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netdb.h
new file mode 120000
index 000000000..67f7a2f66
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netdb.h
@@ -0,0 +1 @@
+../../../common/include/netdb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ether.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ether.h
new file mode 120000
index 000000000..e331c47d7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ether.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/ether.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/if_ether.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/if_ether.h
new file mode 120000
index 000000000..5354bb582
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/if_ether.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/if_ether.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in.h
new file mode 120000
index 000000000..8439fe558
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/in.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in6.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in6.h
new file mode 120000
index 000000000..fa5937fb8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in6.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/in6.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in_systm.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in_systm.h
new file mode 120000
index 000000000..ea70a333b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/in_systm.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/in_systm.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip.h
new file mode 120000
index 000000000..3eb209768
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/ip.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip_icmp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip_icmp.h
new file mode 120000
index 000000000..2c9024fa2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/ip_icmp.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/ip_icmp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/tcp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/tcp.h
new file mode 120000
index 000000000..6b0d82947
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/tcp.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/tcp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/udp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/udp.h
new file mode 120000
index 000000000..d5e0f6b91
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netinet/udp.h
@@ -0,0 +1 @@
+../../../../common/include/netinet/udp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/netpacket/packet.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netpacket/packet.h
new file mode 120000
index 000000000..7473ba46f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/netpacket/packet.h
@@ -0,0 +1 @@
+../../../../common/include/netpacket/packet.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/new b/ndk/build/platforms/android-1.5/arch-arm/usr/include/new
new file mode 120000
index 000000000..b3e4225a6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/new
@@ -0,0 +1 @@
+../../../common/include/new
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/nsswitch.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/nsswitch.h
new file mode 120000
index 000000000..361ce3431
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/nsswitch.h
@@ -0,0 +1 @@
+../../../common/include/nsswitch.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/pathconf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pathconf.h
new file mode 120000
index 000000000..f1c45ca88
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pathconf.h
@@ -0,0 +1 @@
+../../../common/include/pathconf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/paths.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/paths.h
new file mode 120000
index 000000000..04b00c0b8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/paths.h
@@ -0,0 +1 @@
+../../../common/include/paths.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/poll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/poll.h
new file mode 120000
index 000000000..e260aad3e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/poll.h
@@ -0,0 +1 @@
+../../../common/include/poll.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/pthread.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pthread.h
new file mode 120000
index 000000000..e7240fe55
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pthread.h
@@ -0,0 +1 @@
+../../../common/include/pthread.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/pwd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pwd.h
new file mode 120000
index 000000000..deefc65f5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/pwd.h
@@ -0,0 +1 @@
+../../../common/include/pwd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/resolv.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/resolv.h
new file mode 120000
index 000000000..645cec6f3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/resolv.h
@@ -0,0 +1 @@
+../../../common/include/resolv.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sched.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sched.h
new file mode 120000
index 000000000..7eb75bc5b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sched.h
@@ -0,0 +1 @@
+../../../common/include/sched.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/semaphore.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/semaphore.h
new file mode 120000
index 000000000..5981819b2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/semaphore.h
@@ -0,0 +1 @@
+../../../common/include/semaphore.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/setjmp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/setjmp.h
new file mode 120000
index 000000000..927b88e3d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/setjmp.h
@@ -0,0 +1 @@
+../../../common/include/setjmp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sgtty.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sgtty.h
new file mode 120000
index 000000000..fcfac52dd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sgtty.h
@@ -0,0 +1 @@
+../../../common/include/sgtty.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sha1.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sha1.h
new file mode 120000
index 000000000..f4aadd27f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sha1.h
@@ -0,0 +1 @@
+../../../common/include/sha1.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/signal.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/signal.h
new file mode 120000
index 000000000..83e2e8ea7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/signal.h
@@ -0,0 +1 @@
+../../../common/include/signal.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdint.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdint.h
new file mode 120000
index 000000000..8b0dfbf1a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdint.h
@@ -0,0 +1 @@
+../../../common/include/stdint.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdio.h
new file mode 120000
index 000000000..41d7d040a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdio.h
@@ -0,0 +1 @@
+../../../common/include/stdio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdlib.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdlib.h
new file mode 120000
index 000000000..de97694cc
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stdlib.h
@@ -0,0 +1 @@
+../../../common/include/stdlib.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/stl_pair.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stl_pair.h
new file mode 120000
index 000000000..bfeaf5bd7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/stl_pair.h
@@ -0,0 +1 @@
+../../../common/include/stl_pair.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/string.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/string.h
new file mode 120000
index 000000000..ee1c46ab0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/string.h
@@ -0,0 +1 @@
+../../../common/include/string.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/strings.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/strings.h
new file mode 120000
index 000000000..e3c356d4f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/strings.h
@@ -0,0 +1 @@
+../../../common/include/strings.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_errdefs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_errdefs.h
new file mode 120000
index 000000000..b2a299e04
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_errdefs.h
@@ -0,0 +1 @@
+../../../../common/include/sys/_errdefs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_sigdefs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_sigdefs.h
new file mode 120000
index 000000000..ea48d378c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_sigdefs.h
@@ -0,0 +1 @@
+../../../../common/include/sys/_sigdefs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_system_properties.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_system_properties.h
new file mode 120000
index 000000000..6054cc498
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_system_properties.h
@@ -0,0 +1 @@
+../../../../common/include/sys/_system_properties.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_types.h
new file mode 120000
index 000000000..936b4d52a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/_types.h
@@ -0,0 +1 @@
+../../../../common/include/sys/_types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/atomics.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/atomics.h
new file mode 120000
index 000000000..03047948b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/atomics.h
@@ -0,0 +1 @@
+../../../../common/include/sys/atomics.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs.h
new file mode 120000
index 000000000..36eede70e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs.h
@@ -0,0 +1 @@
+../../../../common/include/sys/cdefs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs_elf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs_elf.h
new file mode 120000
index 000000000..fa852bfd1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/cdefs_elf.h
@@ -0,0 +1 @@
+../../../../common/include/sys/cdefs_elf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/dirent.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/dirent.h
new file mode 120000
index 000000000..cac02ee35
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/dirent.h
@@ -0,0 +1 @@
+../../../../common/include/sys/dirent.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/endian.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/endian.h
new file mode 120000
index 000000000..25109dbfe
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/endian.h
@@ -0,0 +1 @@
+../../../../common/include/sys/endian.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/epoll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/epoll.h
new file mode 120000
index 000000000..bf93fc622
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/epoll.h
@@ -0,0 +1 @@
+../../../../common/include/sys/epoll.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/errno.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/errno.h
new file mode 120000
index 000000000..199ad7852
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/errno.h
@@ -0,0 +1 @@
+../../../../common/include/sys/errno.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/exec_elf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/exec_elf.h
new file mode 120000
index 000000000..24e01e64d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/exec_elf.h
@@ -0,0 +1 @@
+../../../../common/include/sys/exec_elf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/file.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/file.h
new file mode 120000
index 000000000..99ab5d373
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/file.h
@@ -0,0 +1 @@
+../../../../common/include/sys/file.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/fsuid.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/fsuid.h
new file mode 120000
index 000000000..f5f997476
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/fsuid.h
@@ -0,0 +1 @@
+../../../../common/include/sys/fsuid.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/inotify.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/inotify.h
new file mode 120000
index 000000000..a05065343
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/inotify.h
@@ -0,0 +1 @@
+../../../../common/include/sys/inotify.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl.h
new file mode 120000
index 000000000..e228a66f7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ioctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl_compat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl_compat.h
new file mode 120000
index 000000000..dd004de1f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ioctl_compat.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ioctl_compat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ipc.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ipc.h
new file mode 120000
index 000000000..5d275f2e7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ipc.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ipc.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/klog.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/klog.h
new file mode 120000
index 000000000..4cad4c912
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/klog.h
@@ -0,0 +1 @@
+../../../../common/include/sys/klog.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/limits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/limits.h
new file mode 120000
index 000000000..4f5021458
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/limits.h
@@ -0,0 +1 @@
+../../../../common/include/sys/limits.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-syscalls.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-syscalls.h
new file mode 120000
index 000000000..754d7c490
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-syscalls.h
@@ -0,0 +1 @@
+../../../../common/include/sys/linux-syscalls.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-unistd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-unistd.h
new file mode 120000
index 000000000..9496fded7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/linux-unistd.h
@@ -0,0 +1 @@
+../../../../common/include/sys/linux-unistd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mman.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mman.h
new file mode 120000
index 000000000..bd6a6b86f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mman.h
@@ -0,0 +1 @@
+../../../../common/include/sys/mman.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mount.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mount.h
new file mode 120000
index 000000000..0b0a916f9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/mount.h
@@ -0,0 +1 @@
+../../../../common/include/sys/mount.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/param.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/param.h
new file mode 120000
index 000000000..16e5bcc3a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/param.h
@@ -0,0 +1 @@
+../../../../common/include/sys/param.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/poll.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/poll.h
new file mode 120000
index 000000000..a98ab69c9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/poll.h
@@ -0,0 +1 @@
+../../../../common/include/sys/poll.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/prctl.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/prctl.h
new file mode 120000
index 000000000..950d2fbba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/prctl.h
@@ -0,0 +1 @@
+../../../../common/include/sys/prctl.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ptrace.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ptrace.h
new file mode 120000
index 000000000..3b2714f96
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ptrace.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ptrace.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/reboot.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/reboot.h
new file mode 120000
index 000000000..8295ffc1d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/reboot.h
@@ -0,0 +1 @@
+../../../../common/include/sys/reboot.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/resource.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/resource.h
new file mode 120000
index 000000000..72a813f18
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/resource.h
@@ -0,0 +1 @@
+../../../../common/include/sys/resource.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/select.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/select.h
new file mode 120000
index 000000000..42f203708
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/select.h
@@ -0,0 +1 @@
+../../../../common/include/sys/select.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sendfile.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sendfile.h
new file mode 120000
index 000000000..ac4d8a051
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sendfile.h
@@ -0,0 +1 @@
+../../../../common/include/sys/sendfile.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socket.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socket.h
new file mode 120000
index 000000000..36a033101
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socket.h
@@ -0,0 +1 @@
+../../../../common/include/sys/socket.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socketcalls.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socketcalls.h
new file mode 120000
index 000000000..5e94809d0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/socketcalls.h
@@ -0,0 +1 @@
+../../../../common/include/sys/socketcalls.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/stat.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/stat.h
new file mode 120000
index 000000000..fa00c54f2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/stat.h
@@ -0,0 +1 @@
+../../../../common/include/sys/stat.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/statfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/statfs.h
new file mode 120000
index 000000000..d53806db2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/statfs.h
@@ -0,0 +1 @@
+../../../../common/include/sys/statfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syscall.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syscall.h
new file mode 120000
index 000000000..4225c352f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syscall.h
@@ -0,0 +1 @@
+../../../../common/include/sys/syscall.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysconf.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysconf.h
new file mode 120000
index 000000000..ed9cf1f1c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysconf.h
@@ -0,0 +1 @@
+../../../../common/include/sys/sysconf.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysinfo.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysinfo.h
new file mode 120000
index 000000000..1693d79a7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysinfo.h
@@ -0,0 +1 @@
+../../../../common/include/sys/sysinfo.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syslimits.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syslimits.h
new file mode 120000
index 000000000..17efa787c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/syslimits.h
@@ -0,0 +1 @@
+../../../../common/include/sys/syslimits.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysmacros.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysmacros.h
new file mode 120000
index 000000000..fa13ecad3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/sysmacros.h
@@ -0,0 +1 @@
+../../../../common/include/sys/sysmacros.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/system_properties.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/system_properties.h
new file mode 120000
index 000000000..286ba9dfa
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/system_properties.h
@@ -0,0 +1 @@
+../../../../common/include/sys/system_properties.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/time.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/time.h
new file mode 120000
index 000000000..b376430a1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/time.h
@@ -0,0 +1 @@
+../../../../common/include/sys/time.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/timeb.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/timeb.h
new file mode 120000
index 000000000..fef113e4f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/timeb.h
@@ -0,0 +1 @@
+../../../../common/include/sys/timeb.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/times.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/times.h
new file mode 120000
index 000000000..53c3a1ad3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/times.h
@@ -0,0 +1 @@
+../../../../common/include/sys/times.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttychars.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttychars.h
new file mode 120000
index 000000000..09c33524c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttychars.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ttychars.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttydev.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttydev.h
new file mode 120000
index 000000000..4735daa01
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/ttydev.h
@@ -0,0 +1 @@
+../../../../common/include/sys/ttydev.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/types.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/types.h
new file mode 120000
index 000000000..8829c6b7a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/types.h
@@ -0,0 +1 @@
+../../../../common/include/sys/types.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/uio.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/uio.h
new file mode 120000
index 000000000..a11120033
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/uio.h
@@ -0,0 +1 @@
+../../../../common/include/sys/uio.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/un.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/un.h
new file mode 120000
index 000000000..20d7c68b0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/un.h
@@ -0,0 +1 @@
+../../../../common/include/sys/un.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utime.h
new file mode 120000
index 000000000..84942479a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utime.h
@@ -0,0 +1 @@
+../../../../common/include/sys/utime.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utsname.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utsname.h
new file mode 120000
index 000000000..cf985f089
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/utsname.h
@@ -0,0 +1 @@
+../../../../common/include/sys/utsname.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vfs.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vfs.h
new file mode 120000
index 000000000..c4873c350
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vfs.h
@@ -0,0 +1 @@
+../../../../common/include/sys/vfs.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vt.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vt.h
new file mode 120000
index 000000000..55b3ed4b8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/vt.h
@@ -0,0 +1 @@
+../../../../common/include/sys/vt.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/wait.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/wait.h
new file mode 120000
index 000000000..9f27986d4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/sys/wait.h
@@ -0,0 +1 @@
+../../../../common/include/sys/wait.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/syslog.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/syslog.h
new file mode 120000
index 000000000..609c4e1b1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/syslog.h
@@ -0,0 +1 @@
+../../../common/include/syslog.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/termios.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/termios.h
new file mode 120000
index 000000000..53740f50e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/termios.h
@@ -0,0 +1 @@
+../../../common/include/termios.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/thread_db.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/thread_db.h
new file mode 120000
index 000000000..e6b5cedb8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/thread_db.h
@@ -0,0 +1 @@
+../../../common/include/thread_db.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/time.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/time.h
new file mode 120000
index 000000000..4ae3e0629
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/time.h
@@ -0,0 +1 @@
+../../../common/include/time.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/time64.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/time64.h
new file mode 120000
index 000000000..9e4ca23bf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/time64.h
@@ -0,0 +1 @@
+../../../common/include/time64.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/typeinfo b/ndk/build/platforms/android-1.5/arch-arm/usr/include/typeinfo
new file mode 120000
index 000000000..35bacb5c2
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/typeinfo
@@ -0,0 +1 @@
+../../../common/include/typeinfo
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/unistd.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/unistd.h
new file mode 120000
index 000000000..378e20d2c
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/unistd.h
@@ -0,0 +1 @@
+../../../common/include/unistd.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/util.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/util.h
new file mode 120000
index 000000000..c8de0fe75
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/util.h
@@ -0,0 +1 @@
+../../../common/include/util.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/utility b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utility
new file mode 120000
index 000000000..f670e6808
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utility
@@ -0,0 +1 @@
+../../../common/include/utility
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/utime.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utime.h
new file mode 120000
index 000000000..520a474dd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utime.h
@@ -0,0 +1 @@
+../../../common/include/utime.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/utmp.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utmp.h
new file mode 120000
index 000000000..9fe8b9529
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/utmp.h
@@ -0,0 +1 @@
+../../../common/include/utmp.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/wchar.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/wchar.h
new file mode 120000
index 000000000..5a35644ea
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/wchar.h
@@ -0,0 +1 @@
+../../../common/include/wchar.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/include/wctype.h b/ndk/build/platforms/android-1.5/arch-arm/usr/include/wctype.h
new file mode 120000
index 000000000..2a2a82310
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/arch-arm/usr/include/wctype.h
@@ -0,0 +1 @@
+../../../common/include/wctype.h
\ No newline at end of file
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_dynamic.o b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_dynamic.o
new file mode 100644
index 000000000..63d4efae4
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_dynamic.o differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_static.o b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_static.o
new file mode 100644
index 000000000..d11c79ebe
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtbegin_static.o differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtend_android.o b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtend_android.o
new file mode 100644
index 000000000..5b76af8da
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/crtend_android.o differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.a b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.a
new file mode 100644
index 000000000..4fdcafc41
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.a differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.so b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.so
new file mode 100644
index 000000000..9714e97e3
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libc.so differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libdl.so b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libdl.so
new file mode 100644
index 000000000..e2a589c61
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libdl.so differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.a b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.a
new file mode 100644
index 000000000..3e1ccb093
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.a differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.so b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.so
new file mode 100644
index 000000000..87f44460d
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libm.so differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.a b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.a
new file mode 100644
index 000000000..8f495a5d0
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.a differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.so b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.so
new file mode 100644
index 000000000..d3d103f2c
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libstdc++.so differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.a b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.a
new file mode 100644
index 000000000..9d634be38
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.a differ
diff --git a/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.so b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.so
new file mode 100644
index 000000000..ea603f079
Binary files /dev/null and b/ndk/build/platforms/android-1.5/arch-arm/usr/lib/libthread_db.so differ
diff --git a/ndk/build/platforms/android-1.5/common/include/alloca.h b/ndk/build/platforms/android-1.5/common/include/alloca.h
new file mode 100644
index 000000000..0c50fc310
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/alloca.h
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ALLOCA_H
+#define _ALLOCA_H
+
+#define alloca(size) __builtin_alloca(size)
+
+#endif /* _ALLOCA_H */
+
diff --git a/ndk/build/platforms/android-1.5/common/include/arpa/inet.h b/ndk/build/platforms/android-1.5/common/include/arpa/inet.h
new file mode 100644
index 000000000..3ebb872ec
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/arpa/inet.h
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ARPA_INET_H_
+#define _ARPA_INET_H_
+
+#include
+#include
+#include
+#include
+
+__BEGIN_DECLS
+
+typedef uint32_t in_addr_t;
+
+extern uint32_t inet_addr(const char *);
+
+extern int inet_aton(const char *, struct in_addr *);
+extern char* inet_ntoa(struct in_addr);
+
+extern int inet_pton(int, const char *, void *);
+extern const char* inet_ntop(int, const void *, char *, size_t);
+
+extern unsigned int inet_nsap_addr(const char *, unsigned char *, int);
+extern char* inet_nsap_ntoa(int, const unsigned char *, char *);
+
+__END_DECLS
+
+#endif /* _ARPA_INET_H_ */
+
+
diff --git a/ndk/build/platforms/android-1.5/common/include/arpa/nameser.h b/ndk/build/platforms/android-1.5/common/include/arpa/nameser.h
new file mode 100644
index 000000000..028eadced
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/arpa/nameser.h
@@ -0,0 +1,41 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _arpa_nameser_h
+#define _arpa_nameser_h
+
+#include
+#include
+
+/* this header intentionally blank
+ *
+ * the definitions normally found in are
+ * really a bunch of resolver's internal declarations that
+ * should not be exposed to client code in any way
+ */
+
+#endif /* _arpa_nameser_h */
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/4level-fixup.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/4level-fixup.h
new file mode 100644
index 000000000..91ae7f498
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/4level-fixup.h
@@ -0,0 +1,42 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _4LEVEL_FIXUP_H
+#define _4LEVEL_FIXUP_H
+
+#define __ARCH_HAS_4LEVEL_HACK
+#define __PAGETABLE_PUD_FOLDED
+
+#define PUD_SIZE PGDIR_SIZE
+#define PUD_MASK PGDIR_MASK
+#define PTRS_PER_PUD 1
+
+#define pud_t pgd_t
+
+#define pmd_alloc(mm, pud, address) ((unlikely(pgd_none(*(pud))) && __pmd_alloc(mm, pud, address))? NULL: pmd_offset(pud, address))
+
+#define pud_alloc(mm, pgd, address) (pgd)
+#define pud_offset(pgd, start) (pgd)
+#define pud_none(pud) 0
+#define pud_bad(pud) 0
+#define pud_present(pud) 1
+#define pud_ERROR(pud) do { } while (0)
+#define pud_clear(pud) pgd_clear(pud)
+
+#undef pud_free_tlb
+#define pud_free_tlb(tlb, x) do { } while (0)
+#define pud_free(x) do { } while (0)
+#define __pud_free_tlb(tlb, x) do { } while (0)
+
+#undef pud_addr_end
+#define pud_addr_end(addr, end) (end)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/audit_dir_write.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/audit_dir_write.h
new file mode 100644
index 000000000..1327b59d8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/audit_dir_write.h
@@ -0,0 +1,11 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/__ffs.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/__ffs.h
new file mode 100644
index 000000000..3d135bdb9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/__ffs.h
@@ -0,0 +1,19 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS___FFS_H_
+#define _ASM_GENERIC_BITOPS___FFS_H_
+
+#include
+
+#if BITS_PER_LONG == 64
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/atomic.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/atomic.h
new file mode 100644
index 000000000..5f53ba925
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/atomic.h
@@ -0,0 +1,23 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_ATOMIC_H_
+#define _ASM_GENERIC_BITOPS_ATOMIC_H_
+
+#include
+
+#define BITOP_MASK(nr) (1UL << ((nr) % BITS_PER_LONG))
+#define BITOP_WORD(nr) ((nr) / BITS_PER_LONG)
+
+#define _atomic_spin_lock_irqsave(l,f) do { local_irq_save(f); } while (0)
+#define _atomic_spin_unlock_irqrestore(l,f) do { local_irq_restore(f); } while (0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/ffz.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/ffz.h
new file mode 100644
index 000000000..18da271e4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/ffz.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_FFZ_H_
+#define _ASM_GENERIC_BITOPS_FFZ_H_
+
+#define ffz(x) __ffs(~(x))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/find.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/find.h
new file mode 100644
index 000000000..8361cfeab
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/find.h
@@ -0,0 +1,18 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_FIND_H_
+#define _ASM_GENERIC_BITOPS_FIND_H_
+
+#define find_first_bit(addr, size) find_next_bit((addr), (size), 0)
+#define find_first_zero_bit(addr, size) find_next_zero_bit((addr), (size), 0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls.h
new file mode 100644
index 000000000..8adbf3186
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_FLS_H_
+#define _ASM_GENERIC_BITOPS_FLS_H_
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls64.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls64.h
new file mode 100644
index 000000000..af77098fe
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/fls64.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_FLS64_H_
+#define _ASM_GENERIC_BITOPS_FLS64_H_
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/le.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/le.h
new file mode 100644
index 000000000..97ca97368
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/le.h
@@ -0,0 +1,53 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_LE_H_
+#define _ASM_GENERIC_BITOPS_LE_H_
+
+#include
+#include
+
+#define BITOP_WORD(nr) ((nr) / BITS_PER_LONG)
+#define BITOP_LE_SWIZZLE ((BITS_PER_LONG-1) & ~0x7)
+
+#ifdef __LITTLE_ENDIAN
+
+#define generic_test_le_bit(nr, addr) test_bit(nr, addr)
+#define generic___set_le_bit(nr, addr) __set_bit(nr, addr)
+#define generic___clear_le_bit(nr, addr) __clear_bit(nr, addr)
+
+#define generic_test_and_set_le_bit(nr, addr) test_and_set_bit(nr, addr)
+#define generic_test_and_clear_le_bit(nr, addr) test_and_clear_bit(nr, addr)
+
+#define generic___test_and_set_le_bit(nr, addr) __test_and_set_bit(nr, addr)
+#define generic___test_and_clear_le_bit(nr, addr) __test_and_clear_bit(nr, addr)
+
+#define generic_find_next_zero_le_bit(addr, size, offset) find_next_zero_bit(addr, size, offset)
+
+#elif defined(__BIG_ENDIAN)
+
+#define generic_test_le_bit(nr, addr) test_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+#define generic___set_le_bit(nr, addr) __set_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+#define generic___clear_le_bit(nr, addr) __clear_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+
+#define generic_test_and_set_le_bit(nr, addr) test_and_set_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+#define generic_test_and_clear_le_bit(nr, addr) test_and_clear_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+
+#define generic___test_and_set_le_bit(nr, addr) __test_and_set_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+#define generic___test_and_clear_le_bit(nr, addr) __test_and_clear_bit((nr) ^ BITOP_LE_SWIZZLE, (addr))
+
+#else
+#error "Please fix "
+#endif
+
+#define generic_find_first_zero_le_bit(addr, size) generic_find_next_zero_le_bit((addr), (size), 0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/non-atomic.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/non-atomic.h
new file mode 100644
index 000000000..727f7362d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bitops/non-atomic.h
@@ -0,0 +1,20 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BITOPS_NON_ATOMIC_H_
+#define _ASM_GENERIC_BITOPS_NON_ATOMIC_H_
+
+#include
+
+#define BITOP_MASK(nr) (1UL << ((nr) % BITS_PER_LONG))
+#define BITOP_WORD(nr) ((nr) / BITS_PER_LONG)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/bug.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/bug.h
new file mode 100644
index 000000000..d91a135cf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/bug.h
@@ -0,0 +1,33 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_BUG_H
+#define _ASM_GENERIC_BUG_H
+
+#include
+
+#ifndef HAVE_ARCH_BUG
+#define BUG()
+#endif
+
+#ifndef HAVE_ARCH_BUG_ON
+#define BUG_ON(condition) do { if (condition) ; } while(0)
+#endif
+
+#ifndef HAVE_ARCH_WARN_ON
+#define WARN_ON(condition) do { if (condition) ; } while(0)
+#endif
+
+#define WARN_ON_ONCE(condition) ({ static int __warn_once = 1; int __ret = 0; if (unlikely((condition) && __warn_once)) { __warn_once = 0; WARN_ON(1); __ret = 1; } __ret; })
+
+#define WARN_ON_SMP(x) do { } while (0)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/cputime.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/cputime.h
new file mode 100644
index 000000000..0486b87b1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/cputime.h
@@ -0,0 +1,60 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_CPUTIME_H
+#define _ASM_GENERIC_CPUTIME_H
+
+#include
+#include
+
+typedef unsigned long cputime_t;
+
+#define cputime_zero (0UL)
+#define cputime_max ((~0UL >> 1) - 1)
+#define cputime_add(__a, __b) ((__a) + (__b))
+#define cputime_sub(__a, __b) ((__a) - (__b))
+#define cputime_div(__a, __n) ((__a) / (__n))
+#define cputime_halve(__a) ((__a) >> 1)
+#define cputime_eq(__a, __b) ((__a) == (__b))
+#define cputime_gt(__a, __b) ((__a) > (__b))
+#define cputime_ge(__a, __b) ((__a) >= (__b))
+#define cputime_lt(__a, __b) ((__a) < (__b))
+#define cputime_le(__a, __b) ((__a) <= (__b))
+#define cputime_to_jiffies(__ct) (__ct)
+#define jiffies_to_cputime(__hz) (__hz)
+
+typedef u64 cputime64_t;
+
+#define cputime64_zero (0ULL)
+#define cputime64_add(__a, __b) ((__a) + (__b))
+#define cputime64_sub(__a, __b) ((__a) - (__b))
+#define cputime64_to_jiffies64(__ct) (__ct)
+#define jiffies64_to_cputime64(__jif) (__jif)
+#define cputime_to_cputime64(__ct) ((u64) __ct)
+
+#define cputime_to_msecs(__ct) jiffies_to_msecs(__ct)
+#define msecs_to_cputime(__msecs) msecs_to_jiffies(__msecs)
+
+#define cputime_to_secs(jif) ((jif) / HZ)
+#define secs_to_cputime(sec) ((sec) * HZ)
+
+#define timespec_to_cputime(__val) timespec_to_jiffies(__val)
+#define cputime_to_timespec(__ct,__val) jiffies_to_timespec(__ct,__val)
+
+#define timeval_to_cputime(__val) timeval_to_jiffies(__val)
+#define cputime_to_timeval(__ct,__val) jiffies_to_timeval(__ct,__val)
+
+#define cputime_to_clock_t(__ct) jiffies_to_clock_t(__ct)
+#define clock_t_to_cputime(__x) clock_t_to_jiffies(__x)
+
+#define cputime64_to_clock_t(__ct) jiffies_64_to_clock_t(__ct)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/emergency-restart.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/emergency-restart.h
new file mode 100644
index 000000000..619c68241
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/emergency-restart.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_EMERGENCY_RESTART_H
+#define _ASM_GENERIC_EMERGENCY_RESTART_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/errno-base.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/errno-base.h
new file mode 100644
index 000000000..2fb4a3364
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/errno-base.h
@@ -0,0 +1,50 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_ERRNO_BASE_H
+#define _ASM_GENERIC_ERRNO_BASE_H
+
+#define EPERM 1
+#define ENOENT 2
+#define ESRCH 3
+#define EINTR 4
+#define EIO 5
+#define ENXIO 6
+#define E2BIG 7
+#define ENOEXEC 8
+#define EBADF 9
+#define ECHILD 10
+#define EAGAIN 11
+#define ENOMEM 12
+#define EACCES 13
+#define EFAULT 14
+#define ENOTBLK 15
+#define EBUSY 16
+#define EEXIST 17
+#define EXDEV 18
+#define ENODEV 19
+#define ENOTDIR 20
+#define EISDIR 21
+#define EINVAL 22
+#define ENFILE 23
+#define EMFILE 24
+#define ENOTTY 25
+#define ETXTBSY 26
+#define EFBIG 27
+#define ENOSPC 28
+#define ESPIPE 29
+#define EROFS 30
+#define EMLINK 31
+#define EPIPE 32
+#define EDOM 33
+#define ERANGE 34
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/errno.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/errno.h
new file mode 100644
index 000000000..11dd00f33
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/errno.h
@@ -0,0 +1,119 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_ERRNO_H
+#define _ASM_GENERIC_ERRNO_H
+
+#include
+
+#define EDEADLK 35
+#define ENAMETOOLONG 36
+#define ENOLCK 37
+#define ENOSYS 38
+#define ENOTEMPTY 39
+#define ELOOP 40
+#define EWOULDBLOCK EAGAIN
+#define ENOMSG 42
+#define EIDRM 43
+#define ECHRNG 44
+#define EL2NSYNC 45
+#define EL3HLT 46
+#define EL3RST 47
+#define ELNRNG 48
+#define EUNATCH 49
+#define ENOCSI 50
+#define EL2HLT 51
+#define EBADE 52
+#define EBADR 53
+#define EXFULL 54
+#define ENOANO 55
+#define EBADRQC 56
+#define EBADSLT 57
+
+#define EDEADLOCK EDEADLK
+
+#define EBFONT 59
+#define ENOSTR 60
+#define ENODATA 61
+#define ETIME 62
+#define ENOSR 63
+#define ENONET 64
+#define ENOPKG 65
+#define EREMOTE 66
+#define ENOLINK 67
+#define EADV 68
+#define ESRMNT 69
+#define ECOMM 70
+#define EPROTO 71
+#define EMULTIHOP 72
+#define EDOTDOT 73
+#define EBADMSG 74
+#define EOVERFLOW 75
+#define ENOTUNIQ 76
+#define EBADFD 77
+#define EREMCHG 78
+#define ELIBACC 79
+#define ELIBBAD 80
+#define ELIBSCN 81
+#define ELIBMAX 82
+#define ELIBEXEC 83
+#define EILSEQ 84
+#define ERESTART 85
+#define ESTRPIPE 86
+#define EUSERS 87
+#define ENOTSOCK 88
+#define EDESTADDRREQ 89
+#define EMSGSIZE 90
+#define EPROTOTYPE 91
+#define ENOPROTOOPT 92
+#define EPROTONOSUPPORT 93
+#define ESOCKTNOSUPPORT 94
+#define EOPNOTSUPP 95
+#define EPFNOSUPPORT 96
+#define EAFNOSUPPORT 97
+#define EADDRINUSE 98
+#define EADDRNOTAVAIL 99
+#define ENETDOWN 100
+#define ENETUNREACH 101
+#define ENETRESET 102
+#define ECONNABORTED 103
+#define ECONNRESET 104
+#define ENOBUFS 105
+#define EISCONN 106
+#define ENOTCONN 107
+#define ESHUTDOWN 108
+#define ETOOMANYREFS 109
+#define ETIMEDOUT 110
+#define ECONNREFUSED 111
+#define EHOSTDOWN 112
+#define EHOSTUNREACH 113
+#define EALREADY 114
+#define EINPROGRESS 115
+#define ESTALE 116
+#define EUCLEAN 117
+#define ENOTNAM 118
+#define ENAVAIL 119
+#define EISNAM 120
+#define EREMOTEIO 121
+#define EDQUOT 122
+
+#define ENOMEDIUM 123
+#define EMEDIUMTYPE 124
+#define ECANCELED 125
+#define ENOKEY 126
+#define EKEYEXPIRED 127
+#define EKEYREVOKED 128
+#define EKEYREJECTED 129
+
+#define EOWNERDEAD 130
+#define ENOTRECOVERABLE 131
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/fcntl.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/fcntl.h
new file mode 100644
index 000000000..a53b536fb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/fcntl.h
@@ -0,0 +1,148 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_FCNTL_H
+#define _ASM_GENERIC_FCNTL_H
+
+#include
+
+#define O_ACCMODE 00000003
+#define O_RDONLY 00000000
+#define O_WRONLY 00000001
+#define O_RDWR 00000002
+#ifndef O_CREAT
+#define O_CREAT 00000100
+#endif
+#ifndef O_EXCL
+#define O_EXCL 00000200
+#endif
+#ifndef O_NOCTTY
+#define O_NOCTTY 00000400
+#endif
+#ifndef O_TRUNC
+#define O_TRUNC 00001000
+#endif
+#ifndef O_APPEND
+#define O_APPEND 00002000
+#endif
+#ifndef O_NONBLOCK
+#define O_NONBLOCK 00004000
+#endif
+#ifndef O_SYNC
+#define O_SYNC 00010000
+#endif
+#ifndef FASYNC
+#define FASYNC 00020000
+#endif
+#ifndef O_DIRECT
+#define O_DIRECT 00040000
+#endif
+#ifndef O_LARGEFILE
+#define O_LARGEFILE 00100000
+#endif
+#ifndef O_DIRECTORY
+#define O_DIRECTORY 00200000
+#endif
+#ifndef O_NOFOLLOW
+#define O_NOFOLLOW 00400000
+#endif
+#ifndef O_NOATIME
+#define O_NOATIME 01000000
+#endif
+#ifndef O_NDELAY
+#define O_NDELAY O_NONBLOCK
+#endif
+
+#define F_DUPFD 0
+#define F_GETFD 1
+#define F_SETFD 2
+#define F_GETFL 3
+#define F_SETFL 4
+#ifndef F_GETLK
+#define F_GETLK 5
+#define F_SETLK 6
+#define F_SETLKW 7
+#endif
+#ifndef F_SETOWN
+#define F_SETOWN 8
+#define F_GETOWN 9
+#endif
+#ifndef F_SETSIG
+#define F_SETSIG 10
+#define F_GETSIG 11
+#endif
+
+#define FD_CLOEXEC 1
+
+#ifndef F_RDLCK
+#define F_RDLCK 0
+#define F_WRLCK 1
+#define F_UNLCK 2
+#endif
+
+#ifndef F_EXLCK
+#define F_EXLCK 4
+#define F_SHLCK 8
+#endif
+
+#ifndef F_INPROGRESS
+#define F_INPROGRESS 16
+#endif
+
+#define LOCK_SH 1
+#define LOCK_EX 2
+#define LOCK_NB 4
+#define LOCK_UN 8
+
+#define LOCK_MAND 32
+#define LOCK_READ 64
+#define LOCK_WRITE 128
+#define LOCK_RW 192
+
+#define F_LINUX_SPECIFIC_BASE 1024
+
+#ifndef HAVE_ARCH_STRUCT_FLOCK
+#ifndef __ARCH_FLOCK_PAD
+#define __ARCH_FLOCK_PAD
+#endif
+
+struct flock {
+ short l_type;
+ short l_whence;
+ off_t l_start;
+ off_t l_len;
+ pid_t l_pid;
+ __ARCH_FLOCK_PAD
+};
+#endif
+
+#ifndef F_GETLK64
+#define F_GETLK64 12
+#define F_SETLK64 13
+#define F_SETLKW64 14
+#endif
+
+#ifndef HAVE_ARCH_STRUCT_FLOCK64
+#ifndef __ARCH_FLOCK64_PAD
+#define __ARCH_FLOCK64_PAD
+#endif
+
+struct flock64 {
+ short l_type;
+ short l_whence;
+ loff_t l_start;
+ loff_t l_len;
+ pid_t l_pid;
+ __ARCH_FLOCK64_PAD
+};
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/futex.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/futex.h
new file mode 100644
index 000000000..05d3afed4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/futex.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_FUTEX_H
+#define _ASM_GENERIC_FUTEX_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/ioctl.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/ioctl.h
new file mode 100644
index 000000000..cba2b8ecf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/ioctl.h
@@ -0,0 +1,58 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_IOCTL_H
+#define _ASM_GENERIC_IOCTL_H
+
+#define _IOC_NRBITS 8
+#define _IOC_TYPEBITS 8
+#define _IOC_SIZEBITS 14
+#define _IOC_DIRBITS 2
+
+#define _IOC_NRMASK ((1 << _IOC_NRBITS)-1)
+#define _IOC_TYPEMASK ((1 << _IOC_TYPEBITS)-1)
+#define _IOC_SIZEMASK ((1 << _IOC_SIZEBITS)-1)
+#define _IOC_DIRMASK ((1 << _IOC_DIRBITS)-1)
+
+#define _IOC_NRSHIFT 0
+#define _IOC_TYPESHIFT (_IOC_NRSHIFT+_IOC_NRBITS)
+#define _IOC_SIZESHIFT (_IOC_TYPESHIFT+_IOC_TYPEBITS)
+#define _IOC_DIRSHIFT (_IOC_SIZESHIFT+_IOC_SIZEBITS)
+
+#define _IOC_NONE 0U
+#define _IOC_WRITE 1U
+#define _IOC_READ 2U
+
+#define _IOC(dir,type,nr,size) (((dir) << _IOC_DIRSHIFT) | ((type) << _IOC_TYPESHIFT) | ((nr) << _IOC_NRSHIFT) | ((size) << _IOC_SIZESHIFT))
+
+extern unsigned int __invalid_size_argument_for_IOC;
+#define _IOC_TYPECHECK(t) ((sizeof(t) == sizeof(t[1]) && sizeof(t) < (1 << _IOC_SIZEBITS)) ? sizeof(t) : __invalid_size_argument_for_IOC)
+
+#define _IO(type,nr) _IOC(_IOC_NONE,(type),(nr),0)
+#define _IOR(type,nr,size) _IOC(_IOC_READ,(type),(nr),(_IOC_TYPECHECK(size)))
+#define _IOW(type,nr,size) _IOC(_IOC_WRITE,(type),(nr),(_IOC_TYPECHECK(size)))
+#define _IOWR(type,nr,size) _IOC(_IOC_READ|_IOC_WRITE,(type),(nr),(_IOC_TYPECHECK(size)))
+#define _IOR_BAD(type,nr,size) _IOC(_IOC_READ,(type),(nr),sizeof(size))
+#define _IOW_BAD(type,nr,size) _IOC(_IOC_WRITE,(type),(nr),sizeof(size))
+#define _IOWR_BAD(type,nr,size) _IOC(_IOC_READ|_IOC_WRITE,(type),(nr),sizeof(size))
+
+#define _IOC_DIR(nr) (((nr) >> _IOC_DIRSHIFT) & _IOC_DIRMASK)
+#define _IOC_TYPE(nr) (((nr) >> _IOC_TYPESHIFT) & _IOC_TYPEMASK)
+#define _IOC_NR(nr) (((nr) >> _IOC_NRSHIFT) & _IOC_NRMASK)
+#define _IOC_SIZE(nr) (((nr) >> _IOC_SIZESHIFT) & _IOC_SIZEMASK)
+
+#define IOC_IN (_IOC_WRITE << _IOC_DIRSHIFT)
+#define IOC_OUT (_IOC_READ << _IOC_DIRSHIFT)
+#define IOC_INOUT ((_IOC_WRITE|_IOC_READ) << _IOC_DIRSHIFT)
+#define IOCSIZE_MASK (_IOC_SIZEMASK << _IOC_SIZESHIFT)
+#define IOCSIZE_SHIFT (_IOC_SIZESHIFT)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/ipc.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/ipc.h
new file mode 100644
index 000000000..57657a776
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/ipc.h
@@ -0,0 +1,37 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_IPC_H
+#define _ASM_GENERIC_IPC_H
+
+struct ipc_kludge {
+ struct msgbuf __user *msgp;
+ long msgtyp;
+};
+
+#define SEMOP 1
+#define SEMGET 2
+#define SEMCTL 3
+#define SEMTIMEDOP 4
+#define MSGSND 11
+#define MSGRCV 12
+#define MSGGET 13
+#define MSGCTL 14
+#define SHMAT 21
+#define SHMDT 22
+#define SHMGET 23
+#define SHMCTL 24
+
+#define DIPC 25
+
+#define IPCCALL(version,op) ((version)<<16 | (op))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/local.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/local.h
new file mode 100644
index 000000000..cae0d5416
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/local.h
@@ -0,0 +1,51 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_LOCAL_H
+#define _ASM_GENERIC_LOCAL_H
+
+#include
+#include
+#include
+#include
+
+typedef struct
+{
+ atomic_long_t a;
+} local_t;
+
+#define LOCAL_INIT(i) { ATOMIC_LONG_INIT(i) }
+
+#define local_read(l) atomic_long_read(&(l)->a)
+#define local_set(l,i) atomic_long_set((&(l)->a),(i))
+#define local_inc(l) atomic_long_inc(&(l)->a)
+#define local_dec(l) atomic_long_dec(&(l)->a)
+#define local_add(i,l) atomic_long_add((i),(&(l)->a))
+#define local_sub(i,l) atomic_long_sub((i),(&(l)->a))
+
+#define __local_inc(l) local_set((l), local_read(l) + 1)
+#define __local_dec(l) local_set((l), local_read(l) - 1)
+#define __local_add(i,l) local_set((l), local_read(l) + (i))
+#define __local_sub(i,l) local_set((l), local_read(l) - (i))
+
+#define cpu_local_read(v) local_read(&__get_cpu_var(v))
+#define cpu_local_set(v, i) local_set(&__get_cpu_var(v), (i))
+#define cpu_local_inc(v) local_inc(&__get_cpu_var(v))
+#define cpu_local_dec(v) local_dec(&__get_cpu_var(v))
+#define cpu_local_add(i, v) local_add((i), &__get_cpu_var(v))
+#define cpu_local_sub(i, v) local_sub((i), &__get_cpu_var(v))
+
+#define __cpu_local_inc(v) __local_inc(&__get_cpu_var(v))
+#define __cpu_local_dec(v) __local_dec(&__get_cpu_var(v))
+#define __cpu_local_add(i, v) __local_add((i), &__get_cpu_var(v))
+#define __cpu_local_sub(i, v) __local_sub((i), &__get_cpu_var(v))
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/memory_model.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/memory_model.h
new file mode 100644
index 000000000..fa7602e67
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/memory_model.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_MEMORY_MODEL_H
+#define __ASM_MEMORY_MODEL_H
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/mman.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/mman.h
new file mode 100644
index 000000000..98d278303
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/mman.h
@@ -0,0 +1,46 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_MMAN_H
+#define _ASM_GENERIC_MMAN_H
+
+#define PROT_READ 0x1
+#define PROT_WRITE 0x2
+#define PROT_EXEC 0x4
+#define PROT_SEM 0x8
+#define PROT_NONE 0x0
+#define PROT_GROWSDOWN 0x01000000
+#define PROT_GROWSUP 0x02000000
+
+#define MAP_SHARED 0x01
+#define MAP_PRIVATE 0x02
+#define MAP_TYPE 0x0f
+#define MAP_FIXED 0x10
+#define MAP_ANONYMOUS 0x20
+
+#define MS_ASYNC 1
+#define MS_INVALIDATE 2
+#define MS_SYNC 4
+
+#define MADV_NORMAL 0
+#define MADV_RANDOM 1
+#define MADV_SEQUENTIAL 2
+#define MADV_WILLNEED 3
+#define MADV_DONTNEED 4
+
+#define MADV_REMOVE 9
+#define MADV_DONTFORK 10
+#define MADV_DOFORK 11
+
+#define MAP_ANON MAP_ANONYMOUS
+#define MAP_FILE 0
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/mutex-xchg.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/mutex-xchg.h
new file mode 100644
index 000000000..63a557ec5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/mutex-xchg.h
@@ -0,0 +1,16 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_MUTEX_XCHG_H
+#define _ASM_GENERIC_MUTEX_XCHG_H
+
+#define __mutex_slowpath_needs_to_unlock() 0
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/percpu.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/percpu.h
new file mode 100644
index 000000000..e49830003
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/percpu.h
@@ -0,0 +1,29 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_PERCPU_H_
+#define _ASM_GENERIC_PERCPU_H_
+#include
+
+#define __GENERIC_PER_CPU
+
+#define DEFINE_PER_CPU(type, name) __typeof__(type) per_cpu__##name
+
+#define per_cpu(var, cpu) (*((void)(cpu), &per_cpu__##var))
+#define __get_cpu_var(var) per_cpu__##var
+#define __raw_get_cpu_var(var) per_cpu__##var
+
+#define DECLARE_PER_CPU(type, name) extern __typeof__(type) per_cpu__##name
+
+#define EXPORT_PER_CPU_SYMBOL(var) EXPORT_SYMBOL(per_cpu__##var)
+#define EXPORT_PER_CPU_SYMBOL_GPL(var) EXPORT_SYMBOL_GPL(per_cpu__##var)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable-nopud.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable-nopud.h
new file mode 100644
index 000000000..585f81654
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable-nopud.h
@@ -0,0 +1,39 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _PGTABLE_NOPUD_H
+#define _PGTABLE_NOPUD_H
+
+#ifndef __ASSEMBLY__
+
+#define __PAGETABLE_PUD_FOLDED
+
+typedef struct { pgd_t pgd; } pud_t;
+
+#define PUD_SHIFT PGDIR_SHIFT
+#define PTRS_PER_PUD 1
+#define PUD_SIZE (1UL << PUD_SHIFT)
+#define PUD_MASK (~(PUD_SIZE-1))
+
+#define pud_ERROR(pud) (pgd_ERROR((pud).pgd))
+#define pgd_populate(mm, pgd, pud) do { } while (0)
+#define set_pgd(pgdptr, pgdval) set_pud((pud_t *)(pgdptr), (pud_t) { pgdval })
+#define pud_val(x) (pgd_val((x).pgd))
+#define __pud(x) ((pud_t) { __pgd(x) } )
+#define pgd_page(pgd) (pud_page((pud_t){ pgd }))
+#define pgd_page_kernel(pgd) (pud_page_kernel((pud_t){ pgd }))
+#define pud_alloc_one(mm, address) NULL
+#define pud_free(x) do { } while (0)
+#define __pud_free_tlb(tlb, x) do { } while (0)
+#undef pud_addr_end
+#define pud_addr_end(addr, end) (end)
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable.h
new file mode 100644
index 000000000..a21cdba0d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/pgtable.h
@@ -0,0 +1,95 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_PGTABLE_H
+#define _ASM_GENERIC_PGTABLE_H
+
+#ifndef __HAVE_ARCH_PTEP_ESTABLISH
+
+#ifndef __HAVE_ARCH_SET_PTE_ATOMIC
+#define ptep_establish(__vma, __address, __ptep, __entry) do { set_pte_at((__vma)->vm_mm, (__address), __ptep, __entry); flush_tlb_page(__vma, __address); } while (0)
+#else
+#define ptep_establish(__vma, __address, __ptep, __entry) do { set_pte_atomic(__ptep, __entry); flush_tlb_page(__vma, __address); } while (0)
+#endif
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_SET_ACCESS_FLAGS
+
+#define ptep_set_access_flags(__vma, __address, __ptep, __entry, __dirty) do { set_pte_at((__vma)->vm_mm, (__address), __ptep, __entry); flush_tlb_page(__vma, __address); } while (0)
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_TEST_AND_CLEAR_YOUNG
+#define ptep_test_and_clear_young(__vma, __address, __ptep) ({ pte_t __pte = *(__ptep); int r = 1; if (!pte_young(__pte)) r = 0; else set_pte_at((__vma)->vm_mm, (__address), (__ptep), pte_mkold(__pte)); r; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_CLEAR_YOUNG_FLUSH
+#define ptep_clear_flush_young(__vma, __address, __ptep) ({ int __young; __young = ptep_test_and_clear_young(__vma, __address, __ptep); if (__young) flush_tlb_page(__vma, __address); __young; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_TEST_AND_CLEAR_DIRTY
+#define ptep_test_and_clear_dirty(__vma, __address, __ptep) ({ pte_t __pte = *__ptep; int r = 1; if (!pte_dirty(__pte)) r = 0; else set_pte_at((__vma)->vm_mm, (__address), (__ptep), pte_mkclean(__pte)); r; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_CLEAR_DIRTY_FLUSH
+#define ptep_clear_flush_dirty(__vma, __address, __ptep) ({ int __dirty; __dirty = ptep_test_and_clear_dirty(__vma, __address, __ptep); if (__dirty) flush_tlb_page(__vma, __address); __dirty; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_GET_AND_CLEAR
+#define ptep_get_and_clear(__mm, __address, __ptep) ({ pte_t __pte = *(__ptep); pte_clear((__mm), (__address), (__ptep)); __pte; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_GET_AND_CLEAR_FULL
+#define ptep_get_and_clear_full(__mm, __address, __ptep, __full) ({ pte_t __pte; __pte = ptep_get_and_clear((__mm), (__address), (__ptep)); __pte; })
+#endif
+
+#ifndef __HAVE_ARCH_PTE_CLEAR_FULL
+#define pte_clear_full(__mm, __address, __ptep, __full) do { pte_clear((__mm), (__address), (__ptep)); } while (0)
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_CLEAR_FLUSH
+#define ptep_clear_flush(__vma, __address, __ptep) ({ pte_t __pte; __pte = ptep_get_and_clear((__vma)->vm_mm, __address, __ptep); flush_tlb_page(__vma, __address); __pte; })
+#endif
+
+#ifndef __HAVE_ARCH_PTEP_SET_WRPROTECT
+struct mm_struct;
+#endif
+#ifndef __HAVE_ARCH_PTE_SAME
+#define pte_same(A,B) (pte_val(A) == pte_val(B))
+#endif
+#ifndef __HAVE_ARCH_PAGE_TEST_AND_CLEAR_DIRTY
+#define page_test_and_clear_dirty(page) (0)
+#define pte_maybe_dirty(pte) pte_dirty(pte)
+#else
+#define pte_maybe_dirty(pte) (1)
+#endif
+#ifndef __HAVE_ARCH_PAGE_TEST_AND_CLEAR_YOUNG
+#define page_test_and_clear_young(page) (0)
+#endif
+#ifndef __HAVE_ARCH_PGD_OFFSET_GATE
+#define pgd_offset_gate(mm, addr) pgd_offset(mm, addr)
+#endif
+#ifndef __HAVE_ARCH_LAZY_MMU_PROT_UPDATE
+#define lazy_mmu_prot_update(pte) do { } while (0)
+#endif
+#ifndef __HAVE_ARCH_MOVE_PTE
+#define move_pte(pte, prot, old_addr, new_addr) (pte)
+#endif
+#define pgd_addr_end(addr, end) ({ unsigned long __boundary = ((addr) + PGDIR_SIZE) & PGDIR_MASK; (__boundary - 1 < (end) - 1)? __boundary: (end); })
+#ifndef pud_addr_end
+#define pud_addr_end(addr, end) ({ unsigned long __boundary = ((addr) + PUD_SIZE) & PUD_MASK; (__boundary - 1 < (end) - 1)? __boundary: (end); })
+#endif
+#ifndef pmd_addr_end
+#define pmd_addr_end(addr, end) ({ unsigned long __boundary = ((addr) + PMD_SIZE) & PMD_MASK; (__boundary - 1 < (end) - 1)? __boundary: (end); })
+#endif
+#ifndef __ASSEMBLY__
+
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/poll.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/poll.h
new file mode 100644
index 000000000..b8cd3da85
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/poll.h
@@ -0,0 +1,46 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_GENERIC_POLL_H
+#define __ASM_GENERIC_POLL_H
+
+#define POLLIN 0x0001
+#define POLLPRI 0x0002
+#define POLLOUT 0x0004
+#define POLLERR 0x0008
+#define POLLHUP 0x0010
+#define POLLNVAL 0x0020
+
+#define POLLRDNORM 0x0040
+#define POLLRDBAND 0x0080
+#ifndef POLLWRNORM
+#define POLLWRNORM 0x0100
+#endif
+#ifndef POLLWRBAND
+#define POLLWRBAND 0x0200
+#endif
+#ifndef POLLMSG
+#define POLLMSG 0x0400
+#endif
+#ifndef POLLREMOVE
+#define POLLREMOVE 0x1000
+#endif
+#ifndef POLLRDHUP
+#define POLLRDHUP 0x2000
+#endif
+
+struct pollfd {
+ int fd;
+ short events;
+ short revents;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/resource.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/resource.h
new file mode 100644
index 000000000..a7f7decba
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/resource.h
@@ -0,0 +1,57 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_RESOURCE_H
+#define _ASM_GENERIC_RESOURCE_H
+
+#define RLIMIT_CPU 0
+#define RLIMIT_FSIZE 1
+#define RLIMIT_DATA 2
+#define RLIMIT_STACK 3
+#define RLIMIT_CORE 4
+
+#ifndef RLIMIT_RSS
+#define RLIMIT_RSS 5
+#endif
+
+#ifndef RLIMIT_NPROC
+#define RLIMIT_NPROC 6
+#endif
+
+#ifndef RLIMIT_NOFILE
+#define RLIMIT_NOFILE 7
+#endif
+
+#ifndef RLIMIT_MEMLOCK
+#define RLIMIT_MEMLOCK 8
+#endif
+
+#ifndef RLIMIT_AS
+#define RLIMIT_AS 9
+#endif
+
+#define RLIMIT_LOCKS 10
+#define RLIMIT_SIGPENDING 11
+#define RLIMIT_MSGQUEUE 12
+#define RLIMIT_NICE 13
+#define RLIMIT_RTPRIO 14
+
+#define RLIM_NLIMITS 15
+
+#ifndef RLIM_INFINITY
+#define RLIM_INFINITY (~0UL)
+#endif
+
+#ifndef _STK_LIM_MAX
+#define _STK_LIM_MAX RLIM_INFINITY
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/sections.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/sections.h
new file mode 100644
index 000000000..e9eaa4668
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/sections.h
@@ -0,0 +1,15 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_SECTIONS_H_
+#define _ASM_GENERIC_SECTIONS_H_
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/siginfo.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/siginfo.h
new file mode 100644
index 000000000..d6743a732
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/siginfo.h
@@ -0,0 +1,213 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_SIGINFO_H
+#define _ASM_GENERIC_SIGINFO_H
+
+#include
+#include
+
+typedef union sigval {
+ int sival_int;
+ void __user *sival_ptr;
+} sigval_t;
+
+#ifndef __ARCH_SI_PREAMBLE_SIZE
+#define __ARCH_SI_PREAMBLE_SIZE (3 * sizeof(int))
+#endif
+
+#define SI_MAX_SIZE 128
+#ifndef SI_PAD_SIZE
+#define SI_PAD_SIZE ((SI_MAX_SIZE - __ARCH_SI_PREAMBLE_SIZE) / sizeof(int))
+#endif
+
+#ifndef __ARCH_SI_UID_T
+#define __ARCH_SI_UID_T uid_t
+#endif
+
+#ifndef __ARCH_SI_BAND_T
+#define __ARCH_SI_BAND_T long
+#endif
+
+#ifndef HAVE_ARCH_SIGINFO_T
+
+typedef struct siginfo {
+ int si_signo;
+ int si_errno;
+ int si_code;
+
+ union {
+ int _pad[SI_PAD_SIZE];
+
+ struct {
+ pid_t _pid;
+ __ARCH_SI_UID_T _uid;
+ } _kill;
+
+ struct {
+ timer_t _tid;
+ int _overrun;
+ char _pad[sizeof( __ARCH_SI_UID_T) - sizeof(int)];
+ sigval_t _sigval;
+ int _sys_private;
+ } _timer;
+
+ struct {
+ pid_t _pid;
+ __ARCH_SI_UID_T _uid;
+ sigval_t _sigval;
+ } _rt;
+
+ struct {
+ pid_t _pid;
+ __ARCH_SI_UID_T _uid;
+ int _status;
+ clock_t _utime;
+ clock_t _stime;
+ } _sigchld;
+
+ struct {
+ void __user *_addr;
+#ifdef __ARCH_SI_TRAPNO
+ int _trapno;
+#endif
+ } _sigfault;
+
+ struct {
+ __ARCH_SI_BAND_T _band;
+ int _fd;
+ } _sigpoll;
+ } _sifields;
+} siginfo_t;
+
+#endif
+
+#define si_pid _sifields._kill._pid
+#define si_uid _sifields._kill._uid
+#define si_tid _sifields._timer._tid
+#define si_overrun _sifields._timer._overrun
+#define si_sys_private _sifields._timer._sys_private
+#define si_status _sifields._sigchld._status
+#define si_utime _sifields._sigchld._utime
+#define si_stime _sifields._sigchld._stime
+#define si_value _sifields._rt._sigval
+#define si_int _sifields._rt._sigval.sival_int
+#define si_ptr _sifields._rt._sigval.sival_ptr
+#define si_addr _sifields._sigfault._addr
+#ifdef __ARCH_SI_TRAPNO
+#define si_trapno _sifields._sigfault._trapno
+#endif
+#define si_band _sifields._sigpoll._band
+#define si_fd _sifields._sigpoll._fd
+
+#define __SI_KILL 0
+#define __SI_TIMER 0
+#define __SI_POLL 0
+#define __SI_FAULT 0
+#define __SI_CHLD 0
+#define __SI_RT 0
+#define __SI_MESGQ 0
+#define __SI_CODE(T,N) (N)
+
+#define SI_USER 0
+#define SI_KERNEL 0x80
+#define SI_QUEUE -1
+#define SI_TIMER __SI_CODE(__SI_TIMER,-2)
+#define SI_MESGQ __SI_CODE(__SI_MESGQ,-3)
+#define SI_ASYNCIO -4
+#define SI_SIGIO -5
+#define SI_TKILL -6
+#define SI_DETHREAD -7
+
+#define SI_FROMUSER(siptr) ((siptr)->si_code <= 0)
+#define SI_FROMKERNEL(siptr) ((siptr)->si_code > 0)
+
+#define ILL_ILLOPC (__SI_FAULT|1)
+#define ILL_ILLOPN (__SI_FAULT|2)
+#define ILL_ILLADR (__SI_FAULT|3)
+#define ILL_ILLTRP (__SI_FAULT|4)
+#define ILL_PRVOPC (__SI_FAULT|5)
+#define ILL_PRVREG (__SI_FAULT|6)
+#define ILL_COPROC (__SI_FAULT|7)
+#define ILL_BADSTK (__SI_FAULT|8)
+#define NSIGILL 8
+
+#define FPE_INTDIV (__SI_FAULT|1)
+#define FPE_INTOVF (__SI_FAULT|2)
+#define FPE_FLTDIV (__SI_FAULT|3)
+#define FPE_FLTOVF (__SI_FAULT|4)
+#define FPE_FLTUND (__SI_FAULT|5)
+#define FPE_FLTRES (__SI_FAULT|6)
+#define FPE_FLTINV (__SI_FAULT|7)
+#define FPE_FLTSUB (__SI_FAULT|8)
+#define NSIGFPE 8
+
+#define SEGV_MAPERR (__SI_FAULT|1)
+#define SEGV_ACCERR (__SI_FAULT|2)
+#define NSIGSEGV 2
+
+#define BUS_ADRALN (__SI_FAULT|1)
+#define BUS_ADRERR (__SI_FAULT|2)
+#define BUS_OBJERR (__SI_FAULT|3)
+#define NSIGBUS 3
+
+#define TRAP_BRKPT (__SI_FAULT|1)
+#define TRAP_TRACE (__SI_FAULT|2)
+#define NSIGTRAP 2
+
+#define CLD_EXITED (__SI_CHLD|1)
+#define CLD_KILLED (__SI_CHLD|2)
+#define CLD_DUMPED (__SI_CHLD|3)
+#define CLD_TRAPPED (__SI_CHLD|4)
+#define CLD_STOPPED (__SI_CHLD|5)
+#define CLD_CONTINUED (__SI_CHLD|6)
+#define NSIGCHLD 6
+
+#define POLL_IN (__SI_POLL|1)
+#define POLL_OUT (__SI_POLL|2)
+#define POLL_MSG (__SI_POLL|3)
+#define POLL_ERR (__SI_POLL|4)
+#define POLL_PRI (__SI_POLL|5)
+#define POLL_HUP (__SI_POLL|6)
+#define NSIGPOLL 6
+
+#define SIGEV_SIGNAL 0
+#define SIGEV_NONE 1
+#define SIGEV_THREAD 2
+#define SIGEV_THREAD_ID 4
+
+#ifndef __ARCH_SIGEV_PREAMBLE_SIZE
+#define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(int) * 2 + sizeof(sigval_t))
+#endif
+
+#define SIGEV_MAX_SIZE 64
+#define SIGEV_PAD_SIZE ((SIGEV_MAX_SIZE - __ARCH_SIGEV_PREAMBLE_SIZE) / sizeof(int))
+
+typedef struct sigevent {
+ sigval_t sigev_value;
+ int sigev_signo;
+ int sigev_notify;
+ union {
+ int _pad[SIGEV_PAD_SIZE];
+ int _tid;
+
+ struct {
+ void (*_function)(sigval_t);
+ void *_attribute;
+ } _sigev_thread;
+ } _sigev_un;
+} sigevent_t;
+
+#define sigev_notify_function _sigev_un._sigev_thread._function
+#define sigev_notify_attributes _sigev_un._sigev_thread._attribute
+#define sigev_notify_thread_id _sigev_un._tid
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/signal.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/signal.h
new file mode 100644
index 000000000..226d99c46
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/signal.h
@@ -0,0 +1,39 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __ASM_GENERIC_SIGNAL_H
+#define __ASM_GENERIC_SIGNAL_H
+
+#include
+
+#ifndef SIG_BLOCK
+#define SIG_BLOCK 0
+#endif
+#ifndef SIG_UNBLOCK
+#define SIG_UNBLOCK 1
+#endif
+#ifndef SIG_SETMASK
+#define SIG_SETMASK 2
+#endif
+
+#ifndef __ASSEMBLY__
+typedef void __signalfn_t(int);
+typedef __signalfn_t __user *__sighandler_t;
+
+typedef void __restorefn_t(void);
+typedef __restorefn_t __user *__sigrestore_t;
+
+#define SIG_DFL ((__force __sighandler_t)0)
+#define SIG_IGN ((__force __sighandler_t)1)
+#define SIG_ERR ((__force __sighandler_t)-1)
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/tlb.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/tlb.h
new file mode 100644
index 000000000..dc1e79f80
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/tlb.h
@@ -0,0 +1,37 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC__TLB_H
+#define _ASM_GENERIC__TLB_H
+
+#include
+#include
+#include
+
+#define FREE_PTE_NR 1
+#define tlb_fast_mode(tlb) 1
+
+struct mmu_gather {
+ struct mm_struct *mm;
+ unsigned int nr;
+ unsigned int need_flush;
+ unsigned int fullmm;
+ struct page * pages[FREE_PTE_NR];
+};
+
+#define tlb_remove_tlb_entry(tlb, ptep, address) do { tlb->need_flush = 1; __tlb_remove_tlb_entry(tlb, ptep, address); } while (0)
+#define pte_free_tlb(tlb, ptep) do { tlb->need_flush = 1; __pte_free_tlb(tlb, ptep); } while (0)
+#ifndef __ARCH_HAS_4LEVEL_HACK
+#define pud_free_tlb(tlb, pudp) do { tlb->need_flush = 1; __pud_free_tlb(tlb, pudp); } while (0)
+#endif
+#define pmd_free_tlb(tlb, pmdp) do { tlb->need_flush = 1; __pmd_free_tlb(tlb, pmdp); } while (0)
+#define tlb_migrate_finish(mm) do {} while (0)
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/topology.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/topology.h
new file mode 100644
index 000000000..089b1f28e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/topology.h
@@ -0,0 +1,35 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ASM_GENERIC_TOPOLOGY_H
+#define _ASM_GENERIC_TOPOLOGY_H
+
+#ifndef cpu_to_node
+#define cpu_to_node(cpu) (0)
+#endif
+#ifndef parent_node
+#define parent_node(node) (0)
+#endif
+#ifndef node_to_cpumask
+#define node_to_cpumask(node) (cpu_online_map)
+#endif
+#ifndef node_to_first_cpu
+#define node_to_first_cpu(node) (0)
+#endif
+#ifndef pcibus_to_node
+#define pcibus_to_node(node) (-1)
+#endif
+
+#ifndef pcibus_to_cpumask
+#define pcibus_to_cpumask(bus) (pcibus_to_node(bus) == -1 ? CPU_MASK_ALL : node_to_cpumask(pcibus_to_node(bus)) )
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/asm-generic/xor.h b/ndk/build/platforms/android-1.5/common/include/asm-generic/xor.h
new file mode 100644
index 000000000..6b1e4e8d7
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/asm-generic/xor.h
@@ -0,0 +1,14 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#include
+
+#define XOR_TRY_TEMPLATES do { xor_speed(&xor_block_8regs); xor_speed(&xor_block_8regs_p); xor_speed(&xor_block_32regs); xor_speed(&xor_block_32regs_p); } while (0)
diff --git a/ndk/build/platforms/android-1.5/common/include/assert.h b/ndk/build/platforms/android-1.5/common/include/assert.h
new file mode 100644
index 000000000..62470f5f0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/assert.h
@@ -0,0 +1,65 @@
+/* $OpenBSD: assert.h,v 1.12 2006/01/31 10:53:51 hshoexer Exp $ */
+/* $NetBSD: assert.h,v 1.6 1994/10/26 00:55:44 cgd Exp $ */
+
+/*-
+ * Copyright (c) 1992, 1993
+ * The Regents of the University of California. All rights reserved.
+ * (c) UNIX System Laboratories, Inc.
+ * All or some portions of this file are derived from material licensed
+ * to the University of California by American Telephone and Telegraph
+ * Co. or Unix System Laboratories, Inc. and are reproduced herein with
+ * the permission of UNIX System Laboratories, Inc.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)assert.h 8.2 (Berkeley) 1/21/94
+ */
+
+/*
+ * Unlike other ANSI header files, may usefully be included
+ * multiple times, with and without NDEBUG defined.
+ */
+
+#include
+
+#undef assert
+#undef _assert
+
+#ifdef NDEBUG
+# define assert(e) ((void)0)
+# define _assert(e) ((void)0)
+#else
+# define _assert(e) assert(e)
+# if __ISO_C_VISIBLE >= 1999
+# define assert(e) ((e) ? (void)0 : __assert2(__FILE__, __LINE__, __func__, #e))
+# else
+# define assert(e) ((e) ? (void)0 : __assert(__FILE__, __LINE__, #e))
+# endif
+#endif
+
+__BEGIN_DECLS
+__dead void __assert(const char *, int, const char *);
+__dead void __assert2(const char *, int, const char *, const char *);
+__END_DECLS
diff --git a/ndk/build/platforms/android-1.5/common/include/byteswap.h b/ndk/build/platforms/android-1.5/common/include/byteswap.h
new file mode 100644
index 000000000..16d2ad4f9
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/byteswap.h
@@ -0,0 +1,37 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _BYTESWAP_H_
+#define _BYTESWAP_H_
+
+#include
+
+#define bswap_16(x) swap16(x)
+#define bswap_32(x) swap32(x)
+#define bswap_64(x) swap64(x)
+
+#endif /* _BYTESWAP_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/cstddef b/ndk/build/platforms/android-1.5/common/include/cstddef
new file mode 100644
index 000000000..e69de29bb
diff --git a/ndk/build/platforms/android-1.5/common/include/ctype.h b/ndk/build/platforms/android-1.5/common/include/ctype.h
new file mode 100644
index 000000000..b5f9ff4f8
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/ctype.h
@@ -0,0 +1,203 @@
+/* $OpenBSD: ctype.h,v 1.19 2005/12/13 00:35:22 millert Exp $ */
+/* $NetBSD: ctype.h,v 1.14 1994/10/26 00:55:47 cgd Exp $ */
+
+/*
+ * Copyright (c) 1989 The Regents of the University of California.
+ * All rights reserved.
+ * (c) UNIX System Laboratories, Inc.
+ * All or some portions of this file are derived from material licensed
+ * to the University of California by American Telephone and Telegraph
+ * Co. or Unix System Laboratories, Inc. and are reproduced herein with
+ * the permission of UNIX System Laboratories, Inc.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)ctype.h 5.3 (Berkeley) 4/3/91
+ */
+
+#ifndef _CTYPE_H_
+#define _CTYPE_H_
+
+#include
+
+#define _U 0x01
+#define _L 0x02
+#define _N 0x04
+#define _S 0x08
+#define _P 0x10
+#define _C 0x20
+#define _X 0x40
+#define _B 0x80
+
+__BEGIN_DECLS
+
+extern const char *_ctype_;
+extern const short *_tolower_tab_;
+extern const short *_toupper_tab_;
+
+/* extern __inline is a GNU C extension */
+#ifdef __GNUC__
+#define __CTYPE_INLINE extern __inline
+#else
+#define __CTYPE_INLINE static __inline
+#endif
+
+#if defined(__GNUC__) || defined(_ANSI_LIBRARY) || defined(lint)
+int isalnum(int);
+int isalpha(int);
+int iscntrl(int);
+int isdigit(int);
+int isgraph(int);
+int islower(int);
+int isprint(int);
+int ispunct(int);
+int isspace(int);
+int isupper(int);
+int isxdigit(int);
+int tolower(int);
+int toupper(int);
+
+#if __BSD_VISIBLE || __ISO_C_VISIBLE >= 1999 || __POSIX_VISIBLE > 200112 \
+ || __XPG_VISIBLE > 600
+int isblank(int);
+#endif
+
+#if __BSD_VISIBLE || __XPG_VISIBLE
+int isascii(int);
+int toascii(int);
+int _tolower(int);
+int _toupper(int);
+#endif /* __BSD_VISIBLE || __XPG_VISIBLE */
+
+#endif /* __GNUC__ || _ANSI_LIBRARY || lint */
+
+#if defined(NDEBUG)
+
+__CTYPE_INLINE int isalnum(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & (_U|_L|_N)));
+}
+
+__CTYPE_INLINE int isalpha(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & (_U|_L)));
+}
+
+__CTYPE_INLINE int iscntrl(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _C));
+}
+
+__CTYPE_INLINE int isdigit(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _N));
+}
+
+__CTYPE_INLINE int isgraph(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & (_P|_U|_L|_N)));
+}
+
+__CTYPE_INLINE int islower(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _L));
+}
+
+__CTYPE_INLINE int isprint(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & (_P|_U|_L|_N|_B)));
+}
+
+__CTYPE_INLINE int ispunct(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _P));
+}
+
+__CTYPE_INLINE int isspace(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _S));
+}
+
+__CTYPE_INLINE int isupper(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & _U));
+}
+
+__CTYPE_INLINE int isxdigit(int c)
+{
+ return (c == -1 ? 0 : ((_ctype_ + 1)[(unsigned char)c] & (_N|_X)));
+}
+
+__CTYPE_INLINE int tolower(int c)
+{
+ if ((unsigned int)c > 255)
+ return (c);
+ return ((_tolower_tab_ + 1)[c]);
+}
+
+__CTYPE_INLINE int toupper(int c)
+{
+ if ((unsigned int)c > 255)
+ return (c);
+ return ((_toupper_tab_ + 1)[c]);
+}
+
+#if __BSD_VISIBLE || __ISO_C_VISIBLE >= 1999 || __POSIX_VISIBLE > 200112 \
+ || __XPG_VISIBLE > 600
+__CTYPE_INLINE int isblank(int c)
+{
+ return (c == ' ' || c == '\t');
+}
+#endif
+
+#if __BSD_VISIBLE || __XPG_VISIBLE
+__CTYPE_INLINE int isascii(int c)
+{
+ return ((unsigned int)c <= 0177);
+}
+
+__CTYPE_INLINE int toascii(int c)
+{
+ return (c & 0177);
+}
+
+__CTYPE_INLINE int _tolower(int c)
+{
+ return (c - 'A' + 'a');
+}
+
+__CTYPE_INLINE int _toupper(int c)
+{
+ return (c - 'a' + 'A');
+}
+#endif /* __BSD_VISIBLE || __XPG_VISIBLE */
+
+#endif /* NDEBUG */
+
+__END_DECLS
+
+#undef __CTYPE_INLINE
+
+#endif /* !_CTYPE_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/dirent.h b/ndk/build/platforms/android-1.5/common/include/dirent.h
new file mode 100644
index 000000000..55eef7b52
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/dirent.h
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _DIRENT_H_
+#define _DIRENT_H_
+
+#include
+#include
+
+__BEGIN_DECLS
+
+#ifndef DT_UNKNOWN
+#define DT_UNKNOWN 0
+#define DT_FIFO 1
+#define DT_CHR 2
+#define DT_DIR 4
+#define DT_BLK 6
+#define DT_REG 8
+#define DT_LNK 10
+#define DT_SOCK 12
+#define DT_WHT 14
+#endif
+
+/* the following structure is really called dirent64 by the kernel
+ * headers. They also define a struct dirent, but the latter lack
+ * the d_type field which is required by some libraries (e.g. hotplug)
+ * who assume to be able to access it directly. sad...
+ */
+struct dirent {
+ uint64_t d_ino;
+ int64_t d_off;
+ unsigned short d_reclen;
+ unsigned char d_type;
+ char d_name[256];
+};
+
+typedef struct DIR DIR;
+
+extern int getdents(unsigned int, struct dirent*, unsigned int);
+extern DIR* opendir(const char* dirpath);
+extern DIR* fdopendir(int fd);
+extern struct dirent* readdir(DIR* dirp);
+extern int readdir_r(DIR* dirp, struct dirent *entry, struct dirent **result);
+extern int closedir(DIR* dirp);
+extern void rewinddir(DIR *dirp);
+extern int dirfd(DIR* dirp);
+extern int alphasort(const void *a, const void *b);
+extern int scandir(const char *dir, struct dirent ***namelist,
+ int(*filter)(const struct dirent *),
+ int(*compar)(const struct dirent **,
+ const struct dirent **));
+
+__END_DECLS
+
+#endif /* _DIRENT_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/dlfcn.h b/ndk/build/platforms/android-1.5/common/include/dlfcn.h
new file mode 100644
index 000000000..958279687
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/dlfcn.h
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef __DLFCN_H__
+#define __DLFCN_H__
+
+#include
+
+__BEGIN_DECLS
+
+extern void* dlopen(const char* filename, int flag);
+extern int dlclose(void* handle);
+extern const char* dlerror(void);
+extern void* dlsym(void* handle, const char* symbol);
+
+enum {
+ RTLD_NOW = 0,
+ RTLD_LAZY = 1,
+
+ RTLD_LOCAL = 0,
+ RTLD_GLOBAL = 2,
+};
+
+#define RTLD_DEFAULT ((void*) 0xffffffff)
+#define RTLD_NEXT ((void*) 0xfffffffe)
+
+__END_DECLS
+
+#endif /* __DLFCN_H */
+
+
diff --git a/ndk/build/platforms/android-1.5/common/include/elf.h b/ndk/build/platforms/android-1.5/common/include/elf.h
new file mode 100644
index 000000000..8a86a6390
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/elf.h
@@ -0,0 +1,58 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ELF_H
+#define _ELF_H
+
+/* these definitions are missing from the BSD sources */
+enum {
+ AT_NULL = 0,
+ AT_IGNORE,
+ AT_EXECFD,
+ AT_PHDR,
+ AT_PHENT,
+ AT_PHNUM,
+ AT_PAGESZ,
+ AT_BASE,
+ AT_FLAGS,
+ AT_ENTRY,
+ AT_NOTELF,
+ AT_UID,
+ AT_EUID,
+ AT_GID,
+ AT_EGID,
+ AT_PLATFORM,
+ AT_HWCAP,
+ AT_CLKTCK,
+
+ AT_SECURE = 23
+};
+
+#include
+
+#endif /* _ELF_H */
+
diff --git a/ndk/build/platforms/android-1.5/common/include/endian.h b/ndk/build/platforms/android-1.5/common/include/endian.h
new file mode 100644
index 000000000..475b48cf6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/endian.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ENDIAN_H_
+#define _ENDIAN_H_
+
+#include
+
+#endif /* _ENDIAN_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/err.h b/ndk/build/platforms/android-1.5/common/include/err.h
new file mode 100644
index 000000000..e69de29bb
diff --git a/ndk/build/platforms/android-1.5/common/include/errno.h b/ndk/build/platforms/android-1.5/common/include/errno.h
new file mode 100644
index 000000000..2b2685af4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/errno.h
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _ERRNO_H
+#define _ERRNO_H
+
+#include
+#include
+
+__BEGIN_DECLS
+
+/* on Linux, ENOTSUP and EOPNOTSUPP are defined as the same error code
+ * even if 1000.3 states that they should be different
+ */
+#ifndef ENOTUP
+#define ENOTSUP EOPNOTSUPP
+#endif
+
+/* internal function that should *only* be called from system calls */
+/* use errno = xxxx instead in C code */
+extern int __set_errno(int error);
+
+/* internal function returning the address of the thread-specific errno */
+extern volatile int* __errno(void);
+
+/* a macro expanding to the errno l-value */
+#define errno (*__errno())
+
+__END_DECLS
+
+#endif /* _ERRNO_H */
diff --git a/ndk/build/platforms/android-1.5/common/include/fcntl.h b/ndk/build/platforms/android-1.5/common/include/fcntl.h
new file mode 100644
index 000000000..59e7135cd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/fcntl.h
@@ -0,0 +1,50 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _FCNTL_H
+#define _FCNTL_H
+
+#include
+#include
+#include
+#include /* this is not required, but makes client code much happier */
+
+__BEGIN_DECLS
+
+#ifndef O_ASYNC
+#define O_ASYNC FASYNC
+#endif
+
+extern int open(const char* path, int mode, ...);
+extern int openat(int fd, const char* path, int mode, ...);
+extern int unlinkat(int dirfd, const char *pathname, int flags);
+extern int fcntl(int fd, int command, ...);
+extern int creat(const char* path, mode_t mode);
+
+__END_DECLS
+
+#endif /* _FCNTL_H */
diff --git a/ndk/build/platforms/android-1.5/common/include/features.h b/ndk/build/platforms/android-1.5/common/include/features.h
new file mode 100644
index 000000000..343c84d2b
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/features.h
@@ -0,0 +1,58 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _FEATURES_H_
+#define _FEATURES_H_
+
+/* certain Linux-specific programs expect a header file
+ * that defines various features macros
+ */
+
+/* we do include a number of BSD extensions */
+#define _BSD_SOURCE 1
+
+/* we do include a number of GNU extensions */
+#define _GNU_SOURCE 1
+
+/* C95 support */
+#undef __USE_ISOC95
+#if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199409L
+# define __USE_ISOC95 1
+#endif
+
+/* C99 support */
+#undef __USE_ISOC99
+#if defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L
+# define __USE_ISOC99 1
+#endif
+
+/* Posix support */
+#define __USE_POSIX 1
+#define __USE_POSIX2 1
+#define __USE_XPG 1
+
+#endif /* _FEATURES_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/fnmatch.h b/ndk/build/platforms/android-1.5/common/include/fnmatch.h
new file mode 100644
index 000000000..772b4efa1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/fnmatch.h
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _FNMATCH_H
+#define _FNMATCH_H
+
+#include
+
+__BEGIN_DECLS
+
+#define FNM_NOMATCH 1 /* Match failed. */
+#define FNM_NOSYS 2 /* Function not supported (unused). */
+
+#define FNM_NOESCAPE 0x01 /* Disable backslash escaping. */
+#define FNM_PATHNAME 0x02 /* Slash must be matched by slash. */
+#define FNM_PERIOD 0x04 /* Period must be matched by period. */
+#define FNM_LEADING_DIR 0x08 /* Ignore / after Imatch. */
+#define FNM_CASEFOLD 0x10 /* Case insensitive search. */
+
+#define FNM_IGNORECASE FNM_CASEFOLD
+#define FNM_FILE_NAME FNM_PATHNAME
+
+extern int fnmatch(const char *pattern, const char *string, int flags);
+
+__END_DECLS
+
+#endif /* _FNMATCH_H */
+
diff --git a/ndk/build/platforms/android-1.5/common/include/getopt.h b/ndk/build/platforms/android-1.5/common/include/getopt.h
new file mode 100644
index 000000000..6b4954b50
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/getopt.h
@@ -0,0 +1,85 @@
+/* $OpenBSD: getopt.h,v 1.1 2002/12/03 20:24:29 millert Exp $ */
+/* $NetBSD: getopt.h,v 1.4 2000/07/07 10:43:54 ad Exp $ */
+
+/*-
+ * Copyright (c) 2000 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * This code is derived from software contributed to The NetBSD Foundation
+ * by Dieter Baron and Thomas Klausner.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * This product includes software developed by the NetBSD
+ * Foundation, Inc. and its contributors.
+ * 4. Neither the name of The NetBSD Foundation nor the names of its
+ * contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef _GETOPT_H_
+#define _GETOPT_H_
+
+#include
+
+/*
+ * GNU-like getopt_long() and 4.4BSD getsubopt()/optreset extensions
+ */
+#define no_argument 0
+#define required_argument 1
+#define optional_argument 2
+
+struct option {
+ /* name of long option */
+ const char *name;
+ /*
+ * one of no_argument, required_argument, and optional_argument:
+ * whether option takes an argument
+ */
+ int has_arg;
+ /* if not NULL, set *flag to val when option found */
+ int *flag;
+ /* if flag not NULL, value to set *flag to; else return value */
+ int val;
+};
+
+__BEGIN_DECLS
+int getopt_long(int, char * const *, const char *,
+ const struct option *, int *);
+int getopt_long_only(int, char * const *, const char *,
+ const struct option *, int *);
+#ifndef _GETOPT_DEFINED_
+#define _GETOPT_DEFINED_
+int getopt(int, char * const *, const char *);
+int getsubopt(char **, char * const *, char **);
+
+extern char *optarg; /* getopt(3) external variables */
+extern int opterr;
+extern int optind;
+extern int optopt;
+extern int optreset;
+extern char *suboptarg; /* getsubopt(3) external variable */
+#endif
+__END_DECLS
+
+#endif /* !_GETOPT_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/grp.h b/ndk/build/platforms/android-1.5/common/include/grp.h
new file mode 100644
index 000000000..86d99f357
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/grp.h
@@ -0,0 +1,82 @@
+/* $OpenBSD: grp.h,v 1.8 2005/12/13 00:35:22 millert Exp $ */
+/* $NetBSD: grp.h,v 1.7 1995/04/29 05:30:40 cgd Exp $ */
+
+/*-
+ * Copyright (c) 1989, 1993
+ * The Regents of the University of California. All rights reserved.
+ * (c) UNIX System Laboratories, Inc.
+ * All or some portions of this file are derived from material licensed
+ * to the University of California by American Telephone and Telegraph
+ * Co. or Unix System Laboratories, Inc. and are reproduced herein with
+ * the permission of UNIX System Laboratories, Inc.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)grp.h 8.2 (Berkeley) 1/21/94
+ */
+
+#ifndef _GRP_H_
+#define _GRP_H_
+
+#include
+#include
+
+#if __BSD_VISIBLE
+#define _PATH_GROUP "/etc/group"
+#endif
+
+struct group {
+ char *gr_name; /* group name */
+ char *gr_passwd; /* group password */
+ gid_t gr_gid; /* group id */
+ char **gr_mem; /* group members */
+};
+
+__BEGIN_DECLS
+struct group *getgrgid(gid_t);
+struct group *getgrnam(const char *);
+#if __BSD_VISIBLE || __POSIX_VISIBLE >= 200112 || __XPG_VISIBLE
+struct group *getgrent(void);
+void setgrent(void);
+void endgrent(void);
+int getgrgid_r(gid_t, struct group *, char *,
+ size_t, struct group **);
+int getgrnam_r(const char *, struct group *, char *,
+ size_t, struct group **);
+#endif
+#if __BSD_VISIBLE
+void setgrfile(const char *);
+int setgroupent(int);
+char *group_from_gid(gid_t, int);
+#endif
+
+int getgrouplist (const char *user, gid_t group,
+ gid_t *groups, int *ngroups);
+
+int initgroups (const char *user, gid_t group);
+
+__END_DECLS
+
+#endif /* !_GRP_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/inttypes.h b/ndk/build/platforms/android-1.5/common/include/inttypes.h
new file mode 100644
index 000000000..ca303cbc4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/inttypes.h
@@ -0,0 +1,258 @@
+/* $OpenBSD: inttypes.h,v 1.9 2006/01/15 00:47:51 millert Exp $ */
+
+/*
+ * Copyright (c) 1997, 2005 Todd C. Miller
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+#ifndef _INTTYPES_H_
+#define _INTTYPES_H_
+
+#include
+#include
+
+#if !defined(__cplusplus) || defined(__STDC_FORMAT_MACROS)
+/*
+ * 7.8.1 Macros for format specifiers
+ *
+ * Each of the following object-like macros expands to a string
+ * literal containing a conversion specifier, possibly modified by
+ * a prefix such as hh, h, l, or ll, suitable for use within the
+ * format argument of a formatted input/output function when
+ * converting the corresponding integer type. These macro names
+ * have the general form of PRI (character string literals for the
+ * fprintf family) or SCN (character string literals for the fscanf
+ * family), followed by the conversion specifier, followed by a
+ * name corresponding to a similar typedef name. For example,
+ * PRIdFAST32 can be used in a format string to print the value of
+ * an integer of type int_fast32_t.
+ */
+
+/* fprintf macros for signed integers */
+#define PRId8 "d" /* int8_t */
+#define PRId16 "d" /* int16_t */
+#define PRId32 "d" /* int32_t */
+#define PRId64 "lld" /* int64_t */
+
+#define PRIdLEAST8 "d" /* int_least8_t */
+#define PRIdLEAST16 "d" /* int_least16_t */
+#define PRIdLEAST32 "d" /* int_least32_t */
+#define PRIdLEAST64 "lld" /* int_least64_t */
+
+#define PRIdFAST8 "d" /* int_fast8_t */
+#define PRIdFAST16 "d" /* int_fast16_t */
+#define PRIdFAST32 "d" /* int_fast32_t */
+#define PRIdFAST64 "lld" /* int_fast64_t */
+
+#define PRIdMAX "jd" /* intmax_t */
+#define PRIdPTR "ld" /* intptr_t */
+
+#define PRIi8 "i" /* int8_t */
+#define PRIi16 "i" /* int16_t */
+#define PRIi32 "i" /* int32_t */
+#define PRIi64 "lli" /* int64_t */
+
+#define PRIiLEAST8 "i" /* int_least8_t */
+#define PRIiLEAST16 "i" /* int_least16_t */
+#define PRIiLEAST32 "i" /* int_least32_t */
+#define PRIiLEAST64 "lli" /* int_least64_t */
+
+#define PRIiFAST8 "i" /* int_fast8_t */
+#define PRIiFAST16 "i" /* int_fast16_t */
+#define PRIiFAST32 "i" /* int_fast32_t */
+#define PRIiFAST64 "lli" /* int_fast64_t */
+
+#define PRIiMAX "ji" /* intmax_t */
+#define PRIiPTR "li" /* intptr_t */
+
+/* fprintf macros for unsigned integers */
+#define PRIo8 "o" /* int8_t */
+#define PRIo16 "o" /* int16_t */
+#define PRIo32 "o" /* int32_t */
+#define PRIo64 "llo" /* int64_t */
+
+#define PRIoLEAST8 "o" /* int_least8_t */
+#define PRIoLEAST16 "o" /* int_least16_t */
+#define PRIoLEAST32 "o" /* int_least32_t */
+#define PRIoLEAST64 "llo" /* int_least64_t */
+
+#define PRIoFAST8 "o" /* int_fast8_t */
+#define PRIoFAST16 "o" /* int_fast16_t */
+#define PRIoFAST32 "o" /* int_fast32_t */
+#define PRIoFAST64 "llo" /* int_fast64_t */
+
+#define PRIoMAX "jo" /* intmax_t */
+#define PRIoPTR "lo" /* intptr_t */
+
+#define PRIu8 "u" /* uint8_t */
+#define PRIu16 "u" /* uint16_t */
+#define PRIu32 "u" /* uint32_t */
+#define PRIu64 "llu" /* uint64_t */
+
+#define PRIuLEAST8 "u" /* uint_least8_t */
+#define PRIuLEAST16 "u" /* uint_least16_t */
+#define PRIuLEAST32 "u" /* uint_least32_t */
+#define PRIuLEAST64 "llu" /* uint_least64_t */
+
+#define PRIuFAST8 "u" /* uint_fast8_t */
+#define PRIuFAST16 "u" /* uint_fast16_t */
+#define PRIuFAST32 "u" /* uint_fast32_t */
+#define PRIuFAST64 "llu" /* uint_fast64_t */
+
+#define PRIuMAX "ju" /* uintmax_t */
+#define PRIuPTR "lu" /* uintptr_t */
+
+#define PRIx8 "x" /* uint8_t */
+#define PRIx16 "x" /* uint16_t */
+#define PRIx32 "x" /* uint32_t */
+#define PRIx64 "llx" /* uint64_t */
+
+#define PRIxLEAST8 "x" /* uint_least8_t */
+#define PRIxLEAST16 "x" /* uint_least16_t */
+#define PRIxLEAST32 "x" /* uint_least32_t */
+#define PRIxLEAST64 "llx" /* uint_least64_t */
+
+#define PRIxFAST8 "x" /* uint_fast8_t */
+#define PRIxFAST16 "x" /* uint_fast16_t */
+#define PRIxFAST32 "x" /* uint_fast32_t */
+#define PRIxFAST64 "llx" /* uint_fast64_t */
+
+#define PRIxMAX "jx" /* uintmax_t */
+#define PRIxPTR "lx" /* uintptr_t */
+
+#define PRIX8 "X" /* uint8_t */
+#define PRIX16 "X" /* uint16_t */
+#define PRIX32 "X" /* uint32_t */
+#define PRIX64 "llX" /* uint64_t */
+
+#define PRIXLEAST8 "X" /* uint_least8_t */
+#define PRIXLEAST16 "X" /* uint_least16_t */
+#define PRIXLEAST32 "X" /* uint_least32_t */
+#define PRIXLEAST64 "llX" /* uint_least64_t */
+
+#define PRIXFAST8 "X" /* uint_fast8_t */
+#define PRIXFAST16 "X" /* uint_fast16_t */
+#define PRIXFAST32 "X" /* uint_fast32_t */
+#define PRIXFAST64 "llX" /* uint_fast64_t */
+
+#define PRIXMAX "jX" /* uintmax_t */
+#define PRIXPTR "lX" /* uintptr_t */
+
+/* fscanf macros for signed integers */
+#define SCNd8 "hhd" /* int8_t */
+#define SCNd16 "hd" /* int16_t */
+#define SCNd32 "d" /* int32_t */
+#define SCNd64 "lld" /* int64_t */
+
+#define SCNdLEAST8 "hhd" /* int_least8_t */
+#define SCNdLEAST16 "hd" /* int_least16_t */
+#define SCNdLEAST32 "d" /* int_least32_t */
+#define SCNdLEAST64 "lld" /* int_least64_t */
+
+#define SCNdFAST8 "hhd" /* int_fast8_t */
+#define SCNdFAST16 "hd" /* int_fast16_t */
+#define SCNdFAST32 "d" /* int_fast32_t */
+#define SCNdFAST64 "lld" /* int_fast64_t */
+
+#define SCNdMAX "jd" /* intmax_t */
+#define SCNdPTR "ld" /* intptr_t */
+
+#define SCNi8 "hhi" /* int8_t */
+#define SCNi16 "hi" /* int16_t */
+#define SCNi32 "i" /* int32_t */
+#define SCNi64 "lli" /* int64_t */
+
+#define SCNiLEAST8 "hhi" /* int_least8_t */
+#define SCNiLEAST16 "hi" /* int_least16_t */
+#define SCNiLEAST32 "i" /* int_least32_t */
+#define SCNiLEAST64 "lli" /* int_least64_t */
+
+#define SCNiFAST8 "hhi" /* int_fast8_t */
+#define SCNiFAST16 "hi" /* int_fast16_t */
+#define SCNiFAST32 "i" /* int_fast32_t */
+#define SCNiFAST64 "lli" /* int_fast64_t */
+
+#define SCNiMAX "ji" /* intmax_t */
+#define SCNiPTR "li" /* intptr_t */
+
+/* fscanf macros for unsigned integers */
+#define SCNo8 "hho" /* uint8_t */
+#define SCNo16 "ho" /* uint16_t */
+#define SCNo32 "o" /* uint32_t */
+#define SCNo64 "llo" /* uint64_t */
+
+#define SCNoLEAST8 "hho" /* uint_least8_t */
+#define SCNoLEAST16 "ho" /* uint_least16_t */
+#define SCNoLEAST32 "o" /* uint_least32_t */
+#define SCNoLEAST64 "llo" /* uint_least64_t */
+
+#define SCNoFAST8 "hho" /* uint_fast8_t */
+#define SCNoFAST16 "ho" /* uint_fast16_t */
+#define SCNoFAST32 "o" /* uint_fast32_t */
+#define SCNoFAST64 "llo" /* uint_fast64_t */
+
+#define SCNoMAX "jo" /* uintmax_t */
+#define SCNoPTR "lo" /* uintptr_t */
+
+#define SCNu8 "hhu" /* uint8_t */
+#define SCNu16 "hu" /* uint16_t */
+#define SCNu32 "u" /* uint32_t */
+#define SCNu64 "llu" /* uint64_t */
+
+#define SCNuLEAST8 "hhu" /* uint_least8_t */
+#define SCNuLEAST16 "hu" /* uint_least16_t */
+#define SCNuLEAST32 "u" /* uint_least32_t */
+#define SCNuLEAST64 "llu" /* uint_least64_t */
+
+#define SCNuFAST8 "hhu" /* uint_fast8_t */
+#define SCNuFAST16 "hu" /* uint_fast16_t */
+#define SCNuFAST32 "u" /* uint_fast32_t */
+#define SCNuFAST64 "llu" /* uint_fast64_t */
+
+#define SCNuMAX "ju" /* uintmax_t */
+#define SCNuPTR "lu" /* uintptr_t */
+
+#define SCNx8 "hhx" /* uint8_t */
+#define SCNx16 "hx" /* uint16_t */
+#define SCNx32 "x" /* uint32_t */
+#define SCNx64 "llx" /* uint64_t */
+
+#define SCNxLEAST8 "hhx" /* uint_least8_t */
+#define SCNxLEAST16 "hx" /* uint_least16_t */
+#define SCNxLEAST32 "x" /* uint_least32_t */
+#define SCNxLEAST64 "llx" /* uint_least64_t */
+
+#define SCNxFAST8 "hhx" /* uint_fast8_t */
+#define SCNxFAST16 "hx" /* uint_fast16_t */
+#define SCNxFAST32 "x" /* uint_fast32_t */
+#define SCNxFAST64 "llx" /* uint_fast64_t */
+
+#define SCNxMAX "jx" /* uintmax_t */
+#define SCNxPTR "lx" /* uintptr_t */
+
+#endif /* __cplusplus || __STDC_FORMAT_MACROS */
+
+typedef struct {
+ intmax_t quot; /* quotient */
+ intmax_t rem; /* remainder */
+} imaxdiv_t;
+
+__BEGIN_DECLS
+intmax_t imaxabs(intmax_t);
+imaxdiv_t imaxdiv(intmax_t, intmax_t);
+intmax_t strtoimax(const char *, char **, int);
+uintmax_t strtoumax(const char *, char **, int);
+__END_DECLS
+
+#endif /* _INTTYPES_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/jni.h b/ndk/build/platforms/android-1.5/common/include/jni.h
new file mode 100644
index 000000000..ad954c8f6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/jni.h
@@ -0,0 +1,1140 @@
+/*
+ * Copyright 2006 The Android Open Source Project
+ *
+ * JNI specification, as defined by Sun:
+ * http://java.sun.com/javase/6/docs/technotes/guides/jni/spec/jniTOC.html
+ *
+ * Everything here is expected to be VM-neutral.
+ */
+#ifndef _JNI_H
+#define _JNI_H
+
+#include
+
+/*
+ * Primitive types that match up with Java equivalents.
+ */
+#ifdef HAVE_INTTYPES_H
+# include /* C99 */
+typedef uint8_t jboolean; /* unsigned 8 bits */
+typedef int8_t jbyte; /* signed 8 bits */
+typedef uint16_t jchar; /* unsigned 16 bits */
+typedef int16_t jshort; /* signed 16 bits */
+typedef int32_t jint; /* signed 32 bits */
+typedef int64_t jlong; /* signed 64 bits */
+typedef float jfloat; /* 32-bit IEEE 754 */
+typedef double jdouble; /* 64-bit IEEE 754 */
+#else
+typedef unsigned char jboolean; /* unsigned 8 bits */
+typedef signed char jbyte; /* signed 8 bits */
+typedef unsigned short jchar; /* unsigned 16 bits */
+typedef short jshort; /* signed 16 bits */
+typedef int jint; /* signed 32 bits */
+typedef long long jlong; /* signed 64 bits */
+typedef float jfloat; /* 32-bit IEEE 754 */
+typedef double jdouble; /* 64-bit IEEE 754 */
+#endif
+
+/* "cardinal indices and sizes" */
+typedef jint jsize;
+
+#ifdef __cplusplus
+/*
+ * Reference types, in C++
+ */
+class _jobject {};
+class _jclass : public _jobject {};
+class _jstring : public _jobject {};
+class _jarray : public _jobject {};
+class _jobjectArray : public _jarray {};
+class _jbooleanArray : public _jarray {};
+class _jbyteArray : public _jarray {};
+class _jcharArray : public _jarray {};
+class _jshortArray : public _jarray {};
+class _jintArray : public _jarray {};
+class _jlongArray : public _jarray {};
+class _jfloatArray : public _jarray {};
+class _jdoubleArray : public _jarray {};
+class _jthrowable : public _jobject {};
+
+typedef _jobject* jobject;
+typedef _jclass* jclass;
+typedef _jstring* jstring;
+typedef _jarray* jarray;
+typedef _jobjectArray* jobjectArray;
+typedef _jbooleanArray* jbooleanArray;
+typedef _jbyteArray* jbyteArray;
+typedef _jcharArray* jcharArray;
+typedef _jshortArray* jshortArray;
+typedef _jintArray* jintArray;
+typedef _jlongArray* jlongArray;
+typedef _jfloatArray* jfloatArray;
+typedef _jdoubleArray* jdoubleArray;
+typedef _jthrowable* jthrowable;
+typedef _jobject* jweak;
+
+
+#else /* not __cplusplus */
+
+/*
+ * Reference types, in C.
+ */
+typedef void* jobject;
+typedef jobject jclass;
+typedef jobject jstring;
+typedef jobject jarray;
+typedef jarray jobjectArray;
+typedef jarray jbooleanArray;
+typedef jarray jbyteArray;
+typedef jarray jcharArray;
+typedef jarray jshortArray;
+typedef jarray jintArray;
+typedef jarray jlongArray;
+typedef jarray jfloatArray;
+typedef jarray jdoubleArray;
+typedef jobject jthrowable;
+typedef jobject jweak;
+
+#endif /* not __cplusplus */
+
+struct _jfieldID; /* opaque structure */
+typedef struct _jfieldID* jfieldID; /* field IDs */
+
+struct _jmethodID; /* opaque structure */
+typedef struct _jmethodID* jmethodID; /* method IDs */
+
+struct JNIInvokeInterface;
+
+typedef union jvalue {
+ jboolean z;
+ jbyte b;
+ jchar c;
+ jshort s;
+ jint i;
+ jlong j;
+ jfloat f;
+ jdouble d;
+ jobject l;
+} jvalue;
+
+typedef enum jobjectRefType {
+ JNIInvalidRefType = 0,
+ JNILocalRefType = 1,
+ JNIGlobalRefType = 2,
+ JNIWeakGlobalRefType = 3
+} jobjectRefType;
+
+typedef struct {
+ const char* name;
+ const char* signature;
+ void* fnPtr;
+} JNINativeMethod;
+
+struct _JNIEnv;
+struct _JavaVM;
+typedef const struct JNINativeInterface* C_JNIEnv;
+
+#if defined(__cplusplus)
+typedef _JNIEnv JNIEnv;
+typedef _JavaVM JavaVM;
+#else
+typedef const struct JNINativeInterface* JNIEnv;
+typedef const struct JNIInvokeInterface* JavaVM;
+#endif
+
+/*
+ * Table of interface function pointers.
+ */
+struct JNINativeInterface {
+ void* reserved0;
+ void* reserved1;
+ void* reserved2;
+ void* reserved3;
+
+ jint (*GetVersion)(JNIEnv *);
+
+ jclass (*DefineClass)(JNIEnv*, const char*, jobject, const jbyte*,
+ jsize);
+ jclass (*FindClass)(JNIEnv*, const char*);
+
+ jmethodID (*FromReflectedMethod)(JNIEnv*, jobject);
+ jfieldID (*FromReflectedField)(JNIEnv*, jobject);
+ /* spec doesn't show jboolean parameter */
+ jobject (*ToReflectedMethod)(JNIEnv*, jclass, jmethodID, jboolean);
+
+ jclass (*GetSuperclass)(JNIEnv*, jclass);
+ jboolean (*IsAssignableFrom)(JNIEnv*, jclass, jclass);
+
+ /* spec doesn't show jboolean parameter */
+ jobject (*ToReflectedField)(JNIEnv*, jclass, jfieldID, jboolean);
+
+ jint (*Throw)(JNIEnv*, jthrowable);
+ jint (*ThrowNew)(JNIEnv *, jclass, const char *);
+ jthrowable (*ExceptionOccurred)(JNIEnv*);
+ void (*ExceptionDescribe)(JNIEnv*);
+ void (*ExceptionClear)(JNIEnv*);
+ void (*FatalError)(JNIEnv*, const char*);
+
+ jint (*PushLocalFrame)(JNIEnv*, jint);
+ jobject (*PopLocalFrame)(JNIEnv*, jobject);
+
+ jobject (*NewGlobalRef)(JNIEnv*, jobject);
+ void (*DeleteGlobalRef)(JNIEnv*, jobject);
+ void (*DeleteLocalRef)(JNIEnv*, jobject);
+ jboolean (*IsSameObject)(JNIEnv*, jobject, jobject);
+
+ jobject (*NewLocalRef)(JNIEnv*, jobject);
+ jint (*EnsureLocalCapacity)(JNIEnv*, jint);
+
+ jobject (*AllocObject)(JNIEnv*, jclass);
+ jobject (*NewObject)(JNIEnv*, jclass, jmethodID, ...);
+ jobject (*NewObjectV)(JNIEnv*, jclass, jmethodID, va_list);
+ jobject (*NewObjectA)(JNIEnv*, jclass, jmethodID, jvalue*);
+
+ jclass (*GetObjectClass)(JNIEnv*, jobject);
+ jboolean (*IsInstanceOf)(JNIEnv*, jobject, jclass);
+ jmethodID (*GetMethodID)(JNIEnv*, jclass, const char*, const char*);
+
+ jobject (*CallObjectMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jobject (*CallObjectMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jobject (*CallObjectMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jboolean (*CallBooleanMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jboolean (*CallBooleanMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jboolean (*CallBooleanMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jbyte (*CallByteMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jbyte (*CallByteMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jbyte (*CallByteMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jchar (*CallCharMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jchar (*CallCharMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jchar (*CallCharMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jshort (*CallShortMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jshort (*CallShortMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jshort (*CallShortMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jint (*CallIntMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jint (*CallIntMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jint (*CallIntMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jlong (*CallLongMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jlong (*CallLongMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jlong (*CallLongMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jfloat (*CallFloatMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jfloat (*CallFloatMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jfloat (*CallFloatMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ jdouble (*CallDoubleMethod)(JNIEnv*, jobject, jmethodID, ...);
+ jdouble (*CallDoubleMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ jdouble (*CallDoubleMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+ void (*CallVoidMethod)(JNIEnv*, jobject, jmethodID, ...);
+ void (*CallVoidMethodV)(JNIEnv*, jobject, jmethodID, va_list);
+ void (*CallVoidMethodA)(JNIEnv*, jobject, jmethodID, jvalue*);
+
+ jobject (*CallNonvirtualObjectMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jobject (*CallNonvirtualObjectMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jobject (*CallNonvirtualObjectMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jboolean (*CallNonvirtualBooleanMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jboolean (*CallNonvirtualBooleanMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jboolean (*CallNonvirtualBooleanMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jbyte (*CallNonvirtualByteMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jbyte (*CallNonvirtualByteMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jbyte (*CallNonvirtualByteMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jchar (*CallNonvirtualCharMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jchar (*CallNonvirtualCharMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jchar (*CallNonvirtualCharMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jshort (*CallNonvirtualShortMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jshort (*CallNonvirtualShortMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jshort (*CallNonvirtualShortMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jint (*CallNonvirtualIntMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jint (*CallNonvirtualIntMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jint (*CallNonvirtualIntMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jlong (*CallNonvirtualLongMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jlong (*CallNonvirtualLongMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jlong (*CallNonvirtualLongMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jfloat (*CallNonvirtualFloatMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jfloat (*CallNonvirtualFloatMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jfloat (*CallNonvirtualFloatMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ jdouble (*CallNonvirtualDoubleMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ jdouble (*CallNonvirtualDoubleMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ jdouble (*CallNonvirtualDoubleMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+ void (*CallNonvirtualVoidMethod)(JNIEnv*, jobject, jclass,
+ jmethodID, ...);
+ void (*CallNonvirtualVoidMethodV)(JNIEnv*, jobject, jclass,
+ jmethodID, va_list);
+ void (*CallNonvirtualVoidMethodA)(JNIEnv*, jobject, jclass,
+ jmethodID, jvalue*);
+
+ jfieldID (*GetFieldID)(JNIEnv*, jclass, const char*, const char*);
+
+ jobject (*GetObjectField)(JNIEnv*, jobject, jfieldID);
+ jboolean (*GetBooleanField)(JNIEnv*, jobject, jfieldID);
+ jbyte (*GetByteField)(JNIEnv*, jobject, jfieldID);
+ jchar (*GetCharField)(JNIEnv*, jobject, jfieldID);
+ jshort (*GetShortField)(JNIEnv*, jobject, jfieldID);
+ jint (*GetIntField)(JNIEnv*, jobject, jfieldID);
+ jlong (*GetLongField)(JNIEnv*, jobject, jfieldID);
+ jfloat (*GetFloatField)(JNIEnv*, jobject, jfieldID);
+ jdouble (*GetDoubleField)(JNIEnv*, jobject, jfieldID);
+
+ void (*SetObjectField)(JNIEnv*, jobject, jfieldID, jobject);
+ void (*SetBooleanField)(JNIEnv*, jobject, jfieldID, jboolean);
+ void (*SetByteField)(JNIEnv*, jobject, jfieldID, jbyte);
+ void (*SetCharField)(JNIEnv*, jobject, jfieldID, jchar);
+ void (*SetShortField)(JNIEnv*, jobject, jfieldID, jshort);
+ void (*SetIntField)(JNIEnv*, jobject, jfieldID, jint);
+ void (*SetLongField)(JNIEnv*, jobject, jfieldID, jlong);
+ void (*SetFloatField)(JNIEnv*, jobject, jfieldID, jfloat);
+ void (*SetDoubleField)(JNIEnv*, jobject, jfieldID, jdouble);
+
+ jmethodID (*GetStaticMethodID)(JNIEnv*, jclass, const char*, const char*);
+
+ jobject (*CallStaticObjectMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jobject (*CallStaticObjectMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jobject (*CallStaticObjectMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jboolean (*CallStaticBooleanMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jboolean (*CallStaticBooleanMethodV)(JNIEnv*, jclass, jmethodID,
+ va_list);
+ jboolean (*CallStaticBooleanMethodA)(JNIEnv*, jclass, jmethodID,
+ jvalue*);
+ jbyte (*CallStaticByteMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jbyte (*CallStaticByteMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jbyte (*CallStaticByteMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jchar (*CallStaticCharMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jchar (*CallStaticCharMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jchar (*CallStaticCharMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jshort (*CallStaticShortMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jshort (*CallStaticShortMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jshort (*CallStaticShortMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jint (*CallStaticIntMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jint (*CallStaticIntMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jint (*CallStaticIntMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jlong (*CallStaticLongMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jlong (*CallStaticLongMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jlong (*CallStaticLongMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jfloat (*CallStaticFloatMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jfloat (*CallStaticFloatMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jfloat (*CallStaticFloatMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ jdouble (*CallStaticDoubleMethod)(JNIEnv*, jclass, jmethodID, ...);
+ jdouble (*CallStaticDoubleMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ jdouble (*CallStaticDoubleMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+ void (*CallStaticVoidMethod)(JNIEnv*, jclass, jmethodID, ...);
+ void (*CallStaticVoidMethodV)(JNIEnv*, jclass, jmethodID, va_list);
+ void (*CallStaticVoidMethodA)(JNIEnv*, jclass, jmethodID, jvalue*);
+
+ jfieldID (*GetStaticFieldID)(JNIEnv*, jclass, const char*,
+ const char*);
+
+ jobject (*GetStaticObjectField)(JNIEnv*, jclass, jfieldID);
+ jboolean (*GetStaticBooleanField)(JNIEnv*, jclass, jfieldID);
+ jbyte (*GetStaticByteField)(JNIEnv*, jclass, jfieldID);
+ jchar (*GetStaticCharField)(JNIEnv*, jclass, jfieldID);
+ jshort (*GetStaticShortField)(JNIEnv*, jclass, jfieldID);
+ jint (*GetStaticIntField)(JNIEnv*, jclass, jfieldID);
+ jlong (*GetStaticLongField)(JNIEnv*, jclass, jfieldID);
+ jfloat (*GetStaticFloatField)(JNIEnv*, jclass, jfieldID);
+ jdouble (*GetStaticDoubleField)(JNIEnv*, jclass, jfieldID);
+
+ void (*SetStaticObjectField)(JNIEnv*, jclass, jfieldID, jobject);
+ void (*SetStaticBooleanField)(JNIEnv*, jclass, jfieldID, jboolean);
+ void (*SetStaticByteField)(JNIEnv*, jclass, jfieldID, jbyte);
+ void (*SetStaticCharField)(JNIEnv*, jclass, jfieldID, jchar);
+ void (*SetStaticShortField)(JNIEnv*, jclass, jfieldID, jshort);
+ void (*SetStaticIntField)(JNIEnv*, jclass, jfieldID, jint);
+ void (*SetStaticLongField)(JNIEnv*, jclass, jfieldID, jlong);
+ void (*SetStaticFloatField)(JNIEnv*, jclass, jfieldID, jfloat);
+ void (*SetStaticDoubleField)(JNIEnv*, jclass, jfieldID, jdouble);
+
+ jstring (*NewString)(JNIEnv*, const jchar*, jsize);
+ jsize (*GetStringLength)(JNIEnv*, jstring);
+ const jchar* (*GetStringChars)(JNIEnv*, jstring, jboolean*);
+ void (*ReleaseStringChars)(JNIEnv*, jstring, const jchar*);
+ jstring (*NewStringUTF)(JNIEnv*, const char*);
+ jsize (*GetStringUTFLength)(JNIEnv*, jstring);
+ /* JNI spec says this returns const jbyte*, but that's inconsistent */
+ const char* (*GetStringUTFChars)(JNIEnv*, jstring, jboolean*);
+ void (*ReleaseStringUTFChars)(JNIEnv*, jstring, const char*);
+ jsize (*GetArrayLength)(JNIEnv*, jarray);
+ jobjectArray (*NewObjectArray)(JNIEnv*, jsize, jclass, jobject);
+ jobject (*GetObjectArrayElement)(JNIEnv*, jobjectArray, jsize);
+ void (*SetObjectArrayElement)(JNIEnv*, jobjectArray, jsize, jobject);
+
+ jbooleanArray (*NewBooleanArray)(JNIEnv*, jsize);
+ jbyteArray (*NewByteArray)(JNIEnv*, jsize);
+ jcharArray (*NewCharArray)(JNIEnv*, jsize);
+ jshortArray (*NewShortArray)(JNIEnv*, jsize);
+ jintArray (*NewIntArray)(JNIEnv*, jsize);
+ jlongArray (*NewLongArray)(JNIEnv*, jsize);
+ jfloatArray (*NewFloatArray)(JNIEnv*, jsize);
+ jdoubleArray (*NewDoubleArray)(JNIEnv*, jsize);
+
+ jboolean* (*GetBooleanArrayElements)(JNIEnv*, jbooleanArray, jboolean*);
+ jbyte* (*GetByteArrayElements)(JNIEnv*, jbyteArray, jboolean*);
+ jchar* (*GetCharArrayElements)(JNIEnv*, jcharArray, jboolean*);
+ jshort* (*GetShortArrayElements)(JNIEnv*, jshortArray, jboolean*);
+ jint* (*GetIntArrayElements)(JNIEnv*, jintArray, jboolean*);
+ jlong* (*GetLongArrayElements)(JNIEnv*, jlongArray, jboolean*);
+ jfloat* (*GetFloatArrayElements)(JNIEnv*, jfloatArray, jboolean*);
+ jdouble* (*GetDoubleArrayElements)(JNIEnv*, jdoubleArray, jboolean*);
+
+ void (*ReleaseBooleanArrayElements)(JNIEnv*, jbooleanArray,
+ jboolean*, jint);
+ void (*ReleaseByteArrayElements)(JNIEnv*, jbyteArray,
+ jbyte*, jint);
+ void (*ReleaseCharArrayElements)(JNIEnv*, jcharArray,
+ jchar*, jint);
+ void (*ReleaseShortArrayElements)(JNIEnv*, jshortArray,
+ jshort*, jint);
+ void (*ReleaseIntArrayElements)(JNIEnv*, jintArray,
+ jint*, jint);
+ void (*ReleaseLongArrayElements)(JNIEnv*, jlongArray,
+ jlong*, jint);
+ void (*ReleaseFloatArrayElements)(JNIEnv*, jfloatArray,
+ jfloat*, jint);
+ void (*ReleaseDoubleArrayElements)(JNIEnv*, jdoubleArray,
+ jdouble*, jint);
+
+ void (*GetBooleanArrayRegion)(JNIEnv*, jbooleanArray,
+ jsize, jsize, jboolean*);
+ void (*GetByteArrayRegion)(JNIEnv*, jbyteArray,
+ jsize, jsize, jbyte*);
+ void (*GetCharArrayRegion)(JNIEnv*, jcharArray,
+ jsize, jsize, jchar*);
+ void (*GetShortArrayRegion)(JNIEnv*, jshortArray,
+ jsize, jsize, jshort*);
+ void (*GetIntArrayRegion)(JNIEnv*, jintArray,
+ jsize, jsize, jint*);
+ void (*GetLongArrayRegion)(JNIEnv*, jlongArray,
+ jsize, jsize, jlong*);
+ void (*GetFloatArrayRegion)(JNIEnv*, jfloatArray,
+ jsize, jsize, jfloat*);
+ void (*GetDoubleArrayRegion)(JNIEnv*, jdoubleArray,
+ jsize, jsize, jdouble*);
+
+ /* spec shows these without const; some jni.h do, some don't */
+ void (*SetBooleanArrayRegion)(JNIEnv*, jbooleanArray,
+ jsize, jsize, const jboolean*);
+ void (*SetByteArrayRegion)(JNIEnv*, jbyteArray,
+ jsize, jsize, const jbyte*);
+ void (*SetCharArrayRegion)(JNIEnv*, jcharArray,
+ jsize, jsize, const jchar*);
+ void (*SetShortArrayRegion)(JNIEnv*, jshortArray,
+ jsize, jsize, const jshort*);
+ void (*SetIntArrayRegion)(JNIEnv*, jintArray,
+ jsize, jsize, const jint*);
+ void (*SetLongArrayRegion)(JNIEnv*, jlongArray,
+ jsize, jsize, const jlong*);
+ void (*SetFloatArrayRegion)(JNIEnv*, jfloatArray,
+ jsize, jsize, const jfloat*);
+ void (*SetDoubleArrayRegion)(JNIEnv*, jdoubleArray,
+ jsize, jsize, const jdouble*);
+
+ jint (*RegisterNatives)(JNIEnv*, jclass, const JNINativeMethod*,
+ jint);
+ jint (*UnregisterNatives)(JNIEnv*, jclass);
+ jint (*MonitorEnter)(JNIEnv*, jobject);
+ jint (*MonitorExit)(JNIEnv*, jobject);
+ jint (*GetJavaVM)(JNIEnv*, JavaVM**);
+
+ void (*GetStringRegion)(JNIEnv*, jstring, jsize, jsize, jchar*);
+ void (*GetStringUTFRegion)(JNIEnv*, jstring, jsize, jsize, char*);
+
+ void* (*GetPrimitiveArrayCritical)(JNIEnv*, jarray, jboolean*);
+ void (*ReleasePrimitiveArrayCritical)(JNIEnv*, jarray, void*, jint);
+
+ const jchar* (*GetStringCritical)(JNIEnv*, jstring, jboolean*);
+ void (*ReleaseStringCritical)(JNIEnv*, jstring, const jchar*);
+
+ jweak (*NewWeakGlobalRef)(JNIEnv*, jobject);
+ void (*DeleteWeakGlobalRef)(JNIEnv*, jweak);
+
+ jboolean (*ExceptionCheck)(JNIEnv*);
+
+ jobject (*NewDirectByteBuffer)(JNIEnv*, void*, jlong);
+ void* (*GetDirectBufferAddress)(JNIEnv*, jobject);
+ jlong (*GetDirectBufferCapacity)(JNIEnv*, jobject);
+
+ /* added in JNI 1.6 */
+ jobjectRefType (*GetObjectRefType)(JNIEnv*, jobject);
+};
+
+/*
+ * C++ object wrapper.
+ *
+ * This is usually overlaid on a C struct whose first element is a
+ * JNINativeInterface*. We rely somewhat on compiler behavior.
+ */
+struct _JNIEnv {
+ /* do not rename this; it does not seem to be entirely opaque */
+ const struct JNINativeInterface* functions;
+
+#if defined(__cplusplus)
+
+ jint GetVersion()
+ { return functions->GetVersion(this); }
+
+ jclass DefineClass(const char *name, jobject loader, const jbyte* buf,
+ jsize bufLen)
+ { return functions->DefineClass(this, name, loader, buf, bufLen); }
+
+ jclass FindClass(const char* name)
+ { return functions->FindClass(this, name); }
+
+ jmethodID FromReflectedMethod(jobject method)
+ { return functions->FromReflectedMethod(this, method); }
+
+ jfieldID FromReflectedField(jobject field)
+ { return functions->FromReflectedField(this, field); }
+
+ jobject ToReflectedMethod(jclass cls, jmethodID methodID, jboolean isStatic)
+ { return functions->ToReflectedMethod(this, cls, methodID, isStatic); }
+
+ jclass GetSuperclass(jclass clazz)
+ { return functions->GetSuperclass(this, clazz); }
+
+ jboolean IsAssignableFrom(jclass clazz1, jclass clazz2)
+ { return functions->IsAssignableFrom(this, clazz1, clazz2); }
+
+ jobject ToReflectedField(jclass cls, jfieldID fieldID, jboolean isStatic)
+ { return functions->ToReflectedField(this, cls, fieldID, isStatic); }
+
+ jint Throw(jthrowable obj)
+ { return functions->Throw(this, obj); }
+
+ jint ThrowNew(jclass clazz, const char* message)
+ { return functions->ThrowNew(this, clazz, message); }
+
+ jthrowable ExceptionOccurred()
+ { return functions->ExceptionOccurred(this); }
+
+ void ExceptionDescribe()
+ { functions->ExceptionDescribe(this); }
+
+ void ExceptionClear()
+ { functions->ExceptionClear(this); }
+
+ void FatalError(const char* msg)
+ { functions->FatalError(this, msg); }
+
+ jint PushLocalFrame(jint capacity)
+ { return functions->PushLocalFrame(this, capacity); }
+
+ jobject PopLocalFrame(jobject result)
+ { return functions->PopLocalFrame(this, result); }
+
+ jobject NewGlobalRef(jobject obj)
+ { return functions->NewGlobalRef(this, obj); }
+
+ void DeleteGlobalRef(jobject globalRef)
+ { functions->DeleteGlobalRef(this, globalRef); }
+
+ void DeleteLocalRef(jobject localRef)
+ { functions->DeleteLocalRef(this, localRef); }
+
+ jboolean IsSameObject(jobject ref1, jobject ref2)
+ { return functions->IsSameObject(this, ref1, ref2); }
+
+ jobject NewLocalRef(jobject ref)
+ { return functions->NewLocalRef(this, ref); }
+
+ jint EnsureLocalCapacity(jint capacity)
+ { return functions->EnsureLocalCapacity(this, capacity); }
+
+ jobject AllocObject(jclass clazz)
+ { return functions->AllocObject(this, clazz); }
+
+ jobject NewObject(jclass clazz, jmethodID methodID, ...)
+ {
+ va_list args;
+ va_start(args, methodID);
+ jobject result = functions->NewObjectV(this, clazz, methodID, args);
+ va_end(args);
+ return result;
+ }
+
+ jobject NewObjectV(jclass clazz, jmethodID methodID, va_list args)
+ { return functions->NewObjectV(this, clazz, methodID, args); }
+
+ jobject NewObjectA(jclass clazz, jmethodID methodID, jvalue* args)
+ { return functions->NewObjectA(this, clazz, methodID, args); }
+
+ jclass GetObjectClass(jobject obj)
+ { return functions->GetObjectClass(this, obj); }
+
+ jboolean IsInstanceOf(jobject obj, jclass clazz)
+ { return functions->IsInstanceOf(this, obj, clazz); }
+
+ jmethodID GetMethodID(jclass clazz, const char* name, const char* sig)
+ { return functions->GetMethodID(this, clazz, name, sig); }
+
+#define CALL_TYPE_METHOD(_jtype, _jname) \
+ _jtype Call##_jname##Method(jobject obj, jmethodID methodID, ...) \
+ { \
+ _jtype result; \
+ va_list args; \
+ va_start(args, methodID); \
+ result = functions->Call##_jname##MethodV(this, obj, methodID, \
+ args); \
+ va_end(args); \
+ return result; \
+ }
+#define CALL_TYPE_METHODV(_jtype, _jname) \
+ _jtype Call##_jname##MethodV(jobject obj, jmethodID methodID, \
+ va_list args) \
+ { return functions->Call##_jname##MethodV(this, obj, methodID, args); }
+#define CALL_TYPE_METHODA(_jtype, _jname) \
+ _jtype Call##_jname##MethodA(jobject obj, jmethodID methodID, \
+ jvalue* args) \
+ { return functions->Call##_jname##MethodA(this, obj, methodID, args); }
+
+#define CALL_TYPE(_jtype, _jname) \
+ CALL_TYPE_METHOD(_jtype, _jname) \
+ CALL_TYPE_METHODV(_jtype, _jname) \
+ CALL_TYPE_METHODA(_jtype, _jname)
+
+ CALL_TYPE(jobject, Object)
+ CALL_TYPE(jboolean, Boolean)
+ CALL_TYPE(jbyte, Byte)
+ CALL_TYPE(jchar, Char)
+ CALL_TYPE(jshort, Short)
+ CALL_TYPE(jint, Int)
+ CALL_TYPE(jlong, Long)
+ CALL_TYPE(jfloat, Float)
+ CALL_TYPE(jdouble, Double)
+
+ void CallVoidMethod(jobject obj, jmethodID methodID, ...)
+ {
+ va_list args;
+ va_start(args, methodID);
+ functions->CallVoidMethodV(this, obj, methodID, args);
+ va_end(args);
+ }
+ void CallVoidMethodV(jobject obj, jmethodID methodID, va_list args)
+ { functions->CallVoidMethodV(this, obj, methodID, args); }
+ void CallVoidMethodA(jobject obj, jmethodID methodID, jvalue* args)
+ { functions->CallVoidMethodA(this, obj, methodID, args); }
+
+#define CALL_NONVIRT_TYPE_METHOD(_jtype, _jname) \
+ _jtype CallNonvirtual##_jname##Method(jobject obj, jclass clazz, \
+ jmethodID methodID, ...) \
+ { \
+ _jtype result; \
+ va_list args; \
+ va_start(args, methodID); \
+ result = functions->CallNonvirtual##_jname##MethodV(this, obj, \
+ clazz, methodID, args); \
+ va_end(args); \
+ return result; \
+ }
+#define CALL_NONVIRT_TYPE_METHODV(_jtype, _jname) \
+ _jtype CallNonvirtual##_jname##MethodV(jobject obj, jclass clazz, \
+ jmethodID methodID, va_list args) \
+ { return functions->CallNonvirtual##_jname##MethodV(this, obj, clazz, \
+ methodID, args); }
+#define CALL_NONVIRT_TYPE_METHODA(_jtype, _jname) \
+ _jtype CallNonvirtual##_jname##MethodA(jobject obj, jclass clazz, \
+ jmethodID methodID, jvalue* args) \
+ { return functions->CallNonvirtual##_jname##MethodA(this, obj, clazz, \
+ methodID, args); }
+
+#define CALL_NONVIRT_TYPE(_jtype, _jname) \
+ CALL_NONVIRT_TYPE_METHOD(_jtype, _jname) \
+ CALL_NONVIRT_TYPE_METHODV(_jtype, _jname) \
+ CALL_NONVIRT_TYPE_METHODA(_jtype, _jname)
+
+ CALL_NONVIRT_TYPE(jobject, Object)
+ CALL_NONVIRT_TYPE(jboolean, Boolean)
+ CALL_NONVIRT_TYPE(jbyte, Byte)
+ CALL_NONVIRT_TYPE(jchar, Char)
+ CALL_NONVIRT_TYPE(jshort, Short)
+ CALL_NONVIRT_TYPE(jint, Int)
+ CALL_NONVIRT_TYPE(jlong, Long)
+ CALL_NONVIRT_TYPE(jfloat, Float)
+ CALL_NONVIRT_TYPE(jdouble, Double)
+
+ void CallNonvirtualVoidMethod(jobject obj, jclass clazz,
+ jmethodID methodID, ...)
+ {
+ va_list args;
+ va_start(args, methodID);
+ functions->CallNonvirtualVoidMethodV(this, obj, clazz, methodID, args);
+ va_end(args);
+ }
+ void CallNonvirtualVoidMethodV(jobject obj, jclass clazz,
+ jmethodID methodID, va_list args)
+ { functions->CallNonvirtualVoidMethodV(this, obj, clazz, methodID, args); }
+ void CallNonvirtualVoidMethodA(jobject obj, jclass clazz,
+ jmethodID methodID, jvalue* args)
+ { functions->CallNonvirtualVoidMethodA(this, obj, clazz, methodID, args); }
+
+ jfieldID GetFieldID(jclass clazz, const char* name, const char* sig)
+ { return functions->GetFieldID(this, clazz, name, sig); }
+
+ jobject GetObjectField(jobject obj, jfieldID fieldID)
+ { return functions->GetObjectField(this, obj, fieldID); }
+ jboolean GetBooleanField(jobject obj, jfieldID fieldID)
+ { return functions->GetBooleanField(this, obj, fieldID); }
+ jbyte GetByteField(jobject obj, jfieldID fieldID)
+ { return functions->GetByteField(this, obj, fieldID); }
+ jchar GetCharField(jobject obj, jfieldID fieldID)
+ { return functions->GetCharField(this, obj, fieldID); }
+ jshort GetShortField(jobject obj, jfieldID fieldID)
+ { return functions->GetShortField(this, obj, fieldID); }
+ jint GetIntField(jobject obj, jfieldID fieldID)
+ { return functions->GetIntField(this, obj, fieldID); }
+ jlong GetLongField(jobject obj, jfieldID fieldID)
+ { return functions->GetLongField(this, obj, fieldID); }
+ jfloat GetFloatField(jobject obj, jfieldID fieldID)
+ { return functions->GetFloatField(this, obj, fieldID); }
+ jdouble GetDoubleField(jobject obj, jfieldID fieldID)
+ { return functions->GetDoubleField(this, obj, fieldID); }
+
+ void SetObjectField(jobject obj, jfieldID fieldID, jobject value)
+ { functions->SetObjectField(this, obj, fieldID, value); }
+ void SetBooleanField(jobject obj, jfieldID fieldID, jboolean value)
+ { functions->SetBooleanField(this, obj, fieldID, value); }
+ void SetByteField(jobject obj, jfieldID fieldID, jbyte value)
+ { functions->SetByteField(this, obj, fieldID, value); }
+ void SetCharField(jobject obj, jfieldID fieldID, jchar value)
+ { functions->SetCharField(this, obj, fieldID, value); }
+ void SetShortField(jobject obj, jfieldID fieldID, jshort value)
+ { functions->SetShortField(this, obj, fieldID, value); }
+ void SetIntField(jobject obj, jfieldID fieldID, jint value)
+ { functions->SetIntField(this, obj, fieldID, value); }
+ void SetLongField(jobject obj, jfieldID fieldID, jlong value)
+ { functions->SetLongField(this, obj, fieldID, value); }
+ void SetFloatField(jobject obj, jfieldID fieldID, jfloat value)
+ { functions->SetFloatField(this, obj, fieldID, value); }
+ void SetDoubleField(jobject obj, jfieldID fieldID, jdouble value)
+ { functions->SetDoubleField(this, obj, fieldID, value); }
+
+ jmethodID GetStaticMethodID(jclass clazz, const char* name, const char* sig)
+ { return functions->GetStaticMethodID(this, clazz, name, sig); }
+
+#define CALL_STATIC_TYPE_METHOD(_jtype, _jname) \
+ _jtype CallStatic##_jname##Method(jclass clazz, jmethodID methodID, \
+ ...) \
+ { \
+ _jtype result; \
+ va_list args; \
+ va_start(args, methodID); \
+ result = functions->CallStatic##_jname##MethodV(this, clazz, \
+ methodID, args); \
+ va_end(args); \
+ return result; \
+ }
+#define CALL_STATIC_TYPE_METHODV(_jtype, _jname) \
+ _jtype CallStatic##_jname##MethodV(jclass clazz, jmethodID methodID, \
+ va_list args) \
+ { return functions->CallStatic##_jname##MethodV(this, clazz, methodID, \
+ args); }
+#define CALL_STATIC_TYPE_METHODA(_jtype, _jname) \
+ _jtype CallStatic##_jname##MethodA(jclass clazz, jmethodID methodID, \
+ jvalue* args) \
+ { return functions->CallStatic##_jname##MethodA(this, clazz, methodID, \
+ args); }
+
+#define CALL_STATIC_TYPE(_jtype, _jname) \
+ CALL_STATIC_TYPE_METHOD(_jtype, _jname) \
+ CALL_STATIC_TYPE_METHODV(_jtype, _jname) \
+ CALL_STATIC_TYPE_METHODA(_jtype, _jname)
+
+ CALL_STATIC_TYPE(jobject, Object)
+ CALL_STATIC_TYPE(jboolean, Boolean)
+ CALL_STATIC_TYPE(jbyte, Byte)
+ CALL_STATIC_TYPE(jchar, Char)
+ CALL_STATIC_TYPE(jshort, Short)
+ CALL_STATIC_TYPE(jint, Int)
+ CALL_STATIC_TYPE(jlong, Long)
+ CALL_STATIC_TYPE(jfloat, Float)
+ CALL_STATIC_TYPE(jdouble, Double)
+
+ void CallStaticVoidMethod(jclass clazz, jmethodID methodID, ...)
+ {
+ va_list args;
+ va_start(args, methodID);
+ functions->CallStaticVoidMethodV(this, clazz, methodID, args);
+ va_end(args);
+ }
+ void CallStaticVoidMethodV(jclass clazz, jmethodID methodID, va_list args)
+ { functions->CallStaticVoidMethodV(this, clazz, methodID, args); }
+ void CallStaticVoidMethodA(jclass clazz, jmethodID methodID, jvalue* args)
+ { functions->CallStaticVoidMethodA(this, clazz, methodID, args); }
+
+ jfieldID GetStaticFieldID(jclass clazz, const char* name, const char* sig)
+ { return functions->GetStaticFieldID(this, clazz, name, sig); }
+
+ jobject GetStaticObjectField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticObjectField(this, clazz, fieldID); }
+ jboolean GetStaticBooleanField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticBooleanField(this, clazz, fieldID); }
+ jbyte GetStaticByteField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticByteField(this, clazz, fieldID); }
+ jchar GetStaticCharField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticCharField(this, clazz, fieldID); }
+ jshort GetStaticShortField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticShortField(this, clazz, fieldID); }
+ jint GetStaticIntField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticIntField(this, clazz, fieldID); }
+ jlong GetStaticLongField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticLongField(this, clazz, fieldID); }
+ jfloat GetStaticFloatField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticFloatField(this, clazz, fieldID); }
+ jdouble GetStaticDoubleField(jclass clazz, jfieldID fieldID)
+ { return functions->GetStaticDoubleField(this, clazz, fieldID); }
+
+ void SetStaticObjectField(jclass clazz, jfieldID fieldID, jobject value)
+ { functions->SetStaticObjectField(this, clazz, fieldID, value); }
+ void SetStaticBooleanField(jclass clazz, jfieldID fieldID, jboolean value)
+ { functions->SetStaticBooleanField(this, clazz, fieldID, value); }
+ void SetStaticByteField(jclass clazz, jfieldID fieldID, jbyte value)
+ { functions->SetStaticByteField(this, clazz, fieldID, value); }
+ void SetStaticCharField(jclass clazz, jfieldID fieldID, jchar value)
+ { functions->SetStaticCharField(this, clazz, fieldID, value); }
+ void SetStaticShortField(jclass clazz, jfieldID fieldID, jshort value)
+ { functions->SetStaticShortField(this, clazz, fieldID, value); }
+ void SetStaticIntField(jclass clazz, jfieldID fieldID, jint value)
+ { functions->SetStaticIntField(this, clazz, fieldID, value); }
+ void SetStaticLongField(jclass clazz, jfieldID fieldID, jlong value)
+ { functions->SetStaticLongField(this, clazz, fieldID, value); }
+ void SetStaticFloatField(jclass clazz, jfieldID fieldID, jfloat value)
+ { functions->SetStaticFloatField(this, clazz, fieldID, value); }
+ void SetStaticDoubleField(jclass clazz, jfieldID fieldID, jdouble value)
+ { functions->SetStaticDoubleField(this, clazz, fieldID, value); }
+
+ jstring NewString(const jchar* unicodeChars, jsize len)
+ { return functions->NewString(this, unicodeChars, len); }
+
+ jsize GetStringLength(jstring string)
+ { return functions->GetStringLength(this, string); }
+
+ const jchar* GetStringChars(jstring string, jboolean* isCopy)
+ { return functions->GetStringChars(this, string, isCopy); }
+
+ void ReleaseStringChars(jstring string, const jchar* chars)
+ { functions->ReleaseStringChars(this, string, chars); }
+
+ jstring NewStringUTF(const char* bytes)
+ { return functions->NewStringUTF(this, bytes); }
+
+ jsize GetStringUTFLength(jstring string)
+ { return functions->GetStringUTFLength(this, string); }
+
+ const char* GetStringUTFChars(jstring string, jboolean* isCopy)
+ { return functions->GetStringUTFChars(this, string, isCopy); }
+
+ void ReleaseStringUTFChars(jstring string, const char* utf)
+ { functions->ReleaseStringUTFChars(this, string, utf); }
+
+ jsize GetArrayLength(jarray array)
+ { return functions->GetArrayLength(this, array); }
+
+ jobjectArray NewObjectArray(jsize length, jclass elementClass,
+ jobject initialElement)
+ { return functions->NewObjectArray(this, length, elementClass,
+ initialElement); }
+
+ jobject GetObjectArrayElement(jobjectArray array, jsize index)
+ { return functions->GetObjectArrayElement(this, array, index); }
+
+ void SetObjectArrayElement(jobjectArray array, jsize index, jobject value)
+ { functions->SetObjectArrayElement(this, array, index, value); }
+
+ jbooleanArray NewBooleanArray(jsize length)
+ { return functions->NewBooleanArray(this, length); }
+ jbyteArray NewByteArray(jsize length)
+ { return functions->NewByteArray(this, length); }
+ jcharArray NewCharArray(jsize length)
+ { return functions->NewCharArray(this, length); }
+ jshortArray NewShortArray(jsize length)
+ { return functions->NewShortArray(this, length); }
+ jintArray NewIntArray(jsize length)
+ { return functions->NewIntArray(this, length); }
+ jlongArray NewLongArray(jsize length)
+ { return functions->NewLongArray(this, length); }
+ jfloatArray NewFloatArray(jsize length)
+ { return functions->NewFloatArray(this, length); }
+ jdoubleArray NewDoubleArray(jsize length)
+ { return functions->NewDoubleArray(this, length); }
+
+ jboolean* GetBooleanArrayElements(jbooleanArray array, jboolean* isCopy)
+ { return functions->GetBooleanArrayElements(this, array, isCopy); }
+ jbyte* GetByteArrayElements(jbyteArray array, jboolean* isCopy)
+ { return functions->GetByteArrayElements(this, array, isCopy); }
+ jchar* GetCharArrayElements(jcharArray array, jboolean* isCopy)
+ { return functions->GetCharArrayElements(this, array, isCopy); }
+ jshort* GetShortArrayElements(jshortArray array, jboolean* isCopy)
+ { return functions->GetShortArrayElements(this, array, isCopy); }
+ jint* GetIntArrayElements(jintArray array, jboolean* isCopy)
+ { return functions->GetIntArrayElements(this, array, isCopy); }
+ jlong* GetLongArrayElements(jlongArray array, jboolean* isCopy)
+ { return functions->GetLongArrayElements(this, array, isCopy); }
+ jfloat* GetFloatArrayElements(jfloatArray array, jboolean* isCopy)
+ { return functions->GetFloatArrayElements(this, array, isCopy); }
+ jdouble* GetDoubleArrayElements(jdoubleArray array, jboolean* isCopy)
+ { return functions->GetDoubleArrayElements(this, array, isCopy); }
+
+ void ReleaseBooleanArrayElements(jbooleanArray array, jboolean* elems,
+ jint mode)
+ { functions->ReleaseBooleanArrayElements(this, array, elems, mode); }
+ void ReleaseByteArrayElements(jbyteArray array, jbyte* elems,
+ jint mode)
+ { functions->ReleaseByteArrayElements(this, array, elems, mode); }
+ void ReleaseCharArrayElements(jcharArray array, jchar* elems,
+ jint mode)
+ { functions->ReleaseCharArrayElements(this, array, elems, mode); }
+ void ReleaseShortArrayElements(jshortArray array, jshort* elems,
+ jint mode)
+ { functions->ReleaseShortArrayElements(this, array, elems, mode); }
+ void ReleaseIntArrayElements(jintArray array, jint* elems,
+ jint mode)
+ { functions->ReleaseIntArrayElements(this, array, elems, mode); }
+ void ReleaseLongArrayElements(jlongArray array, jlong* elems,
+ jint mode)
+ { functions->ReleaseLongArrayElements(this, array, elems, mode); }
+ void ReleaseFloatArrayElements(jfloatArray array, jfloat* elems,
+ jint mode)
+ { functions->ReleaseFloatArrayElements(this, array, elems, mode); }
+ void ReleaseDoubleArrayElements(jdoubleArray array, jdouble* elems,
+ jint mode)
+ { functions->ReleaseDoubleArrayElements(this, array, elems, mode); }
+
+ void GetBooleanArrayRegion(jbooleanArray array, jsize start, jsize len,
+ jboolean* buf)
+ { functions->GetBooleanArrayRegion(this, array, start, len, buf); }
+ void GetByteArrayRegion(jbyteArray array, jsize start, jsize len,
+ jbyte* buf)
+ { functions->GetByteArrayRegion(this, array, start, len, buf); }
+ void GetCharArrayRegion(jcharArray array, jsize start, jsize len,
+ jchar* buf)
+ { functions->GetCharArrayRegion(this, array, start, len, buf); }
+ void GetShortArrayRegion(jshortArray array, jsize start, jsize len,
+ jshort* buf)
+ { functions->GetShortArrayRegion(this, array, start, len, buf); }
+ void GetIntArrayRegion(jintArray array, jsize start, jsize len,
+ jint* buf)
+ { functions->GetIntArrayRegion(this, array, start, len, buf); }
+ void GetLongArrayRegion(jlongArray array, jsize start, jsize len,
+ jlong* buf)
+ { functions->GetLongArrayRegion(this, array, start, len, buf); }
+ void GetFloatArrayRegion(jfloatArray array, jsize start, jsize len,
+ jfloat* buf)
+ { functions->GetFloatArrayRegion(this, array, start, len, buf); }
+ void GetDoubleArrayRegion(jdoubleArray array, jsize start, jsize len,
+ jdouble* buf)
+ { functions->GetDoubleArrayRegion(this, array, start, len, buf); }
+
+ void SetBooleanArrayRegion(jbooleanArray array, jsize start, jsize len,
+ const jboolean* buf)
+ { functions->SetBooleanArrayRegion(this, array, start, len, buf); }
+ void SetByteArrayRegion(jbyteArray array, jsize start, jsize len,
+ const jbyte* buf)
+ { functions->SetByteArrayRegion(this, array, start, len, buf); }
+ void SetCharArrayRegion(jcharArray array, jsize start, jsize len,
+ const jchar* buf)
+ { functions->SetCharArrayRegion(this, array, start, len, buf); }
+ void SetShortArrayRegion(jshortArray array, jsize start, jsize len,
+ const jshort* buf)
+ { functions->SetShortArrayRegion(this, array, start, len, buf); }
+ void SetIntArrayRegion(jintArray array, jsize start, jsize len,
+ const jint* buf)
+ { functions->SetIntArrayRegion(this, array, start, len, buf); }
+ void SetLongArrayRegion(jlongArray array, jsize start, jsize len,
+ const jlong* buf)
+ { functions->SetLongArrayRegion(this, array, start, len, buf); }
+ void SetFloatArrayRegion(jfloatArray array, jsize start, jsize len,
+ const jfloat* buf)
+ { functions->SetFloatArrayRegion(this, array, start, len, buf); }
+ void SetDoubleArrayRegion(jdoubleArray array, jsize start, jsize len,
+ const jdouble* buf)
+ { functions->SetDoubleArrayRegion(this, array, start, len, buf); }
+
+ jint RegisterNatives(jclass clazz, const JNINativeMethod* methods,
+ jint nMethods)
+ { return functions->RegisterNatives(this, clazz, methods, nMethods); }
+
+ jint UnregisterNatives(jclass clazz)
+ { return functions->UnregisterNatives(this, clazz); }
+
+ jint MonitorEnter(jobject obj)
+ { return functions->MonitorEnter(this, obj); }
+
+ jint MonitorExit(jobject obj)
+ { return functions->MonitorExit(this, obj); }
+
+ jint GetJavaVM(JavaVM** vm)
+ { return functions->GetJavaVM(this, vm); }
+
+ void GetStringRegion(jstring str, jsize start, jsize len, jchar* buf)
+ { functions->GetStringRegion(this, str, start, len, buf); }
+
+ void GetStringUTFRegion(jstring str, jsize start, jsize len, char* buf)
+ { return functions->GetStringUTFRegion(this, str, start, len, buf); }
+
+ void* GetPrimitiveArrayCritical(jarray array, jboolean* isCopy)
+ { return functions->GetPrimitiveArrayCritical(this, array, isCopy); }
+
+ void ReleasePrimitiveArrayCritical(jarray array, void* carray, jint mode)
+ { functions->ReleasePrimitiveArrayCritical(this, array, carray, mode); }
+
+ const jchar* GetStringCritical(jstring string, jboolean* isCopy)
+ { return functions->GetStringCritical(this, string, isCopy); }
+
+ void ReleaseStringCritical(jstring string, const jchar* carray)
+ { functions->ReleaseStringCritical(this, string, carray); }
+
+ jweak NewWeakGlobalRef(jobject obj)
+ { return functions->NewWeakGlobalRef(this, obj); }
+
+ void DeleteWeakGlobalRef(jweak obj)
+ { functions->DeleteWeakGlobalRef(this, obj); }
+
+ jboolean ExceptionCheck()
+ { return functions->ExceptionCheck(this); }
+
+ jobject NewDirectByteBuffer(void* address, jlong capacity)
+ { return functions->NewDirectByteBuffer(this, address, capacity); }
+
+ void* GetDirectBufferAddress(jobject buf)
+ { return functions->GetDirectBufferAddress(this, buf); }
+
+ jlong GetDirectBufferCapacity(jobject buf)
+ { return functions->GetDirectBufferCapacity(this, buf); }
+
+ /* added in JNI 1.6 */
+ jobjectRefType GetObjectRefType(jobject obj)
+ { return functions->GetObjectRefType(this, obj); }
+#endif /*__cplusplus*/
+};
+
+
+/*
+ * JNI invocation interface.
+ */
+struct JNIInvokeInterface {
+ void* reserved0;
+ void* reserved1;
+ void* reserved2;
+
+ jint (*DestroyJavaVM)(JavaVM*);
+ jint (*AttachCurrentThread)(JavaVM*, JNIEnv**, void*);
+ jint (*DetachCurrentThread)(JavaVM*);
+ jint (*GetEnv)(JavaVM*, void**, jint);
+ jint (*AttachCurrentThreadAsDaemon)(JavaVM*, JNIEnv**, void*);
+};
+
+/*
+ * C++ version.
+ */
+struct _JavaVM {
+ const struct JNIInvokeInterface* functions;
+
+#if defined(__cplusplus)
+ jint DestroyJavaVM()
+ { return functions->DestroyJavaVM(this); }
+ jint AttachCurrentThread(JNIEnv** p_env, void* thr_args)
+ { return functions->AttachCurrentThread(this, p_env, thr_args); }
+ jint DetachCurrentThread()
+ { return functions->DetachCurrentThread(this); }
+ jint GetEnv(void** env, jint version)
+ { return functions->GetEnv(this, env, version); }
+ jint AttachCurrentThreadAsDaemon(JNIEnv** p_env, void* thr_args)
+ { return functions->AttachCurrentThreadAsDaemon(this, p_env, thr_args); }
+#endif /*__cplusplus*/
+};
+
+struct JavaVMAttachArgs {
+ jint version; /* must be >= JNI_VERSION_1_2 */
+ const char* name; /* NULL or name of thread as modified UTF-8 str */
+ jobject group; /* global ref of a ThreadGroup object, or NULL */
+};
+typedef struct JavaVMAttachArgs JavaVMAttachArgs;
+
+/*
+ * JNI 1.2+ initialization. (As of 1.6, the pre-1.2 structures are no
+ * longer supported.)
+ */
+typedef struct JavaVMOption {
+ const char* optionString;
+ void* extraInfo;
+} JavaVMOption;
+
+typedef struct JavaVMInitArgs {
+ jint version; /* use JNI_VERSION_1_2 or later */
+
+ jint nOptions;
+ JavaVMOption* options;
+ jboolean ignoreUnrecognized;
+} JavaVMInitArgs;
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+/*
+ * VM initialization functions.
+ *
+ * Note these are the only symbols exported for JNI by the VM.
+ */
+jint JNI_GetDefaultJavaVMInitArgs(void*);
+jint JNI_CreateJavaVM(JavaVM**, JNIEnv**, void*);
+jint JNI_GetCreatedJavaVMs(JavaVM**, jsize, jsize*);
+
+/*
+ * Prototypes for functions exported by loadable shared libs. These are
+ * called by JNI, not provided by JNI.
+ */
+jint JNI_OnLoad(JavaVM* vm, void* reserved);
+void JNI_OnUnload(JavaVM* vm, void* reserved);
+
+#ifdef __cplusplus
+}
+#endif
+
+
+/*
+ * Manifest constants.
+ */
+#define JNI_FALSE 0
+#define JNI_TRUE 1
+
+#define JNI_VERSION_1_1 0x00010001
+#define JNI_VERSION_1_2 0x00010002
+#define JNI_VERSION_1_4 0x00010004
+#define JNI_VERSION_1_6 0x00010006
+
+#define JNI_OK (0) /* no error */
+#define JNI_ERR (-1) /* generic error */
+#define JNI_EDETACHED (-2) /* thread detached from the VM */
+#define JNI_EVERSION (-3) /* JNI version error */
+
+#define JNI_COMMIT 1 /* copy content, do not free buffer */
+#define JNI_ABORT 2 /* free buffer w/o copying back */
+
+/* need these for Windows-aware headers */
+#define JNIIMPORT
+#define JNIEXPORT
+#define JNICALL
+
+#endif /*_JNI_H*/
diff --git a/ndk/build/platforms/android-1.5/common/include/lastlog.h b/ndk/build/platforms/android-1.5/common/include/lastlog.h
new file mode 100644
index 000000000..e69de29bb
diff --git a/ndk/build/platforms/android-1.5/common/include/libgen.h b/ndk/build/platforms/android-1.5/common/include/libgen.h
new file mode 100644
index 000000000..c5fc76a79
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/libgen.h
@@ -0,0 +1,57 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ */
+#ifndef _LIBGEN_H
+#define _LIBGEN_H
+
+#include
+#include
+
+__BEGIN_DECLS
+
+/* our version of dirname/basename don't modify the input path */
+extern char* dirname (const char* path);
+extern char* basename(const char* path);
+
+/* special thread-safe Bionic versions
+ *
+ * if 'buffer' is NULL, 'bufflen' is ignored and the length of the result is returned
+ * otherwise, place result in 'buffer'
+ *
+ * at most bufflen-1 characters written, plus a terminating zero
+ *
+ * return length of result, or -1 in case of error, with errno set to:
+ *
+ * ERANGE: buffer is too short
+ * ENAMETOOLONG: the result is too long for a valid path
+ */
+extern int dirname_r(const char* path, char* buffer, size_t bufflen);
+extern int basename_r(const char* path, char* buffer, size_t bufflen);
+
+__END_DECLS
+
+#endif /* _LIBGEN_H */
diff --git a/ndk/build/platforms/android-1.5/common/include/limits.h b/ndk/build/platforms/android-1.5/common/include/limits.h
new file mode 100644
index 000000000..c204e4dfd
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/limits.h
@@ -0,0 +1,96 @@
+/* $OpenBSD: limits.h,v 1.13 2005/12/31 19:29:38 millert Exp $ */
+/* $NetBSD: limits.h,v 1.7 1994/10/26 00:56:00 cgd Exp $ */
+
+/*
+ * Copyright (c) 1988 The Regents of the University of California.
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * @(#)limits.h 5.9 (Berkeley) 4/3/91
+ */
+
+#ifndef _LIMITS_H_
+#define _LIMITS_H_
+
+#include
+
+#if __POSIX_VISIBLE
+#define _POSIX_ARG_MAX 4096
+#define _POSIX_CHILD_MAX 25
+#define _POSIX_LINK_MAX 8
+#define _POSIX_MAX_CANON 255
+#define _POSIX_MAX_INPUT 255
+#define _POSIX_NAME_MAX 14
+#define _POSIX_NGROUPS_MAX 0
+#define _POSIX_OPEN_MAX 16
+#define _POSIX_PATH_MAX 256
+#define _POSIX_PIPE_BUF 512
+#define _POSIX_RE_DUP_MAX 255
+#define _POSIX_SSIZE_MAX 32767
+#define _POSIX_STREAM_MAX 8
+#define _POSIX_SYMLINK_MAX 255
+#define _POSIX_SYMLOOP_MAX 8
+#define _POSIX_TZNAME_MAX 3
+
+#define _POSIX2_BC_BASE_MAX 99
+#define _POSIX2_BC_DIM_MAX 2048
+#define _POSIX2_BC_SCALE_MAX 99
+#define _POSIX2_BC_STRING_MAX 1000
+#define _POSIX2_COLL_WEIGHTS_MAX 2
+#define _POSIX2_EXPR_NEST_MAX 32
+#define _POSIX2_LINE_MAX 2048
+#define _POSIX2_RE_DUP_MAX _POSIX_RE_DUP_MAX
+
+#if __POSIX_VISIBLE >= 200112
+#define _POSIX_TTY_NAME_MAX 9 /* includes trailing NUL */
+#define _POSIX_LOGIN_NAME_MAX 9 /* includes trailing NUL */
+#endif /* __POSIX_VISIBLE >= 200112 */
+#endif /* __POSIX_VISIBLE */
+
+#if __XPG_VISIBLE
+#define PASS_MAX 128 /* _PASSWORD_LEN from */
+
+#define NL_ARGMAX 9
+#define NL_LANGMAX 14
+#define NL_MSGMAX 32767
+#define NL_NMAX 1
+#define NL_SETMAX 255
+#define NL_TEXTMAX 255
+
+#define TMP_MAX 308915776
+#endif /* __XPG_VISIBLE */
+
+#include
+
+#if __POSIX_VISIBLE
+#include
+#endif
+
+#ifndef PAGESIZE
+#define PAGESIZE PAGE_SIZE
+#endif
+
+#endif /* !_LIMITS_H_ */
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/a.out.h b/ndk/build/platforms/android-1.5/common/include/linux/a.out.h
new file mode 100644
index 000000000..73253043e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/a.out.h
@@ -0,0 +1,220 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __A_OUT_GNU_H__
+#define __A_OUT_GNU_H__
+
+#define __GNU_EXEC_MACROS__
+
+#ifndef __STRUCT_EXEC_OVERRIDE__
+
+#include
+
+#endif
+
+enum machine_type {
+#ifdef M_OLDSUN2
+ M__OLDSUN2 = M_OLDSUN2,
+#else
+ M_OLDSUN2 = 0,
+#endif
+#ifdef M_68010
+ M__68010 = M_68010,
+#else
+ M_68010 = 1,
+#endif
+#ifdef M_68020
+ M__68020 = M_68020,
+#else
+ M_68020 = 2,
+#endif
+#ifdef M_SPARC
+ M__SPARC = M_SPARC,
+#else
+ M_SPARC = 3,
+#endif
+
+ M_386 = 100,
+ M_MIPS1 = 151,
+ M_MIPS2 = 152
+};
+
+#ifndef N_MAGIC
+#define N_MAGIC(exec) ((exec).a_info & 0xffff)
+#endif
+#define N_MACHTYPE(exec) ((enum machine_type)(((exec).a_info >> 16) & 0xff))
+#define N_FLAGS(exec) (((exec).a_info >> 24) & 0xff)
+#define N_SET_INFO(exec, magic, type, flags) ((exec).a_info = ((magic) & 0xffff) | (((int)(type) & 0xff) << 16) | (((flags) & 0xff) << 24))
+#define N_SET_MAGIC(exec, magic) ((exec).a_info = (((exec).a_info & 0xffff0000) | ((magic) & 0xffff)))
+
+#define N_SET_MACHTYPE(exec, machtype) ((exec).a_info = ((exec).a_info&0xff00ffff) | ((((int)(machtype))&0xff) << 16))
+
+#define N_SET_FLAGS(exec, flags) ((exec).a_info = ((exec).a_info&0x00ffffff) | (((flags) & 0xff) << 24))
+
+#define OMAGIC 0407
+
+#define NMAGIC 0410
+
+#define ZMAGIC 0413
+
+#define QMAGIC 0314
+
+#define CMAGIC 0421
+
+#ifndef N_BADMAG
+#define N_BADMAG(x) (N_MAGIC(x) != OMAGIC && N_MAGIC(x) != NMAGIC && N_MAGIC(x) != ZMAGIC && N_MAGIC(x) != QMAGIC)
+#endif
+
+#define _N_HDROFF(x) (1024 - sizeof (struct exec))
+
+#ifndef N_TXTOFF
+#define N_TXTOFF(x) (N_MAGIC(x) == ZMAGIC ? _N_HDROFF((x)) + sizeof (struct exec) : (N_MAGIC(x) == QMAGIC ? 0 : sizeof (struct exec)))
+#endif
+
+#ifndef N_DATOFF
+#define N_DATOFF(x) (N_TXTOFF(x) + (x).a_text)
+#endif
+
+#ifndef N_TRELOFF
+#define N_TRELOFF(x) (N_DATOFF(x) + (x).a_data)
+#endif
+
+#ifndef N_DRELOFF
+#define N_DRELOFF(x) (N_TRELOFF(x) + N_TRSIZE(x))
+#endif
+
+#ifndef N_SYMOFF
+#define N_SYMOFF(x) (N_DRELOFF(x) + N_DRSIZE(x))
+#endif
+
+#ifndef N_STROFF
+#define N_STROFF(x) (N_SYMOFF(x) + N_SYMSIZE(x))
+#endif
+
+#ifndef N_TXTADDR
+#define N_TXTADDR(x) (N_MAGIC(x) == QMAGIC ? PAGE_SIZE : 0)
+#endif
+
+#if defined(vax) || defined(hp300) || defined(pyr)
+#define SEGMENT_SIZE page_size
+#endif
+#ifdef sony
+#define SEGMENT_SIZE 0x2000
+#endif
+#ifdef is68k
+#define SEGMENT_SIZE 0x20000
+#endif
+#if defined(m68k) && defined(PORTAR)
+#define PAGE_SIZE 0x400
+#define SEGMENT_SIZE PAGE_SIZE
+#endif
+
+#ifdef linux
+#include
+#if defined(__i386__) || defined(__mc68000__)
+#define SEGMENT_SIZE 1024
+#else
+#ifndef SEGMENT_SIZE
+#define SEGMENT_SIZE PAGE_SIZE
+#endif
+#endif
+#endif
+
+#define _N_SEGMENT_ROUND(x) ALIGN(x, SEGMENT_SIZE)
+
+#define _N_TXTENDADDR(x) (N_TXTADDR(x)+(x).a_text)
+
+#ifndef N_DATADDR
+#define N_DATADDR(x) (N_MAGIC(x)==OMAGIC? (_N_TXTENDADDR(x)) : (_N_SEGMENT_ROUND (_N_TXTENDADDR(x))))
+#endif
+
+#ifndef N_BSSADDR
+#define N_BSSADDR(x) (N_DATADDR(x) + (x).a_data)
+#endif
+
+#ifndef N_NLIST_DECLARED
+struct nlist {
+ union {
+ char *n_name;
+ struct nlist *n_next;
+ long n_strx;
+ } n_un;
+ unsigned char n_type;
+ char n_other;
+ short n_desc;
+ unsigned long n_value;
+};
+#endif
+
+#ifndef N_UNDF
+#define N_UNDF 0
+#endif
+#ifndef N_ABS
+#define N_ABS 2
+#endif
+#ifndef N_TEXT
+#define N_TEXT 4
+#endif
+#ifndef N_DATA
+#define N_DATA 6
+#endif
+#ifndef N_BSS
+#define N_BSS 8
+#endif
+#ifndef N_FN
+#define N_FN 15
+#endif
+
+#ifndef N_EXT
+#define N_EXT 1
+#endif
+#ifndef N_TYPE
+#define N_TYPE 036
+#endif
+#ifndef N_STAB
+#define N_STAB 0340
+#endif
+
+#define N_INDR 0xa
+
+#define N_SETA 0x14
+#define N_SETT 0x16
+#define N_SETD 0x18
+#define N_SETB 0x1A
+
+#define N_SETV 0x1C
+
+#ifndef N_RELOCATION_INFO_DECLARED
+
+struct relocation_info
+{
+
+ int r_address;
+
+ unsigned int r_symbolnum:24;
+
+ unsigned int r_pcrel:1;
+
+ unsigned int r_length:2;
+
+ unsigned int r_extern:1;
+
+#ifdef NS32K
+ unsigned r_bsr:1;
+ unsigned r_disp:1;
+ unsigned r_pad:2;
+#else
+ unsigned int r_pad:4;
+#endif
+};
+#endif
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/aio_abi.h b/ndk/build/platforms/android-1.5/common/include/linux/aio_abi.h
new file mode 100644
index 000000000..c92bc8f11
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/aio_abi.h
@@ -0,0 +1,64 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __LINUX__AIO_ABI_H
+#define __LINUX__AIO_ABI_H
+
+#include
+
+typedef unsigned long aio_context_t;
+
+enum {
+ IOCB_CMD_PREAD = 0,
+ IOCB_CMD_PWRITE = 1,
+ IOCB_CMD_FSYNC = 2,
+ IOCB_CMD_FDSYNC = 3,
+
+ IOCB_CMD_NOOP = 6,
+};
+
+struct io_event {
+ __u64 data;
+ __u64 obj;
+ __s64 res;
+ __s64 res2;
+};
+
+#ifdef __LITTLE_ENDIAN
+#define PADDED(x,y) x, y
+#elif defined(__BIG_ENDIAN)
+#define PADDED(x,y) y, x
+#else
+#error edit for your odd byteorder.
+#endif
+
+struct iocb {
+
+ __u64 aio_data;
+ __u32 PADDED(aio_key, aio_reserved1);
+
+ __u16 aio_lio_opcode;
+ __s16 aio_reqprio;
+ __u32 aio_fildes;
+
+ __u64 aio_buf;
+ __u64 aio_nbytes;
+ __s64 aio_offset;
+
+ __u64 aio_reserved2;
+ __u64 aio_reserved3;
+};
+
+#undef IFBIG
+#undef IFLITTLE
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/akm8976.h b/ndk/build/platforms/android-1.5/common/include/linux/akm8976.h
new file mode 100644
index 000000000..a5aa68ea5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/akm8976.h
@@ -0,0 +1,89 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef AKM8976_H
+#define AKM8976_H
+
+#include
+
+#define AKECS_MODE_MEASURE 0x00
+
+#define AKECS_MODE_PFFD 0x01
+#define AKECS_MODE_E2P_READ 0x02
+#define AKECS_MODE_POWERDOWN 0x03
+
+#define AKECS_MODE_MEASURE_SNG 0x10
+#define AKECS_MODE_MEASURE_SEQ 0x11
+
+#define CSPEC_AINT 0x01
+#define CSPEC_SNG_NUM 0x01
+#define CSPEC_SEQ_NUM 0x02
+#define CSPEC_SFRQ_32 0x00
+#define CSPEC_SFRQ_64 0x01
+#define CSPEC_MCS 0x07
+#define CSPEC_MKS 0x01
+#define CSPEC_INTEN 0x01
+
+#define RBUFF_SIZE 31
+#define MAX_CALI_SIZE 0x1000U
+
+#define AKECS_REG_ST 0xC0
+#define AKECS_REG_TMPS 0xC1
+#define AKECS_REG_MS1 0xE0
+#define AKECS_REG_MS2 0xE1
+#define AKECS_REG_MS3 0xE2
+
+#define AKMIO 0xA1
+
+#define ECS_IOCTL_INIT _IO(AKMIO, 0x01)
+#define ECS_IOCTL_WRITE _IOW(AKMIO, 0x02, char[5])
+#define ECS_IOCTL_READ _IOWR(AKMIO, 0x03, char[5])
+#define ECS_IOCTL_RESET _IO(AKMIO, 0x04)
+#define ECS_IOCTL_INT_STATUS _IO(AKMIO, 0x05)
+#define ECS_IOCTL_FFD_STATUS _IO(AKMIO, 0x06)
+#define ECS_IOCTL_SET_MODE _IOW(AKMIO, 0x07, short)
+#define ECS_IOCTL_GETDATA _IOR(AKMIO, 0x08, char[RBUFF_SIZE+1])
+#define ECS_IOCTL_GET_NUMFRQ _IOR(AKMIO, 0x09, char[2])
+#define ECS_IOCTL_SET_PERST _IO(AKMIO, 0x0A)
+#define ECS_IOCTL_SET_G0RST _IO(AKMIO, 0x0B)
+#define ECS_IOCTL_SET_YPR _IOW(AKMIO, 0x0C, short[12])
+#define ECS_IOCTL_GET_OPEN_STATUS _IOR(AKMIO, 0x0D, int)
+#define ECS_IOCTL_GET_CLOSE_STATUS _IOR(AKMIO, 0x0E, int)
+#define ECS_IOCTL_GET_CALI_DATA _IOR(AKMIO, 0x0F, char[MAX_CALI_SIZE])
+#define ECS_IOCTL_GET_DELAY _IOR(AKMIO, 0x30, short)
+
+#define ECS_IOCTL_APP_SET_MODE _IOW(AKMIO, 0x10, short)
+#define ECS_IOCTL_APP_SET_MFLAG _IOW(AKMIO, 0x11, short)
+#define ECS_IOCTL_APP_GET_MFLAG _IOW(AKMIO, 0x12, short)
+#define ECS_IOCTL_APP_SET_AFLAG _IOW(AKMIO, 0x13, short)
+#define ECS_IOCTL_APP_GET_AFLAG _IOR(AKMIO, 0x14, short)
+#define ECS_IOCTL_APP_SET_TFLAG _IOR(AKMIO, 0x15, short)
+#define ECS_IOCTL_APP_GET_TFLAG _IOR(AKMIO, 0x16, short)
+#define ECS_IOCTL_APP_RESET_PEDOMETER _IO(AKMIO, 0x17)
+#define ECS_IOCTL_APP_SET_DELAY _IOW(AKMIO, 0x18, short)
+#define ECS_IOCTL_APP_GET_DELAY ECS_IOCTL_GET_DELAY
+#define ECS_IOCTL_APP_SET_MVFLAG _IOW(AKMIO, 0x19, short)
+#define ECS_IOCTL_APP_GET_MVFLAG _IOR(AKMIO, 0x1A, short)
+
+#define ECS_IOCTL_SET_STEP_CNT _IOW(AKMIO, 0x20, short)
+
+#define ECS_RST 146
+#define ECS_CLK_ON 155
+#define ECS_INTR 161
+
+struct akm8976_platform_data {
+ int reset;
+ int clk_on;
+ int intr;
+};
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/android_alarm.h b/ndk/build/platforms/android-1.5/common/include/linux/android_alarm.h
new file mode 100644
index 000000000..80828eab4
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/android_alarm.h
@@ -0,0 +1,50 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ANDROID_ALARM_H
+#define _LINUX_ANDROID_ALARM_H
+
+#include
+#include
+
+typedef enum {
+
+ ANDROID_ALARM_RTC_WAKEUP,
+ ANDROID_ALARM_RTC,
+ ANDROID_ALARM_ELAPSED_REALTIME_WAKEUP,
+ ANDROID_ALARM_ELAPSED_REALTIME,
+ ANDROID_ALARM_SYSTEMTIME,
+
+ ANDROID_ALARM_TYPE_COUNT,
+
+} android_alarm_type_t;
+
+typedef enum {
+ ANDROID_ALARM_RTC_WAKEUP_MASK = 1U << ANDROID_ALARM_RTC_WAKEUP,
+ ANDROID_ALARM_RTC_MASK = 1U << ANDROID_ALARM_RTC,
+ ANDROID_ALARM_ELAPSED_REALTIME_WAKEUP_MASK = 1U << ANDROID_ALARM_ELAPSED_REALTIME_WAKEUP,
+ ANDROID_ALARM_ELAPSED_REALTIME_MASK = 1U << ANDROID_ALARM_ELAPSED_REALTIME,
+ ANDROID_ALARM_SYSTEMTIME_MASK = 1U << ANDROID_ALARM_SYSTEMTIME,
+ ANDROID_ALARM_TIME_CHANGE_MASK = 1U << 16
+} android_alarm_return_flags_t;
+
+#define ANDROID_ALARM_CLEAR(type) _IO('a', 0 | ((type) << 4))
+#define ANDROID_ALARM_WAIT _IO('a', 1)
+#define ANDROID_ALARM_SET(type) _IOW('a', 2 | ((type) << 4), struct timespec)
+#define ANDROID_ALARM_SET_AND_WAIT(type) _IOW('a', 3 | ((type) << 4), struct timespec)
+#define ANDROID_ALARM_GET_TIME(type) _IOW('a', 4 | ((type) << 4), struct timespec)
+#define ANDROID_ALARM_SET_RTC _IOW('a', 5, struct timespec)
+#define ANDROID_ALARM_SET_TIMEZONE _IOW('a', 6, struct timezone)
+
+#define ANDROID_ALARM_BASE_CMD(cmd) (cmd & ~(_IOC(0, 0, 0xf0, 0)))
+#define ANDROID_ALARM_IOCTL_TO_TYPE(cmd) (_IOC_NR(cmd) >> 4)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/android_pmem.h b/ndk/build/platforms/android-1.5/common/include/linux/android_pmem.h
new file mode 100644
index 000000000..858857ef1
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/android_pmem.h
@@ -0,0 +1,52 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ANDROID_PMEM_H_
+#define _ANDROID_PMEM_H_
+
+#include
+
+#ifndef __user
+#define __user
+#endif
+
+struct pmem_region {
+ unsigned long offset;
+ unsigned long len;
+};
+
+#define PMEM_IOCTL_MAGIC 'p'
+#define PMEM_GET_PHYS _IOW(PMEM_IOCTL_MAGIC, 1, struct pmem_region *)
+#define PMEM_MAP _IOW(PMEM_IOCTL_MAGIC, 2, struct pmem_region *)
+#define PMEM_GET_SIZE _IOW(PMEM_IOCTL_MAGIC, 3, struct pmem_region *)
+#define PMEM_UNMAP _IOW(PMEM_IOCTL_MAGIC, 4, struct pmem_region *)
+
+#define PMEM_ALLOCATE _IOW(PMEM_IOCTL_MAGIC, 5, unsigned int)
+
+#define PMEM_CONNECT _IOW(PMEM_IOCTL_MAGIC, 6, unsigned int)
+
+#define PMEM_GET_TOTAL_SIZE _IOW(PMEM_IOCTL_MAGIC, 7, struct pmem_region *)
+
+#define HW3D_REVOKE_GPU _IOW(PMEM_IOCTL_MAGIC, 8, unsigned int)
+#define HW3D_GRANT_GPU _IOW(PMEM_IOCTL_MAGIC, 9, unsigned int)
+#define HW3D_WAIT_IRQ _IOW(PMEM_IOCTL_MAGIC,10, unsigned int)
+
+struct android_pmem_platform_data;
+struct pmem_file_operations {
+ int (*mmap) (struct file *, struct vm_area_struct *);
+ int (*open) (struct inode *, struct file *);
+ ssize_t (*read) (struct file *, char __user *, size_t, long long *);
+ int (*release) (struct inode *, struct file *);
+ long (*ioctl) (struct file *, unsigned int, unsigned long);
+};
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/android_power.h b/ndk/build/platforms/android-1.5/common/include/linux/android_power.h
new file mode 100644
index 000000000..2e9032176
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/android_power.h
@@ -0,0 +1,55 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ANDROID_POWER_H
+#define _LINUX_ANDROID_POWER_H
+
+#include
+
+typedef struct
+{
+ struct list_head link;
+ int lock_count;
+ int flags;
+ const char *name;
+ int expires;
+} android_suspend_lock_t;
+
+#define ANDROID_SUSPEND_LOCK_FLAG_COUNTED (1U << 0)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_READABLE (1U << 1)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_SET (1U << 2)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_CLEAR (1U << 3)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_INC (1U << 4)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_DEC (1U << 5)
+#define ANDROID_SUSPEND_LOCK_FLAG_USER_VISIBLE_MASK (0x1fU << 1)
+#define ANDROID_SUSPEND_LOCK_AUTO_EXPIRE (1U << 6)
+
+typedef struct android_early_suspend android_early_suspend_t;
+struct android_early_suspend
+{
+ struct list_head link;
+ int level;
+ void (*suspend)(android_early_suspend_t *h);
+ void (*resume)(android_early_suspend_t *h);
+};
+
+typedef enum {
+ ANDROID_CHARGING_STATE_UNKNOWN,
+ ANDROID_CHARGING_STATE_DISCHARGE,
+ ANDROID_CHARGING_STATE_MAINTAIN,
+ ANDROID_CHARGING_STATE_SLOW,
+ ANDROID_CHARGING_STATE_NORMAL,
+ ANDROID_CHARGING_STATE_FAST,
+ ANDROID_CHARGING_STATE_OVERHEAT
+} android_charging_state_t;
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/apm_bios.h b/ndk/build/platforms/android-1.5/common/include/linux/apm_bios.h
new file mode 100644
index 000000000..d32b4aac6
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/apm_bios.h
@@ -0,0 +1,94 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_APM_H
+#define _LINUX_APM_H
+
+typedef unsigned short apm_event_t;
+typedef unsigned short apm_eventinfo_t;
+
+#define APM_STATE_READY 0x0000
+#define APM_STATE_STANDBY 0x0001
+#define APM_STATE_SUSPEND 0x0002
+#define APM_STATE_OFF 0x0003
+#define APM_STATE_BUSY 0x0004
+#define APM_STATE_REJECT 0x0005
+#define APM_STATE_OEM_SYS 0x0020
+#define APM_STATE_OEM_DEV 0x0040
+
+#define APM_STATE_DISABLE 0x0000
+#define APM_STATE_ENABLE 0x0001
+
+#define APM_STATE_DISENGAGE 0x0000
+#define APM_STATE_ENGAGE 0x0001
+
+#define APM_SYS_STANDBY 0x0001
+#define APM_SYS_SUSPEND 0x0002
+#define APM_NORMAL_RESUME 0x0003
+#define APM_CRITICAL_RESUME 0x0004
+#define APM_LOW_BATTERY 0x0005
+#define APM_POWER_STATUS_CHANGE 0x0006
+#define APM_UPDATE_TIME 0x0007
+#define APM_CRITICAL_SUSPEND 0x0008
+#define APM_USER_STANDBY 0x0009
+#define APM_USER_SUSPEND 0x000a
+#define APM_STANDBY_RESUME 0x000b
+#define APM_CAPABILITY_CHANGE 0x000c
+
+#define APM_SUCCESS 0x00
+#define APM_DISABLED 0x01
+#define APM_CONNECTED 0x02
+#define APM_NOT_CONNECTED 0x03
+#define APM_16_CONNECTED 0x05
+#define APM_16_UNSUPPORTED 0x06
+#define APM_32_CONNECTED 0x07
+#define APM_32_UNSUPPORTED 0x08
+#define APM_BAD_DEVICE 0x09
+#define APM_BAD_PARAM 0x0a
+#define APM_NOT_ENGAGED 0x0b
+#define APM_BAD_FUNCTION 0x0c
+#define APM_RESUME_DISABLED 0x0d
+#define APM_NO_ERROR 0x53
+#define APM_BAD_STATE 0x60
+#define APM_NO_EVENTS 0x80
+#define APM_NOT_PRESENT 0x86
+
+#define APM_DEVICE_BIOS 0x0000
+#define APM_DEVICE_ALL 0x0001
+#define APM_DEVICE_DISPLAY 0x0100
+#define APM_DEVICE_STORAGE 0x0200
+#define APM_DEVICE_PARALLEL 0x0300
+#define APM_DEVICE_SERIAL 0x0400
+#define APM_DEVICE_NETWORK 0x0500
+#define APM_DEVICE_PCMCIA 0x0600
+#define APM_DEVICE_BATTERY 0x8000
+#define APM_DEVICE_OEM 0xe000
+#define APM_DEVICE_OLD_ALL 0xffff
+#define APM_DEVICE_CLASS 0x00ff
+#define APM_DEVICE_MASK 0xff00
+
+#define APM_MAX_BATTERIES 2
+
+#define APM_CAP_GLOBAL_STANDBY 0x0001
+#define APM_CAP_GLOBAL_SUSPEND 0x0002
+#define APM_CAP_RESUME_STANDBY_TIMER 0x0004
+#define APM_CAP_RESUME_SUSPEND_TIMER 0x0008
+#define APM_CAP_RESUME_STANDBY_RING 0x0010
+#define APM_CAP_RESUME_SUSPEND_RING 0x0020
+#define APM_CAP_RESUME_STANDBY_PCMCIA 0x0040
+#define APM_CAP_RESUME_SUSPEND_PCMCIA 0x0080
+
+#include
+
+#define APM_IOC_STANDBY _IO('A', 1)
+#define APM_IOC_SUSPEND _IO('A', 2)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/ashmem.h b/ndk/build/platforms/android-1.5/common/include/linux/ashmem.h
new file mode 100644
index 000000000..a57d1dee3
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/ashmem.h
@@ -0,0 +1,46 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ASHMEM_H
+#define _LINUX_ASHMEM_H
+
+#include
+#include
+
+#define ASHMEM_NAME_LEN 256
+
+#define ASHMEM_NAME_DEF "dev/ashmem"
+
+#define ASHMEM_NOT_PURGED 0
+#define ASHMEM_WAS_PURGED 1
+
+#define ASHMEM_IS_UNPINNED 0
+#define ASHMEM_IS_PINNED 1
+
+struct ashmem_pin {
+ __u32 offset;
+ __u32 len;
+};
+
+#define __ASHMEMIOC 0x77
+
+#define ASHMEM_SET_NAME _IOW(__ASHMEMIOC, 1, char[ASHMEM_NAME_LEN])
+#define ASHMEM_GET_NAME _IOR(__ASHMEMIOC, 2, char[ASHMEM_NAME_LEN])
+#define ASHMEM_SET_SIZE _IOW(__ASHMEMIOC, 3, size_t)
+#define ASHMEM_GET_SIZE _IO(__ASHMEMIOC, 4)
+#define ASHMEM_SET_PROT_MASK _IOW(__ASHMEMIOC, 5, unsigned long)
+#define ASHMEM_GET_PROT_MASK _IO(__ASHMEMIOC, 6)
+#define ASHMEM_PIN _IOW(__ASHMEMIOC, 7, struct ashmem_pin)
+#define ASHMEM_UNPIN _IOW(__ASHMEMIOC, 8, struct ashmem_pin)
+#define ASHMEM_GET_PIN_STATUS _IO(__ASHMEMIOC, 9)
+#define ASHMEM_PURGE_ALL_CACHES _IO(__ASHMEMIOC, 10)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/ata.h b/ndk/build/platforms/android-1.5/common/include/linux/ata.h
new file mode 100644
index 000000000..76af57627
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/ata.h
@@ -0,0 +1,265 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __LINUX_ATA_H__
+#define __LINUX_ATA_H__
+
+#include
+
+#define ATA_DMA_BOUNDARY 0xffffUL
+#define ATA_DMA_MASK 0xffffffffULL
+
+enum {
+
+ ATA_MAX_DEVICES = 2,
+ ATA_MAX_PRD = 256,
+ ATA_SECT_SIZE = 512,
+
+ ATA_ID_WORDS = 256,
+ ATA_ID_SERNO_OFS = 10,
+ ATA_ID_FW_REV_OFS = 23,
+ ATA_ID_PROD_OFS = 27,
+ ATA_ID_OLD_PIO_MODES = 51,
+ ATA_ID_FIELD_VALID = 53,
+ ATA_ID_MWDMA_MODES = 63,
+ ATA_ID_PIO_MODES = 64,
+ ATA_ID_EIDE_DMA_MIN = 65,
+ ATA_ID_EIDE_PIO = 67,
+ ATA_ID_EIDE_PIO_IORDY = 68,
+ ATA_ID_UDMA_MODES = 88,
+ ATA_ID_MAJOR_VER = 80,
+ ATA_ID_PIO4 = (1 << 1),
+
+ ATA_PCI_CTL_OFS = 2,
+ ATA_SERNO_LEN = 20,
+ ATA_UDMA0 = (1 << 0),
+ ATA_UDMA1 = ATA_UDMA0 | (1 << 1),
+ ATA_UDMA2 = ATA_UDMA1 | (1 << 2),
+ ATA_UDMA3 = ATA_UDMA2 | (1 << 3),
+ ATA_UDMA4 = ATA_UDMA3 | (1 << 4),
+ ATA_UDMA5 = ATA_UDMA4 | (1 << 5),
+ ATA_UDMA6 = ATA_UDMA5 | (1 << 6),
+ ATA_UDMA7 = ATA_UDMA6 | (1 << 7),
+
+ ATA_UDMA_MASK_40C = ATA_UDMA2,
+
+ ATA_PRD_SZ = 8,
+ ATA_PRD_TBL_SZ = (ATA_MAX_PRD * ATA_PRD_SZ),
+ ATA_PRD_EOT = (1 << 31),
+
+ ATA_DMA_TABLE_OFS = 4,
+ ATA_DMA_STATUS = 2,
+ ATA_DMA_CMD = 0,
+ ATA_DMA_WR = (1 << 3),
+ ATA_DMA_START = (1 << 0),
+ ATA_DMA_INTR = (1 << 2),
+ ATA_DMA_ERR = (1 << 1),
+ ATA_DMA_ACTIVE = (1 << 0),
+
+ ATA_HOB = (1 << 7),
+ ATA_NIEN = (1 << 1),
+ ATA_LBA = (1 << 6),
+ ATA_DEV1 = (1 << 4),
+ ATA_DEVICE_OBS = (1 << 7) | (1 << 5),
+ ATA_DEVCTL_OBS = (1 << 3),
+ ATA_BUSY = (1 << 7),
+ ATA_DRDY = (1 << 6),
+ ATA_DF = (1 << 5),
+ ATA_DRQ = (1 << 3),
+ ATA_ERR = (1 << 0),
+ ATA_SRST = (1 << 2),
+ ATA_ICRC = (1 << 7),
+ ATA_UNC = (1 << 6),
+ ATA_IDNF = (1 << 4),
+ ATA_ABORTED = (1 << 2),
+
+ ATA_REG_DATA = 0x00,
+ ATA_REG_ERR = 0x01,
+ ATA_REG_NSECT = 0x02,
+ ATA_REG_LBAL = 0x03,
+ ATA_REG_LBAM = 0x04,
+ ATA_REG_LBAH = 0x05,
+ ATA_REG_DEVICE = 0x06,
+ ATA_REG_STATUS = 0x07,
+
+ ATA_REG_FEATURE = ATA_REG_ERR,
+ ATA_REG_CMD = ATA_REG_STATUS,
+ ATA_REG_BYTEL = ATA_REG_LBAM,
+ ATA_REG_BYTEH = ATA_REG_LBAH,
+ ATA_REG_DEVSEL = ATA_REG_DEVICE,
+ ATA_REG_IRQ = ATA_REG_NSECT,
+
+ ATA_CMD_CHK_POWER = 0xE5,
+ ATA_CMD_STANDBY = 0xE2,
+ ATA_CMD_IDLE = 0xE3,
+ ATA_CMD_EDD = 0x90,
+ ATA_CMD_FLUSH = 0xE7,
+ ATA_CMD_FLUSH_EXT = 0xEA,
+ ATA_CMD_ID_ATA = 0xEC,
+ ATA_CMD_ID_ATAPI = 0xA1,
+ ATA_CMD_READ = 0xC8,
+ ATA_CMD_READ_EXT = 0x25,
+ ATA_CMD_WRITE = 0xCA,
+ ATA_CMD_WRITE_EXT = 0x35,
+ ATA_CMD_WRITE_FUA_EXT = 0x3D,
+ ATA_CMD_FPDMA_READ = 0x60,
+ ATA_CMD_FPDMA_WRITE = 0x61,
+ ATA_CMD_PIO_READ = 0x20,
+ ATA_CMD_PIO_READ_EXT = 0x24,
+ ATA_CMD_PIO_WRITE = 0x30,
+ ATA_CMD_PIO_WRITE_EXT = 0x34,
+ ATA_CMD_READ_MULTI = 0xC4,
+ ATA_CMD_READ_MULTI_EXT = 0x29,
+ ATA_CMD_WRITE_MULTI = 0xC5,
+ ATA_CMD_WRITE_MULTI_EXT = 0x39,
+ ATA_CMD_WRITE_MULTI_FUA_EXT = 0xCE,
+ ATA_CMD_SET_FEATURES = 0xEF,
+ ATA_CMD_PACKET = 0xA0,
+ ATA_CMD_VERIFY = 0x40,
+ ATA_CMD_VERIFY_EXT = 0x42,
+ ATA_CMD_STANDBYNOW1 = 0xE0,
+ ATA_CMD_IDLEIMMEDIATE = 0xE1,
+ ATA_CMD_INIT_DEV_PARAMS = 0x91,
+ ATA_CMD_READ_NATIVE_MAX = 0xF8,
+ ATA_CMD_READ_NATIVE_MAX_EXT = 0x27,
+ ATA_CMD_READ_LOG_EXT = 0x2f,
+
+ ATA_LOG_SATA_NCQ = 0x10,
+
+ SETFEATURES_XFER = 0x03,
+ XFER_UDMA_7 = 0x47,
+ XFER_UDMA_6 = 0x46,
+ XFER_UDMA_5 = 0x45,
+ XFER_UDMA_4 = 0x44,
+ XFER_UDMA_3 = 0x43,
+ XFER_UDMA_2 = 0x42,
+ XFER_UDMA_1 = 0x41,
+ XFER_UDMA_0 = 0x40,
+ XFER_MW_DMA_2 = 0x22,
+ XFER_MW_DMA_1 = 0x21,
+ XFER_MW_DMA_0 = 0x20,
+ XFER_SW_DMA_2 = 0x12,
+ XFER_SW_DMA_1 = 0x11,
+ XFER_SW_DMA_0 = 0x10,
+ XFER_PIO_4 = 0x0C,
+ XFER_PIO_3 = 0x0B,
+ XFER_PIO_2 = 0x0A,
+ XFER_PIO_1 = 0x09,
+ XFER_PIO_0 = 0x08,
+ XFER_PIO_SLOW = 0x00,
+
+ SETFEATURES_WC_ON = 0x02,
+ SETFEATURES_WC_OFF = 0x82,
+
+ ATAPI_PKT_DMA = (1 << 0),
+ ATAPI_DMADIR = (1 << 2),
+ ATAPI_CDB_LEN = 16,
+
+ ATA_CBL_NONE = 0,
+ ATA_CBL_PATA40 = 1,
+ ATA_CBL_PATA80 = 2,
+ ATA_CBL_PATA_UNK = 3,
+ ATA_CBL_SATA = 4,
+
+ SCR_STATUS = 0,
+ SCR_ERROR = 1,
+ SCR_CONTROL = 2,
+ SCR_ACTIVE = 3,
+ SCR_NOTIFICATION = 4,
+
+ SERR_DATA_RECOVERED = (1 << 0),
+ SERR_COMM_RECOVERED = (1 << 1),
+ SERR_DATA = (1 << 8),
+ SERR_PERSISTENT = (1 << 9),
+ SERR_PROTOCOL = (1 << 10),
+ SERR_INTERNAL = (1 << 11),
+ SERR_PHYRDY_CHG = (1 << 16),
+ SERR_DEV_XCHG = (1 << 26),
+
+ ATA_TFLAG_LBA48 = (1 << 0),
+ ATA_TFLAG_ISADDR = (1 << 1),
+ ATA_TFLAG_DEVICE = (1 << 2),
+ ATA_TFLAG_WRITE = (1 << 3),
+ ATA_TFLAG_LBA = (1 << 4),
+ ATA_TFLAG_FUA = (1 << 5),
+ ATA_TFLAG_POLLING = (1 << 6),
+};
+
+enum ata_tf_protocols {
+
+ ATA_PROT_UNKNOWN,
+ ATA_PROT_NODATA,
+ ATA_PROT_PIO,
+ ATA_PROT_DMA,
+ ATA_PROT_NCQ,
+ ATA_PROT_ATAPI,
+ ATA_PROT_ATAPI_NODATA,
+ ATA_PROT_ATAPI_DMA,
+};
+
+enum ata_ioctls {
+ ATA_IOC_GET_IO32 = 0x309,
+ ATA_IOC_SET_IO32 = 0x324,
+};
+
+struct ata_prd {
+ u32 addr;
+ u32 flags_len;
+};
+
+struct ata_taskfile {
+ unsigned long flags;
+ u8 protocol;
+
+ u8 ctl;
+
+ u8 hob_feature;
+ u8 hob_nsect;
+ u8 hob_lbal;
+ u8 hob_lbam;
+ u8 hob_lbah;
+
+ u8 feature;
+ u8 nsect;
+ u8 lbal;
+ u8 lbam;
+ u8 lbah;
+
+ u8 device;
+
+ u8 command;
+};
+
+#define ata_id_is_ata(id) (((id)[0] & (1 << 15)) == 0)
+#define ata_id_is_cfa(id) ((id)[0] == 0x848A)
+#define ata_id_is_sata(id) ((id)[93] == 0)
+#define ata_id_rahead_enabled(id) ((id)[85] & (1 << 6))
+#define ata_id_wcache_enabled(id) ((id)[85] & (1 << 5))
+#define ata_id_hpa_enabled(id) ((id)[85] & (1 << 10))
+#define ata_id_has_fua(id) ((id)[84] & (1 << 6))
+#define ata_id_has_flush(id) ((id)[83] & (1 << 12))
+#define ata_id_has_flush_ext(id) ((id)[83] & (1 << 13))
+#define ata_id_has_lba48(id) ((id)[83] & (1 << 10))
+#define ata_id_has_hpa(id) ((id)[82] & (1 << 10))
+#define ata_id_has_wcache(id) ((id)[82] & (1 << 5))
+#define ata_id_has_pm(id) ((id)[82] & (1 << 3))
+#define ata_id_has_lba(id) ((id)[49] & (1 << 9))
+#define ata_id_has_dma(id) ((id)[49] & (1 << 8))
+#define ata_id_has_ncq(id) ((id)[76] & (1 << 8))
+#define ata_id_queue_depth(id) (((id)[75] & 0x1f) + 1)
+#define ata_id_removeable(id) ((id)[0] & (1 << 7))
+#define ata_id_has_dword_io(id) ((id)[50] & (1 << 0))
+#define ata_id_u32(id,n) (((u32) (id)[(n) + 1] << 16) | ((u32) (id)[(n)]))
+#define ata_id_u64(id,n) ( ((u64) (id)[(n) + 3] << 48) | ((u64) (id)[(n) + 2] << 32) | ((u64) (id)[(n) + 1] << 16) | ((u64) (id)[(n) + 0]) )
+
+#define ata_id_cdb_intr(id) (((id)[0] & 0x60) == 0x20)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atm.h b/ndk/build/platforms/android-1.5/common/include/linux/atm.h
new file mode 100644
index 000000000..c9bcd702f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atm.h
@@ -0,0 +1,161 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ATM_H
+#define _LINUX_ATM_H
+
+#include
+#include
+#include
+#include
+
+#define ATM_CELL_SIZE 53
+#define ATM_CELL_PAYLOAD 48
+#define ATM_AAL0_SDU 52
+#define ATM_MAX_AAL34_PDU 65535
+#define ATM_AAL5_TRAILER 8
+#define ATM_MAX_AAL5_PDU 65535
+#define ATM_MAX_CDV 9999
+#define ATM_NOT_RSV_VCI 32
+
+#define ATM_MAX_VPI 255
+#define ATM_MAX_VPI_NNI 4096
+#define ATM_MAX_VCI 65535
+
+#define ATM_NO_AAL 0
+#define ATM_AAL0 13
+#define ATM_AAL1 1
+#define ATM_AAL2 2
+#define ATM_AAL34 3
+#define ATM_AAL5 5
+
+#define __SO_ENCODE(l,n,t) ((((l) & 0x1FF) << 22) | ((n) << 16) | sizeof(t))
+#define __SO_LEVEL_MATCH(c,m) (((c) >> 22) == ((m) & 0x1FF))
+#define __SO_NUMBER(c) (((c) >> 16) & 0x3f)
+#define __SO_SIZE(c) ((c) & 0x3fff)
+
+#define SO_SETCLP __SO_ENCODE(SOL_ATM,0,int)
+
+#define SO_CIRANGE __SO_ENCODE(SOL_ATM,1,struct atm_cirange)
+
+#define SO_ATMQOS __SO_ENCODE(SOL_ATM,2,struct atm_qos)
+
+#define SO_ATMSAP __SO_ENCODE(SOL_ATM,3,struct atm_sap)
+
+#define SO_ATMPVC __SO_ENCODE(SOL_ATM,4,struct sockaddr_atmpvc)
+
+#define SO_MULTIPOINT __SO_ENCODE(SOL_ATM, 5, int)
+
+#define ATM_HDR_GFC_MASK 0xf0000000
+#define ATM_HDR_GFC_SHIFT 28
+#define ATM_HDR_VPI_MASK 0x0ff00000
+#define ATM_HDR_VPI_SHIFT 20
+#define ATM_HDR_VCI_MASK 0x000ffff0
+#define ATM_HDR_VCI_SHIFT 4
+#define ATM_HDR_PTI_MASK 0x0000000e
+#define ATM_HDR_PTI_SHIFT 1
+#define ATM_HDR_CLP 0x00000001
+
+#define ATM_PTI_US0 0
+#define ATM_PTI_US1 1
+#define ATM_PTI_UCES0 2
+#define ATM_PTI_UCES1 3
+#define ATM_PTI_SEGF5 4
+#define ATM_PTI_E2EF5 5
+#define ATM_PTI_RSV_RM 6
+#define ATM_PTI_RSV 7
+
+#define ATM_NONE 0
+#define ATM_UBR 1
+#define ATM_CBR 2
+#define ATM_VBR 3
+#define ATM_ABR 4
+#define ATM_ANYCLASS 5
+
+#define ATM_MAX_PCR -1
+
+struct atm_trafprm {
+ unsigned char traffic_class;
+ int max_pcr;
+ int pcr;
+ int min_pcr;
+ int max_cdv;
+ int max_sdu;
+
+ unsigned int icr;
+ unsigned int tbe;
+ unsigned int frtt : 24;
+ unsigned int rif : 4;
+ unsigned int rdf : 4;
+ unsigned int nrm_pres :1;
+ unsigned int trm_pres :1;
+ unsigned int adtf_pres :1;
+ unsigned int cdf_pres :1;
+ unsigned int nrm :3;
+ unsigned int trm :3;
+ unsigned int adtf :10;
+ unsigned int cdf :3;
+ unsigned int spare :9;
+};
+
+struct atm_qos {
+ struct atm_trafprm txtp;
+ struct atm_trafprm rxtp __ATM_API_ALIGN;
+
+ unsigned char aal __ATM_API_ALIGN;
+};
+
+#define ATM_ITF_ANY -1
+#define ATM_VPI_ANY -1
+#define ATM_VCI_ANY -1
+#define ATM_VPI_UNSPEC -2
+#define ATM_VCI_UNSPEC -2
+
+struct sockaddr_atmpvc {
+ unsigned short sap_family;
+ struct {
+ short itf;
+ short vpi;
+ int vci;
+ } sap_addr __ATM_API_ALIGN;
+};
+
+#define ATM_ESA_LEN 20
+#define ATM_E164_LEN 12
+
+#define ATM_AFI_DCC 0x39
+#define ATM_AFI_ICD 0x47
+#define ATM_AFI_E164 0x45
+#define ATM_AFI_LOCAL 0x49
+
+#define ATM_AFI_DCC_GROUP 0xBD
+#define ATM_AFI_ICD_GROUP 0xC5
+#define ATM_AFI_E164_GROUP 0xC3
+#define ATM_AFI_LOCAL_GROUP 0xC7
+
+#define ATM_LIJ_NONE 0
+#define ATM_LIJ 1
+#define ATM_LIJ_RPJ 2
+#define ATM_LIJ_NJ 3
+
+struct sockaddr_atmsvc {
+ unsigned short sas_family;
+ struct {
+ unsigned char prv[ATM_ESA_LEN];
+ char pub[ATM_E164_LEN+1];
+
+ char lij_type;
+ uint32_t lij_id;
+ } sas_addr __ATM_API_ALIGN;
+};
+
+typedef unsigned short atm_backend_t;
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atmapi.h b/ndk/build/platforms/android-1.5/common/include/linux/atmapi.h
new file mode 100644
index 000000000..bee5cae1d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atmapi.h
@@ -0,0 +1,24 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ATMAPI_H
+#define _LINUX_ATMAPI_H
+
+#if defined(__sparc__) || defined(__ia64__)
+
+#define __ATM_API_ALIGN __attribute__((aligned(8)))
+#else
+#define __ATM_API_ALIGN
+#endif
+
+typedef struct { unsigned char _[8]; } __ATM_API_ALIGN atm_kptr_t;
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atmdev.h b/ndk/build/platforms/android-1.5/common/include/linux/atmdev.h
new file mode 100644
index 000000000..27baeb01f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atmdev.h
@@ -0,0 +1,161 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef LINUX_ATMDEV_H
+#define LINUX_ATMDEV_H
+
+#include
+#include
+#include
+
+#define ESI_LEN 6
+
+#define ATM_OC3_PCR (155520000/270*260/8/53)
+
+#define ATM_25_PCR ((25600000/8-8000)/54)
+
+#define ATM_OC12_PCR (622080000/1080*1040/8/53)
+
+#define ATM_DS3_PCR (8000*12)
+
+#define __AAL_STAT_ITEMS __HANDLE_ITEM(tx); __HANDLE_ITEM(tx_err); __HANDLE_ITEM(rx); __HANDLE_ITEM(rx_err); __HANDLE_ITEM(rx_drop);
+
+struct atm_aal_stats {
+#define __HANDLE_ITEM(i) int i
+ __AAL_STAT_ITEMS
+#undef __HANDLE_ITEM
+};
+
+struct atm_dev_stats {
+ struct atm_aal_stats aal0;
+ struct atm_aal_stats aal34;
+ struct atm_aal_stats aal5;
+} __ATM_API_ALIGN;
+
+#define ATM_GETLINKRATE _IOW('a',ATMIOC_ITF+1,struct atmif_sioc)
+
+#define ATM_GETNAMES _IOW('a',ATMIOC_ITF+3,struct atm_iobuf)
+
+#define ATM_GETTYPE _IOW('a',ATMIOC_ITF+4,struct atmif_sioc)
+
+#define ATM_GETESI _IOW('a',ATMIOC_ITF+5,struct atmif_sioc)
+
+#define ATM_GETADDR _IOW('a',ATMIOC_ITF+6,struct atmif_sioc)
+
+#define ATM_RSTADDR _IOW('a',ATMIOC_ITF+7,struct atmif_sioc)
+
+#define ATM_ADDADDR _IOW('a',ATMIOC_ITF+8,struct atmif_sioc)
+
+#define ATM_DELADDR _IOW('a',ATMIOC_ITF+9,struct atmif_sioc)
+
+#define ATM_GETCIRANGE _IOW('a',ATMIOC_ITF+10,struct atmif_sioc)
+
+#define ATM_SETCIRANGE _IOW('a',ATMIOC_ITF+11,struct atmif_sioc)
+
+#define ATM_SETESI _IOW('a',ATMIOC_ITF+12,struct atmif_sioc)
+
+#define ATM_SETESIF _IOW('a',ATMIOC_ITF+13,struct atmif_sioc)
+
+#define ATM_ADDLECSADDR _IOW('a', ATMIOC_ITF+14, struct atmif_sioc)
+
+#define ATM_DELLECSADDR _IOW('a', ATMIOC_ITF+15, struct atmif_sioc)
+
+#define ATM_GETLECSADDR _IOW('a', ATMIOC_ITF+16, struct atmif_sioc)
+
+#define ATM_GETSTAT _IOW('a',ATMIOC_SARCOM+0,struct atmif_sioc)
+
+#define ATM_GETSTATZ _IOW('a',ATMIOC_SARCOM+1,struct atmif_sioc)
+
+#define ATM_GETLOOP _IOW('a',ATMIOC_SARCOM+2,struct atmif_sioc)
+
+#define ATM_SETLOOP _IOW('a',ATMIOC_SARCOM+3,struct atmif_sioc)
+
+#define ATM_QUERYLOOP _IOW('a',ATMIOC_SARCOM+4,struct atmif_sioc)
+
+#define ATM_SETSC _IOW('a',ATMIOC_SPECIAL+1,int)
+
+#define ATM_SETBACKEND _IOW('a',ATMIOC_SPECIAL+2,atm_backend_t)
+
+#define ATM_NEWBACKENDIF _IOW('a',ATMIOC_SPECIAL+3,atm_backend_t)
+
+#define ATM_ADDPARTY _IOW('a', ATMIOC_SPECIAL+4,struct atm_iobuf)
+
+#define ATM_DROPPARTY _IOW('a', ATMIOC_SPECIAL+5,int)
+
+#define ATM_BACKEND_RAW 0
+#define ATM_BACKEND_PPP 1
+#define ATM_BACKEND_BR2684 2
+
+#define ATM_ITFTYP_LEN 8
+
+#define __ATM_LM_NONE 0
+#define __ATM_LM_AAL 1
+#define __ATM_LM_ATM 2
+
+#define __ATM_LM_PHY 8
+#define __ATM_LM_ANALOG 16
+
+#define __ATM_LM_MKLOC(n) ((n))
+#define __ATM_LM_MKRMT(n) ((n) << 8)
+
+#define __ATM_LM_XTLOC(n) ((n) & 0xff)
+#define __ATM_LM_XTRMT(n) (((n) >> 8) & 0xff)
+
+#define ATM_LM_NONE 0
+
+#define ATM_LM_LOC_AAL __ATM_LM_MKLOC(__ATM_LM_AAL)
+#define ATM_LM_LOC_ATM __ATM_LM_MKLOC(__ATM_LM_ATM)
+#define ATM_LM_LOC_PHY __ATM_LM_MKLOC(__ATM_LM_PHY)
+#define ATM_LM_LOC_ANALOG __ATM_LM_MKLOC(__ATM_LM_ANALOG)
+
+#define ATM_LM_RMT_AAL __ATM_LM_MKRMT(__ATM_LM_AAL)
+#define ATM_LM_RMT_ATM __ATM_LM_MKRMT(__ATM_LM_ATM)
+#define ATM_LM_RMT_PHY __ATM_LM_MKRMT(__ATM_LM_PHY)
+#define ATM_LM_RMT_ANALOG __ATM_LM_MKRMT(__ATM_LM_ANALOG)
+
+struct atm_iobuf {
+ int length;
+ void __user *buffer;
+};
+
+#define ATM_CI_MAX -1
+
+struct atm_cirange {
+ signed char vpi_bits;
+ signed char vci_bits;
+};
+
+#define ATM_SC_RX 1024
+#define ATM_SC_TX 2048
+
+#define ATM_BACKLOG_DEFAULT 32
+
+#define ATM_MF_IMMED 1
+#define ATM_MF_INC_RSV 2
+#define ATM_MF_INC_SHP 4
+#define ATM_MF_DEC_RSV 8
+#define ATM_MF_DEC_SHP 16
+#define ATM_MF_BWD 32
+
+#define ATM_MF_SET (ATM_MF_INC_RSV | ATM_MF_INC_SHP | ATM_MF_DEC_RSV | ATM_MF_DEC_SHP | ATM_MF_BWD)
+
+#define ATM_VS_IDLE 0
+#define ATM_VS_CONNECTED 1
+#define ATM_VS_CLOSING 2
+#define ATM_VS_LISTEN 3
+#define ATM_VS_INUSE 4
+#define ATM_VS_BOUND 5
+
+#define ATM_VS2TXT_MAP "IDLE", "CONNECTED", "CLOSING", "LISTEN", "INUSE", "BOUND"
+
+#define ATM_VF2TXT_MAP "ADDR", "READY", "PARTIAL", "REGIS", "RELEASED", "HASQOS", "LISTEN", "META", "256", "512", "1024", "2048", "SESSION", "HASSAP", "BOUND", "CLOSE"
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atmioc.h b/ndk/build/platforms/android-1.5/common/include/linux/atmioc.h
new file mode 100644
index 000000000..d004339f5
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atmioc.h
@@ -0,0 +1,40 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ATMIOC_H
+#define _LINUX_ATMIOC_H
+
+#include
+
+#define ATMIOC_PHYCOM 0x00
+#define ATMIOC_PHYCOM_END 0x0f
+#define ATMIOC_PHYTYP 0x10
+#define ATMIOC_PHYTYP_END 0x2f
+#define ATMIOC_PHYPRV 0x30
+#define ATMIOC_PHYPRV_END 0x4f
+#define ATMIOC_SARCOM 0x50
+#define ATMIOC_SARCOM_END 0x50
+#define ATMIOC_SARPRV 0x60
+#define ATMIOC_SARPRV_END 0x7f
+#define ATMIOC_ITF 0x80
+#define ATMIOC_ITF_END 0x8f
+#define ATMIOC_BACKEND 0x90
+#define ATMIOC_BACKEND_END 0xaf
+
+#define ATMIOC_AREQUIPA 0xc0
+#define ATMIOC_LANE 0xd0
+#define ATMIOC_MPOA 0xd8
+#define ATMIOC_CLIP 0xe0
+#define ATMIOC_CLIP_END 0xef
+#define ATMIOC_SPECIAL 0xf0
+#define ATMIOC_SPECIAL_END 0xff
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atmppp.h b/ndk/build/platforms/android-1.5/common/include/linux/atmppp.h
new file mode 100644
index 000000000..3330c32fb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atmppp.h
@@ -0,0 +1,26 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ATMPPP_H
+#define _LINUX_ATMPPP_H
+
+#include
+
+#define PPPOATM_ENCAPS_AUTODETECT (0)
+#define PPPOATM_ENCAPS_VC (1)
+#define PPPOATM_ENCAPS_LLC (2)
+
+struct atm_backend_ppp {
+ atm_backend_t backend_num;
+ int encaps;
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/atmsap.h b/ndk/build/platforms/android-1.5/common/include/linux/atmsap.h
new file mode 100644
index 000000000..456f75f6f
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/atmsap.h
@@ -0,0 +1,117 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_ATMSAP_H
+#define _LINUX_ATMSAP_H
+
+#include
+
+#define ATM_L2_NONE 0
+#define ATM_L2_ISO1745 0x01
+#define ATM_L2_Q291 0x02
+#define ATM_L2_X25_LL 0x06
+#define ATM_L2_X25_ML 0x07
+#define ATM_L2_LAPB 0x08
+#define ATM_L2_HDLC_ARM 0x09
+#define ATM_L2_HDLC_NRM 0x0a
+#define ATM_L2_HDLC_ABM 0x0b
+#define ATM_L2_ISO8802 0x0c
+#define ATM_L2_X75 0x0d
+#define ATM_L2_Q922 0x0e
+#define ATM_L2_USER 0x10
+#define ATM_L2_ISO7776 0x11
+
+#define ATM_L3_NONE 0
+#define ATM_L3_X25 0x06
+#define ATM_L3_ISO8208 0x07
+#define ATM_L3_X223 0x08
+#define ATM_L3_ISO8473 0x09
+#define ATM_L3_T70 0x0a
+#define ATM_L3_TR9577 0x0b
+#define ATM_L3_H310 0x0c
+#define ATM_L3_H321 0x0d
+#define ATM_L3_USER 0x10
+
+#define ATM_HL_NONE 0
+#define ATM_HL_ISO 0x01
+#define ATM_HL_USER 0x02
+#define ATM_HL_HLP 0x03
+#define ATM_HL_VENDOR 0x04
+
+#define ATM_IMD_NONE 0
+#define ATM_IMD_NORMAL 1
+#define ATM_IMD_EXTENDED 2
+
+#define ATM_TT_NONE 0
+#define ATM_TT_RX 1
+#define ATM_TT_TX 2
+#define ATM_TT_RXTX 3
+
+#define ATM_MC_NONE 0
+#define ATM_MC_TS 1
+#define ATM_MC_TS_FEC 2
+#define ATM_MC_PS 3
+#define ATM_MC_PS_FEC 4
+#define ATM_MC_H221 5
+
+#define ATM_MAX_HLI 8
+
+struct atm_blli {
+ unsigned char l2_proto;
+ union {
+ struct {
+ unsigned char mode;
+
+ unsigned char window;
+ } itu;
+ unsigned char user;
+ } l2;
+ unsigned char l3_proto;
+ union {
+ struct {
+ unsigned char mode;
+
+ unsigned char def_size;
+
+ unsigned char window;
+ } itu;
+ unsigned char user;
+ struct {
+ unsigned char term_type;
+ unsigned char fw_mpx_cap;
+
+ unsigned char bw_mpx_cap;
+
+ } h310;
+ struct {
+ unsigned char ipi;
+ unsigned char snap[5];
+
+ } tr9577;
+ } l3;
+} __ATM_API_ALIGN;
+
+struct atm_bhli {
+ unsigned char hl_type;
+ unsigned char hl_length;
+
+ unsigned char hl_info[ATM_MAX_HLI];
+};
+
+#define ATM_MAX_BLLI 3
+
+struct atm_sap {
+ struct atm_bhli bhli;
+ struct atm_blli blli[ATM_MAX_BLLI] __ATM_API_ALIGN;
+
+};
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/attribute_container.h b/ndk/build/platforms/android-1.5/common/include/linux/attribute_container.h
new file mode 100644
index 000000000..1a9bfb059
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/attribute_container.h
@@ -0,0 +1,34 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _ATTRIBUTE_CONTAINER_H_
+#define _ATTRIBUTE_CONTAINER_H_
+
+#include
+#include
+#include
+#include
+
+struct attribute_container {
+ struct list_head node;
+ struct klist containers;
+ struct class *class;
+ struct class_device_attribute **attrs;
+ int (*match)(struct attribute_container *, struct device *);
+#define ATTRIBUTE_CONTAINER_NO_CLASSDEVS 0x01
+ unsigned long flags;
+};
+
+struct attribute_container *attribute_container_classdev_to_container(struct class_device *);
+struct class_device *attribute_container_find_class_device(struct attribute_container *, struct device *);
+struct class_device_attribute **attribute_container_classdev_to_attrs(const struct class_device *classdev);
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/auto_fs.h b/ndk/build/platforms/android-1.5/common/include/linux/auto_fs.h
new file mode 100644
index 000000000..3711cc455
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/auto_fs.h
@@ -0,0 +1,56 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_AUTO_FS_H
+#define _LINUX_AUTO_FS_H
+
+#include
+
+#define AUTOFS_PROTO_VERSION 3
+
+#define AUTOFS_MAX_PROTO_VERSION AUTOFS_PROTO_VERSION
+#define AUTOFS_MIN_PROTO_VERSION AUTOFS_PROTO_VERSION
+
+#if defined(__sparc__) || defined(__mips__) || defined(__x86_64__) || defined(__powerpc__) || defined(__s390__)
+typedef unsigned int autofs_wqt_t;
+#else
+typedef unsigned long autofs_wqt_t;
+#endif
+
+#define autofs_ptype_missing 0
+#define autofs_ptype_expire 1
+
+struct autofs_packet_hdr {
+ int proto_version;
+ int type;
+};
+
+struct autofs_packet_missing {
+ struct autofs_packet_hdr hdr;
+ autofs_wqt_t wait_queue_token;
+ int len;
+ char name[NAME_MAX+1];
+};
+
+struct autofs_packet_expire {
+ struct autofs_packet_hdr hdr;
+ int len;
+ char name[NAME_MAX+1];
+};
+
+#define AUTOFS_IOC_READY _IO(0x93,0x60)
+#define AUTOFS_IOC_FAIL _IO(0x93,0x61)
+#define AUTOFS_IOC_CATATONIC _IO(0x93,0x62)
+#define AUTOFS_IOC_PROTOVER _IOR(0x93,0x63,int)
+#define AUTOFS_IOC_SETTIMEOUT _IOWR(0x93,0x64,unsigned long)
+#define AUTOFS_IOC_EXPIRE _IOR(0x93,0x65,struct autofs_packet_expire)
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/autoconf.h b/ndk/build/platforms/android-1.5/common/include/linux/autoconf.h
new file mode 100644
index 000000000..306bf12bf
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/autoconf.h
@@ -0,0 +1,17 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef LINUX_AUTOCONF_CRAP_GOES_HERE
+#define LINUX_AUTOCONF_CRAP_GOES_HERE
+
+#define AUTOCONF_INCLUDED
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/auxvec.h b/ndk/build/platforms/android-1.5/common/include/linux/auxvec.h
new file mode 100644
index 000000000..f8a07011e
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/auxvec.h
@@ -0,0 +1,40 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_AUXVEC_H
+#define _LINUX_AUXVEC_H
+
+#include
+
+#define AT_NULL 0
+#define AT_IGNORE 1
+#define AT_EXECFD 2
+#define AT_PHDR 3
+#define AT_PHENT 4
+#define AT_PHNUM 5
+#define AT_PAGESZ 6
+#define AT_BASE 7
+#define AT_FLAGS 8
+#define AT_ENTRY 9
+#define AT_NOTELF 10
+#define AT_UID 11
+#define AT_EUID 12
+#define AT_GID 13
+#define AT_EGID 14
+#define AT_PLATFORM 15
+#define AT_HWCAP 16
+#define AT_CLKTCK 17
+
+#define AT_SECURE 23
+
+#define AT_VECTOR_SIZE 44
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/backing-dev.h b/ndk/build/platforms/android-1.5/common/include/linux/backing-dev.h
new file mode 100644
index 000000000..4996d2c0d
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/backing-dev.h
@@ -0,0 +1,53 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_BACKING_DEV_H
+#define _LINUX_BACKING_DEV_H
+
+#include
+
+enum bdi_state {
+ BDI_pdflush,
+ BDI_write_congested,
+ BDI_read_congested,
+ BDI_unused,
+};
+
+typedef int (congested_fn)(void *, int);
+
+struct backing_dev_info {
+ unsigned long ra_pages;
+ unsigned long state;
+ unsigned int capabilities;
+ congested_fn *congested_fn;
+ void *congested_data;
+ void (*unplug_io_fn)(struct backing_dev_info *, struct page *);
+ void *unplug_io_data;
+};
+
+#define BDI_CAP_NO_ACCT_DIRTY 0x00000001
+#define BDI_CAP_NO_WRITEBACK 0x00000002
+#define BDI_CAP_MAP_COPY 0x00000004
+#define BDI_CAP_MAP_DIRECT 0x00000008
+#define BDI_CAP_READ_MAP 0x00000010
+#define BDI_CAP_WRITE_MAP 0x00000020
+#define BDI_CAP_EXEC_MAP 0x00000040
+#define BDI_CAP_VMFLAGS (BDI_CAP_READ_MAP | BDI_CAP_WRITE_MAP | BDI_CAP_EXEC_MAP)
+
+#if defined(VM_MAYREAD) && BDI_CAP_READ_MAP != (VM_MAYREAD || BDI_CAP_WRITE_MAP != (VM_MAYWRITE || BDI_CAP_EXEC_MAP != VM_MAYEXEC))
+#error please change backing_dev_info::capabilities flags
+#endif
+
+#define bdi_cap_writeback_dirty(bdi) (!((bdi)->capabilities & BDI_CAP_NO_WRITEBACK))
+#define bdi_cap_account_dirty(bdi) (!((bdi)->capabilities & BDI_CAP_NO_ACCT_DIRTY))
+#define mapping_cap_writeback_dirty(mapping) bdi_cap_writeback_dirty((mapping)->backing_dev_info)
+#define mapping_cap_account_dirty(mapping) bdi_cap_account_dirty((mapping)->backing_dev_info)
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/binder.h b/ndk/build/platforms/android-1.5/common/include/linux/binder.h
new file mode 100644
index 000000000..b97eafb31
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/binder.h
@@ -0,0 +1,186 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_BINDER_H
+#define _LINUX_BINDER_H
+
+#include
+
+#define B_PACK_CHARS(c1, c2, c3, c4) ((((c1)<<24)) | (((c2)<<16)) | (((c3)<<8)) | (c4))
+#define B_TYPE_LARGE 0x85
+
+enum {
+ BINDER_TYPE_BINDER = B_PACK_CHARS('s', 'b', '*', B_TYPE_LARGE),
+ BINDER_TYPE_WEAK_BINDER = B_PACK_CHARS('w', 'b', '*', B_TYPE_LARGE),
+ BINDER_TYPE_HANDLE = B_PACK_CHARS('s', 'h', '*', B_TYPE_LARGE),
+ BINDER_TYPE_WEAK_HANDLE = B_PACK_CHARS('w', 'h', '*', B_TYPE_LARGE),
+ BINDER_TYPE_FD = B_PACK_CHARS('f', 'd', '*', B_TYPE_LARGE),
+};
+
+enum {
+ FLAT_BINDER_FLAG_PRIORITY_MASK = 0xff,
+ FLAT_BINDER_FLAG_ACCEPTS_FDS = 0x100,
+};
+
+struct flat_binder_object {
+
+ unsigned long type;
+ unsigned long flags;
+
+ union {
+ void *binder;
+ signed long handle;
+ };
+
+ void *cookie;
+};
+
+struct binder_write_read {
+ signed long write_size;
+ signed long write_consumed;
+ unsigned long write_buffer;
+ signed long read_size;
+ signed long read_consumed;
+ unsigned long read_buffer;
+};
+
+struct binder_version {
+
+ signed long protocol_version;
+};
+
+#define BINDER_CURRENT_PROTOCOL_VERSION 7
+
+#define BINDER_WRITE_READ _IOWR('b', 1, struct binder_write_read)
+#define BINDER_SET_IDLE_TIMEOUT _IOW('b', 3, int64_t)
+#define BINDER_SET_MAX_THREADS _IOW('b', 5, size_t)
+#define BINDER_SET_IDLE_PRIORITY _IOW('b', 6, int)
+#define BINDER_SET_CONTEXT_MGR _IOW('b', 7, int)
+#define BINDER_THREAD_EXIT _IOW('b', 8, int)
+#define BINDER_VERSION _IOWR('b', 9, struct binder_version)
+
+enum transaction_flags {
+ TF_ONE_WAY = 0x01,
+ TF_ROOT_OBJECT = 0x04,
+ TF_STATUS_CODE = 0x08,
+ TF_ACCEPT_FDS = 0x10,
+};
+
+struct binder_transaction_data {
+
+ union {
+ size_t handle;
+ void *ptr;
+ } target;
+ void *cookie;
+ unsigned int code;
+
+ unsigned int flags;
+ pid_t sender_pid;
+ uid_t sender_euid;
+ size_t data_size;
+ size_t offsets_size;
+
+ union {
+ struct {
+
+ const void *buffer;
+
+ const void *offsets;
+ } ptr;
+ uint8_t buf[8];
+ } data;
+};
+
+struct binder_ptr_cookie {
+ void *ptr;
+ void *cookie;
+};
+
+struct binder_pri_desc {
+ int priority;
+ int desc;
+};
+
+struct binder_pri_ptr_cookie {
+ int priority;
+ void *ptr;
+ void *cookie;
+};
+
+enum BinderDriverReturnProtocol {
+ BR_ERROR = _IOR_BAD('r', 0, int),
+
+ BR_OK = _IO('r', 1),
+
+ BR_TRANSACTION = _IOR_BAD('r', 2, struct binder_transaction_data),
+ BR_REPLY = _IOR_BAD('r', 3, struct binder_transaction_data),
+
+ BR_ACQUIRE_RESULT = _IOR_BAD('r', 4, int),
+
+ BR_DEAD_REPLY = _IO('r', 5),
+
+ BR_TRANSACTION_COMPLETE = _IO('r', 6),
+
+ BR_INCREFS = _IOR_BAD('r', 7, struct binder_ptr_cookie),
+ BR_ACQUIRE = _IOR_BAD('r', 8, struct binder_ptr_cookie),
+ BR_RELEASE = _IOR_BAD('r', 9, struct binder_ptr_cookie),
+ BR_DECREFS = _IOR_BAD('r', 10, struct binder_ptr_cookie),
+
+ BR_ATTEMPT_ACQUIRE = _IOR_BAD('r', 11, struct binder_pri_ptr_cookie),
+
+ BR_NOOP = _IO('r', 12),
+
+ BR_SPAWN_LOOPER = _IO('r', 13),
+
+ BR_FINISHED = _IO('r', 14),
+
+ BR_DEAD_BINDER = _IOR_BAD('r', 15, void *),
+
+ BR_CLEAR_DEATH_NOTIFICATION_DONE = _IOR_BAD('r', 16, void *),
+
+ BR_FAILED_REPLY = _IO('r', 17),
+
+};
+
+enum BinderDriverCommandProtocol {
+ BC_TRANSACTION = _IOW_BAD('c', 0, struct binder_transaction_data),
+ BC_REPLY = _IOW_BAD('c', 1, struct binder_transaction_data),
+
+ BC_ACQUIRE_RESULT = _IOW_BAD('c', 2, int),
+
+ BC_FREE_BUFFER = _IOW_BAD('c', 3, int),
+
+ BC_INCREFS = _IOW_BAD('c', 4, int),
+ BC_ACQUIRE = _IOW_BAD('c', 5, int),
+ BC_RELEASE = _IOW_BAD('c', 6, int),
+ BC_DECREFS = _IOW_BAD('c', 7, int),
+
+ BC_INCREFS_DONE = _IOW_BAD('c', 8, struct binder_ptr_cookie),
+ BC_ACQUIRE_DONE = _IOW_BAD('c', 9, struct binder_ptr_cookie),
+
+ BC_ATTEMPT_ACQUIRE = _IOW_BAD('c', 10, struct binder_pri_desc),
+
+ BC_REGISTER_LOOPER = _IO('c', 11),
+
+ BC_ENTER_LOOPER = _IO('c', 12),
+ BC_EXIT_LOOPER = _IO('c', 13),
+
+ BC_REQUEST_DEATH_NOTIFICATION = _IOW_BAD('c', 14, struct binder_ptr_cookie),
+
+ BC_CLEAR_DEATH_NOTIFICATION = _IOW_BAD('c', 15, struct binder_ptr_cookie),
+
+ BC_DEAD_BINDER_DONE = _IOW_BAD('c', 16, void *),
+
+};
+
+#endif
+
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/binfmts.h b/ndk/build/platforms/android-1.5/common/include/linux/binfmts.h
new file mode 100644
index 000000000..3335985d0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/binfmts.h
@@ -0,0 +1,23 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_BINFMTS_H
+#define _LINUX_BINFMTS_H
+
+#include
+
+struct pt_regs;
+
+#define MAX_ARG_PAGES 32
+
+#define BINPRM_BUF_SIZE 128
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/bio.h b/ndk/build/platforms/android-1.5/common/include/linux/bio.h
new file mode 100644
index 000000000..4e913146a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/bio.h
@@ -0,0 +1,171 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __LINUX_BIO_H
+#define __LINUX_BIO_H
+
+#include
+#include
+#include
+
+#include
+
+#if defined(BIO_VMERGE_MAX_SIZE) && defined(BIO_VMERGE_BOUNDARY)
+#define BIOVEC_VIRT_START_SIZE(x) (bvec_to_phys(x) & (BIO_VMERGE_BOUNDARY - 1))
+#define BIOVEC_VIRT_OVERSIZE(x) ((x) > BIO_VMERGE_MAX_SIZE)
+#else
+#define BIOVEC_VIRT_START_SIZE(x) 0
+#define BIOVEC_VIRT_OVERSIZE(x) 0
+#endif
+
+#ifndef BIO_VMERGE_BOUNDARY
+#define BIO_VMERGE_BOUNDARY 0
+#endif
+
+#define BIO_DEBUG
+
+#ifdef BIO_DEBUG
+#define BIO_BUG_ON BUG_ON
+#else
+#define BIO_BUG_ON
+#endif
+
+#define BIO_MAX_PAGES 256
+#define BIO_MAX_SIZE (BIO_MAX_PAGES << PAGE_CACHE_SHIFT)
+#define BIO_MAX_SECTORS (BIO_MAX_SIZE >> 9)
+
+struct bio_vec {
+ struct page *bv_page;
+ unsigned int bv_len;
+ unsigned int bv_offset;
+};
+
+struct bio_set;
+struct bio;
+typedef int (bio_end_io_t) (struct bio *, unsigned int, int);
+typedef void (bio_destructor_t) (struct bio *);
+
+struct bio {
+ sector_t bi_sector;
+ struct bio *bi_next;
+ struct block_device *bi_bdev;
+ unsigned long bi_flags;
+ unsigned long bi_rw;
+
+ unsigned short bi_vcnt;
+ unsigned short bi_idx;
+
+ unsigned short bi_phys_segments;
+
+ unsigned short bi_hw_segments;
+
+ unsigned int bi_size;
+
+ unsigned int bi_hw_front_size;
+ unsigned int bi_hw_back_size;
+
+ unsigned int bi_max_vecs;
+
+ struct bio_vec *bi_io_vec;
+
+ bio_end_io_t *bi_end_io;
+ atomic_t bi_cnt;
+
+ void *bi_private;
+
+ bio_destructor_t *bi_destructor;
+};
+
+#define BIO_UPTODATE 0
+#define BIO_RW_BLOCK 1
+#define BIO_EOF 2
+#define BIO_SEG_VALID 3
+#define BIO_CLONED 4
+#define BIO_BOUNCED 5
+#define BIO_USER_MAPPED 6
+#define BIO_EOPNOTSUPP 7
+#define bio_flagged(bio, flag) ((bio)->bi_flags & (1 << (flag)))
+
+#define BIO_POOL_BITS (4)
+#define BIO_POOL_OFFSET (BITS_PER_LONG - BIO_POOL_BITS)
+#define BIO_POOL_MASK (1UL << BIO_POOL_OFFSET)
+#define BIO_POOL_IDX(bio) ((bio)->bi_flags >> BIO_POOL_OFFSET)
+
+#define BIO_RW 0
+#define BIO_RW_AHEAD 1
+#define BIO_RW_BARRIER 2
+#define BIO_RW_FAILFAST 3
+#define BIO_RW_SYNC 4
+
+#define BIO_PRIO_SHIFT (8 * sizeof(unsigned long) - IOPRIO_BITS)
+#define bio_prio(bio) ((bio)->bi_rw >> BIO_PRIO_SHIFT)
+#define bio_prio_valid(bio) ioprio_valid(bio_prio(bio))
+
+#define bio_set_prio(bio, prio) do { WARN_ON(prio >= (1 << IOPRIO_BITS)); (bio)->bi_rw &= ((1UL << BIO_PRIO_SHIFT) - 1); (bio)->bi_rw |= ((unsigned long) (prio) << BIO_PRIO_SHIFT); } while (0)
+
+#define bio_iovec_idx(bio, idx) (&((bio)->bi_io_vec[(idx)]))
+#define bio_iovec(bio) bio_iovec_idx((bio), (bio)->bi_idx)
+#define bio_page(bio) bio_iovec((bio))->bv_page
+#define bio_offset(bio) bio_iovec((bio))->bv_offset
+#define bio_segments(bio) ((bio)->bi_vcnt - (bio)->bi_idx)
+#define bio_sectors(bio) ((bio)->bi_size >> 9)
+#define bio_cur_sectors(bio) (bio_iovec(bio)->bv_len >> 9)
+#define bio_data(bio) (page_address(bio_page((bio))) + bio_offset((bio)))
+#define bio_barrier(bio) ((bio)->bi_rw & (1 << BIO_RW_BARRIER))
+#define bio_sync(bio) ((bio)->bi_rw & (1 << BIO_RW_SYNC))
+#define bio_failfast(bio) ((bio)->bi_rw & (1 << BIO_RW_FAILFAST))
+#define bio_rw_ahead(bio) ((bio)->bi_rw & (1 << BIO_RW_AHEAD))
+
+#define bio_to_phys(bio) (page_to_phys(bio_page((bio))) + (unsigned long) bio_offset((bio)))
+#define bvec_to_phys(bv) (page_to_phys((bv)->bv_page) + (unsigned long) (bv)->bv_offset)
+
+#define __bio_kmap_atomic(bio, idx, kmtype) (kmap_atomic(bio_iovec_idx((bio), (idx))->bv_page, kmtype) + bio_iovec_idx((bio), (idx))->bv_offset)
+
+#define __bio_kunmap_atomic(addr, kmtype) kunmap_atomic(addr, kmtype)
+
+#define __BVEC_END(bio) bio_iovec_idx((bio), (bio)->bi_vcnt - 1)
+#define __BVEC_START(bio) bio_iovec_idx((bio), (bio)->bi_idx)
+
+#ifndef BIOVEC_PHYS_MERGEABLE
+#define BIOVEC_PHYS_MERGEABLE(vec1, vec2) ((bvec_to_phys((vec1)) + (vec1)->bv_len) == bvec_to_phys((vec2)))
+#endif
+
+#define BIOVEC_VIRT_MERGEABLE(vec1, vec2) ((((bvec_to_phys((vec1)) + (vec1)->bv_len) | bvec_to_phys((vec2))) & (BIO_VMERGE_BOUNDARY - 1)) == 0)
+#define __BIO_SEG_BOUNDARY(addr1, addr2, mask) (((addr1) | (mask)) == (((addr2) - 1) | (mask)))
+#define BIOVEC_SEG_BOUNDARY(q, b1, b2) __BIO_SEG_BOUNDARY(bvec_to_phys((b1)), bvec_to_phys((b2)) + (b2)->bv_len, (q)->seg_boundary_mask)
+#define BIO_SEG_BOUNDARY(q, b1, b2) BIOVEC_SEG_BOUNDARY((q), __BVEC_END((b1)), __BVEC_START((b2)))
+
+#define bio_io_error(bio, bytes) bio_endio((bio), (bytes), -EIO)
+
+#define __bio_for_each_segment(bvl, bio, i, start_idx) for (bvl = bio_iovec_idx((bio), (start_idx)), i = (start_idx); i < (bio)->bi_vcnt; bvl++, i++)
+
+#define bio_for_each_segment(bvl, bio, i) __bio_for_each_segment(bvl, bio, i, (bio)->bi_idx)
+
+#define bio_get(bio) atomic_inc(&(bio)->bi_cnt)
+
+struct bio_pair {
+ struct bio bio1, bio2;
+ struct bio_vec bv1, bv2;
+ atomic_t cnt;
+ int error;
+};
+
+struct request_queue;
+
+struct sg_iovec;
+
+#define bvec_kmap_irq(bvec, flags) (page_address((bvec)->bv_page) + (bvec)->bv_offset)
+#define bvec_kunmap_irq(buf, flags) do { *(flags) = 0; } while (0)
+
+#define __bio_kunmap_irq(buf, flags) bvec_kunmap_irq(buf, flags)
+#define bio_kmap_irq(bio, flags) __bio_kmap_irq((bio), (bio)->bi_idx, (flags))
+#define bio_kunmap_irq(buf,flags) __bio_kunmap_irq(buf, flags)
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/bitmap.h b/ndk/build/platforms/android-1.5/common/include/linux/bitmap.h
new file mode 100644
index 000000000..246d158a0
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/bitmap.h
@@ -0,0 +1,24 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef __LINUX_BITMAP_H
+#define __LINUX_BITMAP_H
+
+#ifndef __ASSEMBLY__
+
+#include
+#include
+#include
+
+#define BITMAP_LAST_WORD_MASK(nbits) ( ((nbits) % BITS_PER_LONG) ? (1UL<<((nbits) % BITS_PER_LONG))-1 : ~0UL )
+
+#endif
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/bitops.h b/ndk/build/platforms/android-1.5/common/include/linux/bitops.h
new file mode 100644
index 000000000..f8df614eb
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/bitops.h
@@ -0,0 +1,18 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_BITOPS_H
+#define _LINUX_BITOPS_H
+#include
+
+#include
+
+#endif
diff --git a/ndk/build/platforms/android-1.5/common/include/linux/blkdev.h b/ndk/build/platforms/android-1.5/common/include/linux/blkdev.h
new file mode 100644
index 000000000..30045246a
--- /dev/null
+++ b/ndk/build/platforms/android-1.5/common/include/linux/blkdev.h
@@ -0,0 +1,461 @@
+/****************************************************************************
+ ****************************************************************************
+ ***
+ *** This header was automatically generated from a Linux kernel header
+ *** of the same name, to make information necessary for userspace to
+ *** call into the kernel available to libc. It contains only constants,
+ *** structures, and macros generated from the original header, and thus,
+ *** contains no copyrightable information.
+ ***
+ ****************************************************************************
+ ****************************************************************************/
+#ifndef _LINUX_BLKDEV_H
+#define _LINUX_BLKDEV_H
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include