From a5fcb16aa9e872296ccdee763522a63b376c07c5 Mon Sep 17 00:00:00 2001 From: George Higashiyama Date: Mon, 29 Apr 2024 02:56:00 -0700 Subject: Update rustc.lua --- xmake/modules/core/tools/rustc.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'xmake/modules/core/tools/rustc.lua') diff --git a/xmake/modules/core/tools/rustc.lua b/xmake/modules/core/tools/rustc.lua index c2bf8db5e..13451aa96 100644 --- a/xmake/modules/core/tools/rustc.lua +++ b/xmake/modules/core/tools/rustc.lua @@ -78,7 +78,8 @@ end -- make the framework flag, crate module function nf_framework(self, framework) local basename = path.basename(framework) - local cratename = basename:match("lib(.-)%-.-") or basename:match("lib(.-)") + -- return "mycrate" from libmycrate-f882feaebb8ba0ca.rlib or libmycrate.rlib + local cratename = basename:match("lib(.-)%-.-") or basename:match("lib(.+)") if cratename then return {"--extern", cratename .. "=" .. framework} end -- cgit v1.3.1