Browse Source

Add -lm option for C languages.

master
Menci 6 years ago
parent
commit
4b5d9ea7b8
  1. 2
      src/languages/c-noilinux.ts
  2. 2
      src/languages/c.ts

2
src/languages/c-noilinux.ts

@ -10,7 +10,7 @@ export const lang = {
// write a shell script or some other stuff, // write a shell script or some other stuff,
// and put it to your sandbox. // and put it to your sandbox.
executable: "/usr/bin/compile-c-noilinux", executable: "/usr/bin/compile-c-noilinux",
parameters: ["compile-c-noilinux", sourcePath, "-o", `${outputDirectory}/a.out`, "-O2", "-DONLINE_JUDGE"], parameters: ["compile-c-noilinux", sourcePath, "-o", `${outputDirectory}/a.out`, "-O2", "-DONLINE_JUDGE", "-lm"],
time: 5000, time: 5000,
memory: 1024 * 1024 * 1024 * 2, memory: 1024 * 1024 * 1024 * 2,
process: 10, process: 10,

2
src/languages/c.ts

@ -10,7 +10,7 @@ export const lang = {
// write a shell script or some other stuff, // write a shell script or some other stuff,
// and put it to your sandbox. // and put it to your sandbox.
executable: "/usr/bin/clang-7", executable: "/usr/bin/clang-7",
parameters: ["clang-7", sourcePath, "-o", `${outputDirectory}/a.out`, "-O2", "-fdiagnostics-color=always", "-DONLINE_JUDGE", "-mx32"], parameters: ["clang-7", sourcePath, "-o", `${outputDirectory}/a.out`, "-O2", "-fdiagnostics-color=always", "-DONLINE_JUDGE", "-mx32", "-lm"],
time: 5000, time: 5000,
memory: 1024 * 1024 * 1024 * 2, memory: 1024 * 1024 * 1024 * 2,
process: 10, process: 10,

Loading…
Cancel
Save