Revert "add runtime to classpath in JetCoreEnvironment" temporarily

This reverts commit 59c7f33c88.
This commit is contained in:
Stepan Koltsov
2012-04-09 18:54:42 +04:00
parent 9711d18dca
commit 03e78e8cc3
3 changed files with 12 additions and 18 deletions
@@ -23,7 +23,6 @@ import org.jetbrains.jet.compiler.CompileEnvironmentException;
import org.jetbrains.jet.compiler.CompilerPlugin;
import org.jetbrains.jet.lang.resolve.java.CompilerDependencies;
import org.jetbrains.jet.lang.resolve.java.CompilerSpecialMode;
import org.jetbrains.jet.utils.PathUtil;
import java.io.File;
import java.util.ArrayList;
@@ -50,23 +49,11 @@ public class BytecodeCompiler {
* @return compile environment instance
*/
private CompileEnvironment env( String stdlib, String[] classpath ) {
CompilerSpecialMode compilerSpecialMode = CompilerSpecialMode.REGULAR;
File runtimeJar;
if (compilerSpecialMode.includeKotlinRuntime()) {
if (( stdlib != null ) && ( stdlib.trim().length() > 0 )) {
runtimeJar = new File( stdlib );
}
else {
runtimeJar = PathUtil.getDefaultRuntimePath();
}
CompileEnvironment env = new CompileEnvironment(CompilerDependencies.compilerDependenciesForProduction(CompilerSpecialMode.REGULAR));
if (( stdlib != null ) && ( stdlib.trim().length() > 0 )) {
env.setStdlib( stdlib );
}
else {
runtimeJar = null;
}
CompileEnvironment env = new CompileEnvironment( new CompilerDependencies(
compilerSpecialMode,
compilerSpecialMode.includeJdkHeaders() ? PathUtil.getAltHeadersPath() : null,
runtimeJar ) );
if (( classpath != null ) && ( classpath.length > 0 )) {
env.addToClasspath( classpath );