From fa2be8eb42aafe3e008191369a191e9f0ed2c0b3 Mon Sep 17 00:00:00 2001 From: slhmy Date: Sun, 29 Sep 2024 20:43:12 +0800 Subject: [PATCH] Revert "Remove -static param for C++ compile" This reverts commit 4b97165ddad76fcf4e9e42b6b31eab07b52eae41. --- judge-core/src/compiler.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/judge-core/src/compiler.rs b/judge-core/src/compiler.rs index ef9bb82..b00bde0 100644 --- a/judge-core/src/compiler.rs +++ b/judge-core/src/compiler.rs @@ -10,7 +10,7 @@ const TEMPLATE_ARG_SRC_PATH: &str = "{src_path}"; const TEMPLATE_ARG_TARGET_PATH: &str = "{target_path}"; const RUST_COMPILE_COMMAND_TEMPLATE: &str = "rustc {src_path} -o {target_path}"; -const CPP_COMPILE_COMMAND_TEMPLATE: &str = "g++ {src_path} -o {target_path} -O2"; +const CPP_COMPILE_COMMAND_TEMPLATE: &str = "g++ {src_path} -o {target_path} -O2 -static"; const PYTHON_COMPILE_COMMAND_TEMPLATE: &str = "cp {src_path} {target_path}"; #[derive(Clone)]