Rewrite File.getCanonicalPath.
My original plan was to just rely on the fixed realpath(3), but it turns out
that Java's behavior is quite different from the C library's in cases where
path elements don't exist. I also wasn't particularly excited about introducing
a fixed-length buffer. To that end, I've added a native implementation of
getCanonicalPath.
I've also improved the getAbsolutePath and getCanonicalPath documentation.
This patch also makes File.absolutePath transient, a regression in gingerbread
which uselessly bloated File's serialized form.
Bug: 2281992
Change-Id: Iff94eee07fe574251c1188b2b2eb71f585c81c6a
diff --git a/NativeCode.mk b/NativeCode.mk
index 4c6ffa5..57c2457 100644
--- a/NativeCode.mk
+++ b/NativeCode.mk
@@ -94,8 +94,8 @@
# Define the rules.
LOCAL_SRC_FILES := $(core_src_files)
-LOCAL_C_INCLUDES := $(core_c_includes)
-LOCAL_SHARED_LIBRARIES := $(core_shared_libraries)
+LOCAL_C_INCLUDES := $(core_c_includes) bionic/ bionic/libstdc++/include external/stlport/stlport
+LOCAL_SHARED_LIBRARIES := $(core_shared_libraries) libstlport
LOCAL_STATIC_LIBRARIES := $(core_static_libraries)
LOCAL_MODULE_TAGS := optional
LOCAL_MODULE := libjavacore