Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenJDK issue with soot #3

Open
ftc opened this issue Oct 3, 2016 · 1 comment
Open

OpenJDK issue with soot #3

ftc opened this issue Oct 3, 2016 · 1 comment

Comments

@ftc
Copy link
Member

ftc commented Oct 3, 2016

Soot hard codes the path of the rt.jar and classes.jar on OSx which breaks if you are using the openJDK.

In [sootpath]/src/soot/Scene.java these paths are hardcoded, we should probably open up an issue with soot.

 354         if(System.getProperty("os.name").equals("Mac OS X")) {
 355                 //in older Mac OS X versions, rt.jar was split into classes.jar and ui.jar
 356                 sb.append(System.getProperty("java.home"));
 357                 sb.append(File.separator);
 358                 sb.append("..");
 359                 sb.append(File.separator);
 360                 sb.append("Classes");
 361                 sb.append(File.separator);
 362                 sb.append("classes.jar");
 363
 364                 sb.append(File.pathSeparator);
 365                 sb.append(System.getProperty("java.home"));
 366                 sb.append(File.separator);
 367                 sb.append("..");
 368                 sb.append(File.separator);
 369                 sb.append("Classes");
 370                 sb.append(File.separator);
 371                 sb.append("ui.jar");
 372                 sb.append(File.pathSeparator);
 373         }

Temporary fix:

          if(System.getProperty("os.name").equals("Mac OS X")){
            Scene.v().setSootClassPath(sys.env("JAVA_HOME") + "/jre/lib/rt.jar")

          }
@ftc
Copy link
Member Author

ftc commented Oct 3, 2016

Note: temporary fix added to TraceRunner main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant