Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_langtools
提交
adf2f1de
D
dragonwell8_langtools
项目概览
openanolis
/
dragonwell8_langtools
通知
0
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_langtools
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
adf2f1de
编写于
10月 26, 2012
作者:
J
jjg
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8001229: refactor javac so that ct.sym is just used for javac, not all clients of JavacFileManager
Reviewed-by: mcimadamore
上级
9fa48065
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
15 addition
and
16 deletion
+15
-16
src/share/classes/com/sun/tools/javac/file/JavacFileManager.java
...re/classes/com/sun/tools/javac/file/JavacFileManager.java
+10
-3
src/share/classes/com/sun/tools/javah/JavahFileManager.java
src/share/classes/com/sun/tools/javah/JavahFileManager.java
+2
-6
src/share/classes/com/sun/tools/javah/JavahTask.java
src/share/classes/com/sun/tools/javah/JavahTask.java
+1
-1
src/share/classes/com/sun/tools/javap/JavapFileManager.java
src/share/classes/com/sun/tools/javap/JavapFileManager.java
+2
-6
未找到文件。
src/share/classes/com/sun/tools/javac/file/JavacFileManager.java
浏览文件 @
adf2f1de
...
...
@@ -90,7 +90,7 @@ public class JavacFileManager extends BaseFileManager implements StandardJavaFil
EnumSet
.
of
(
JavaFileObject
.
Kind
.
SOURCE
,
JavaFileObject
.
Kind
.
CLASS
);
protected
boolean
mmappedIO
;
protected
boolean
ignoreSymbolFile
;
protected
boolean
symbolFileEnabled
;
protected
enum
SortFiles
implements
Comparator
<
File
>
{
FORWARD
{
...
...
@@ -142,7 +142,7 @@ public class JavacFileManager extends BaseFileManager implements StandardJavaFil
zipFileIndexCache
=
ZipFileIndexCache
.
getSharedInstance
();
mmappedIO
=
options
.
isSet
(
"mmappedIO"
);
ignoreSymbolFile
=
options
.
isSet
(
"ignore.symbol.file"
);
symbolFileEnabled
=
!
options
.
isSet
(
"ignore.symbol.file"
);
String
sf
=
options
.
get
(
"sortFiles"
);
if
(
sf
!=
null
)
{
...
...
@@ -150,6 +150,13 @@ public class JavacFileManager extends BaseFileManager implements StandardJavaFil
}
}
/**
* Set whether or not to use ct.sym as an alternate to rt.jar.
*/
public
void
setSymbolFileEnabled
(
boolean
b
)
{
symbolFileEnabled
=
b
;
}
@Override
public
boolean
isDefaultBootClassPath
()
{
return
locations
.
isDefaultBootClassPath
();
...
...
@@ -466,7 +473,7 @@ public class JavacFileManager extends BaseFileManager implements StandardJavaFil
*/
private
Archive
openArchive
(
File
zipFileName
,
boolean
useOptimizedZip
)
throws
IOException
{
File
origZipFileName
=
zipFileName
;
if
(
!
ignoreSymbolFile
&&
locations
.
isDefaultBootClassPathRtJar
(
zipFileName
))
{
if
(
symbolFileEnabled
&&
locations
.
isDefaultBootClassPathRtJar
(
zipFileName
))
{
File
file
=
zipFileName
.
getParentFile
().
getParentFile
();
// ${java.home}
if
(
new
File
(
file
.
getName
()).
equals
(
new
File
(
"jre"
)))
file
=
file
.
getParentFile
();
...
...
src/share/classes/com/sun/tools/javah/JavahFileManager.java
浏览文件 @
adf2f1de
/*
* Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007,
2012,
Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -44,7 +44,7 @@ import com.sun.tools.javac.util.Context;
class
JavahFileManager
extends
JavacFileManager
{
private
JavahFileManager
(
Context
context
,
Charset
charset
)
{
super
(
context
,
true
,
charset
);
set
IgnoreSymbolFile
(
tru
e
);
set
SymbolFileEnabled
(
fals
e
);
}
static
JavahFileManager
create
(
final
DiagnosticListener
<?
super
JavaFileObject
>
dl
,
PrintWriter
log
)
{
...
...
@@ -56,8 +56,4 @@ class JavahFileManager extends JavacFileManager {
return
new
JavahFileManager
(
javac_context
,
null
);
}
void
setIgnoreSymbolFile
(
boolean
b
)
{
ignoreSymbolFile
=
b
;
}
}
src/share/classes/com/sun/tools/javah/JavahTask.java
浏览文件 @
adf2f1de
...
...
@@ -500,7 +500,7 @@ public class JavahTask implements NativeHeaderTool.NativeHeaderTask {
g
.
setForce
(
force
);
if
(
fileManager
instanceof
JavahFileManager
)
((
JavahFileManager
)
fileManager
).
set
IgnoreSymbolFile
(
tru
e
);
((
JavahFileManager
)
fileManager
).
set
SymbolFileEnabled
(
fals
e
);
JavaCompiler
c
=
ToolProvider
.
getSystemJavaCompiler
();
List
<
String
>
opts
=
new
ArrayList
<
String
>();
...
...
src/share/classes/com/sun/tools/javap/JavapFileManager.java
浏览文件 @
adf2f1de
/*
* Copyright (c) 2007, 20
08
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 20
12
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -44,7 +44,7 @@ import com.sun.tools.javac.util.Context;
public
class
JavapFileManager
extends
JavacFileManager
{
private
JavapFileManager
(
Context
context
,
Charset
charset
)
{
super
(
context
,
true
,
charset
);
set
IgnoreSymbolFile
(
tru
e
);
set
SymbolFileEnabled
(
fals
e
);
}
public
static
JavapFileManager
create
(
final
DiagnosticListener
<?
super
JavaFileObject
>
dl
,
PrintWriter
log
)
{
...
...
@@ -56,8 +56,4 @@ public class JavapFileManager extends JavacFileManager {
return
new
JavapFileManager
(
javac_context
,
null
);
}
void
setIgnoreSymbolFile
(
boolean
b
)
{
ignoreSymbolFile
=
b
;
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录