OnlineJudge/judge/language.py

43 lines
1.7 KiB
Python
Raw Normal View History

# coding=utf-8
languages = {
1: {
"name": "c",
2015-07-07 10:07:54 +00:00
"src_name": "main.c",
"code": 1,
"compile_max_cpu_time": 3000,
"compile_max_memory": 128 * 1024 * 1024,
"compile_command": "/usr/bin/gcc -DONLINE_JUDGE -O2 -w -fmax-errors=3 -std=c99 {src_path} -lm -o {exe_path}/main",
2016-04-07 08:44:15 +00:00
"spj_compile_command": "/usr/bin/gcc -DONLINE_JUDGE -O2 -Werror -fmax-errors=3 -std=c99 {src_path} -lm -o {exe_path}",
2016-02-02 02:23:23 +00:00
"execute_command": "{exe_path}/main",
"use_sandbox": True
},
2: {
"name": "cpp",
2015-07-07 10:07:54 +00:00
"src_name": "main.cpp",
"code": 2,
"compile_max_cpu_time": 3000,
2016-05-10 13:02:43 +00:00
"compile_max_memory": 256 * 1024 * 1024,
"compile_command": "/usr/bin/g++ -DONLINE_JUDGE -O2 -w -fmax-errors=3 -std=c++11 {src_path} -lm -o {exe_path}/main",
2016-04-07 08:44:15 +00:00
"spj_compile_command": "/usr/bin/g++ -DONLINE_JUDGE -O2 -Werror -fmax-errors=3 -std=c++11 {src_path} -lm -o {exe_path}",
2016-02-02 02:23:23 +00:00
"execute_command": "{exe_path}/main",
"use_sandbox": True
},
3: {
"name": "java",
2015-07-07 10:07:54 +00:00
"src_name": "Main.java",
"code": 3,
"compile_max_cpu_time": 3000,
"compile_max_memory": 1024 * 1024 * 1024,
"compile_command": "/usr/bin/javac {src_path} -d {exe_path} -J-Xss1m -J-XX:MaxPermSize=16M "
"-J-XX:PermSize=8M -J-Xms16m -J-Xmx1024m -encoding UTF8",
"execute_command": "/usr/bin/java -cp {exe_path} -Xss1M -XX:MaxPermSize=16M "
"-XX:PermSize=8M -Xms16M -Xmx{max_memory} -Djava.security.manager "
"-Djava.security.policy==policy -Djava.awt.headless=true Main",
2016-02-02 02:23:23 +00:00
"use_sandbox": False
}
}