summaryrefslogtreecommitdiff
path: root/components
diff options
context:
space:
mode:
authorCYFS <[email protected]>2026-09-09 12:07:39 +0800
committerRbb666 <[email protected]>2026-09-09 13:31:44 +0800
commit5899db2a52f3340b02c2a1a460e7f821202a20a8 (patch)
treef820c94b5f95127565f4089cee9dfc6b9e43e3b7 /components
parentd7ea2bce99c4dc1e63b28638674e1b94d1791417 (diff)
[rust][build] Avoid toml dependency during clean
Diffstat (limited to 'components')
-rw-r--r--components/rust/examples/modules/SConscript5
1 files changed, 3 insertions, 2 deletions
diff --git a/components/rust/examples/modules/SConscript b/components/rust/examples/modules/SConscript
index 056501c057..dffacb839d 100644
--- a/components/rust/examples/modules/SConscript
+++ b/components/rust/examples/modules/SConscript
@@ -1,7 +1,6 @@
import os
import sys
import subprocess
-import toml
from building import *
cwd = GetCurrentDir()
@@ -77,7 +76,9 @@ def build_rust_module(module_dir, build_root):
cargo_toml_path = os.path.join(module_dir, 'Cargo.toml')
if not os.path.exists(cargo_toml_path):
return [], [], ""
-
+
+ import toml
+
with open(cargo_toml_path, 'r') as f:
cargo_config = toml.load(f)