Skip to content

Commit 9548c2f

Browse files
committed
[GR-38830] Use LLVM as backend for ctypes if native access is not allowed.
PullRequest: graalpython/2352
2 parents 28e48a5 + 9e1bed4 commit 9548c2f

File tree

6 files changed

+252
-168
lines changed

6 files changed

+252
-168
lines changed

graalpython/com.oracle.graal.python.shell/src/com/oracle/graal/python/shell/GraalPythonMain.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -490,7 +490,7 @@ private String[] getExecutableList() {
490490
}
491491
exec_list.add("-classpath");
492492
exec_list.add(System.getProperty("java.class.path"));
493-
exec_list.add(GraalPythonMain.class.getName());
493+
exec_list.add(getMainClass());
494494
if (relaunchArgs != null) {
495495
exec_list.addAll(relaunchArgs);
496496
}
@@ -1026,7 +1026,7 @@ private static void setupTerminal(ConsoleHandler consoleHandler) {
10261026
* Some system properties have already been read at this point, so to change them, we just
10271027
* re-execute the process with the additional options.
10281028
*/
1029-
private static void subExec(List<String> args, List<String> subProcessDefs) {
1029+
private void subExec(List<String> args, List<String> subProcessDefs) {
10301030
List<String> cmd = getCmdline(args, subProcessDefs);
10311031
try {
10321032
System.exit(new ProcessBuilder(cmd.toArray(new String[0])).inheritIO().start().waitFor());
@@ -1037,7 +1037,7 @@ private static void subExec(List<String> args, List<String> subProcessDefs) {
10371037
}
10381038
}
10391039

1040-
static List<String> getCmdline(List<String> args, List<String> subProcessDefs) {
1040+
private List<String> getCmdline(List<String> args, List<String> subProcessDefs) {
10411041
List<String> cmd = new ArrayList<>();
10421042
if (isAOT()) {
10431043
cmd.add(ProcessProperties.getExecutableName());
@@ -1064,7 +1064,7 @@ static List<String> getCmdline(List<String> args, List<String> subProcessDefs) {
10641064
assert subProcArg.startsWith("D") || subProcArg.startsWith("agent");
10651065
cmd.add("-" + subProcArg);
10661066
}
1067-
cmd.add(GraalPythonMain.class.getName());
1067+
cmd.add(getMainClass());
10681068
}
10691069

10701070
cmd.addAll(args);

0 commit comments

Comments
 (0)