提交 776b8511 编写于 作者: V vladidan

8005545: Add System property to identify ARCH specific details such as ARM hard-float binaries

Summary: Adding sun.os.abi Java Property support
Reviewed-by: bobv, alanb, dholmes
上级 ce2d77f5
......@@ -602,6 +602,7 @@ define create-info-file
$(call info-file-item, "OS_NAME", "$(REQUIRED_OS_NAME)")
$(call info-file-item, "OS_VERSION", "$(REQUIRED_OS_VERSION)")
$(call info-file-item, "OS_ARCH", "$(OPENJDK_TARGET_CPU_LEGACY)")
if [ -n "$(JDK_ARCH_ABI_PROP_NAME)" ]; then $(call info-file-item, "SUN_ARCH_ABI", "$(JDK_ARCH_ABI_PROP_NAME)"); fi
$(call info-file-item, "SOURCE", "$(ALL_SOURCE_TIPS)")
endef
......
......@@ -212,6 +212,10 @@ Java_java_lang_System_initProperties(JNIEnv *env, jclass cla, jobject props)
PUTPROP(props, "os.version", sprops->os_version);
PUTPROP(props, "os.arch", sprops->os_arch);
#ifdef JDK_ARCH_ABI_PROP_NAME
PUTPROP(props, "sun.arch.abi", sprops->sun_arch_abi);
#endif
/* file system properties */
PUTPROP(props, "file.separator", sprops->file_separator);
PUTPROP(props, "path.separator", sprops->path_separator);
......
......@@ -41,6 +41,10 @@ typedef struct {
char *os_version;
char *os_arch;
#ifdef JDK_ARCH_ABI_PROP_NAME
char *sun_arch_abi;
#endif
nchar *tmp_dir;
nchar *font_dir;
nchar *user_dir;
......
......@@ -514,6 +514,11 @@ GetJavaProperties(JNIEnv *env)
}
}
/* ABI property (optional) */
#ifdef JDK_ARCH_ABI_PROP_NAME
sprops.sun_arch_abi = JDK_ARCH_ABI_PROP_NAME;
#endif
/* Determine the language, country, variant, and encoding from the host,
* and store these in the user.language, user.country, user.variant and
* file.encoding system properties. */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册