diff options
Diffstat (limited to 'xmake/rules/rust')
| -rw-r--r-- | xmake/rules/rust/build/cxxbridge.lua | 27 | ||||
| -rw-r--r-- | xmake/rules/rust/xmake.lua | 4 |
2 files changed, 28 insertions, 3 deletions
diff --git a/xmake/rules/rust/build/cxxbridge.lua b/xmake/rules/rust/build/cxxbridge.lua new file mode 100644 index 000000000..909006632 --- /dev/null +++ b/xmake/rules/rust/build/cxxbridge.lua @@ -0,0 +1,27 @@ +--!A cross-platform build utility based on Lua +-- +-- Licensed under the Apache License, Version 2.0 (the "License"); +-- you may not use this file except in compliance with the License. +-- You may obtain a copy of the License at +-- +-- http://www.apache.org/licenses/LICENSE-2.0 +-- +-- Unless required by applicable law or agreed to in writing, software +-- distributed under the License is distributed on an "AS IS" BASIS, +-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +-- See the License for the specific language governing permissions and +-- limitations under the License. +-- +-- Copyright (C) 2015-present, TBOOX Open Source Group. +-- +-- @author ruki +-- @file cxxbridge.lua +-- + +-- imports +import("core.base.option") +import("lib.detect.find_tool") + +function main(target, batchcmds, sourcefile, opt) + print(sourcefile) +end diff --git a/xmake/rules/rust/xmake.lua b/xmake/rules/rust/xmake.lua index 51e27fcc8..b3599e43b 100644 --- a/xmake/rules/rust/xmake.lua +++ b/xmake/rules/rust/xmake.lua @@ -22,9 +22,7 @@ -- @see https://cxx.rs/build/other.html rule("rust.cxxbridge") set_extensions(".rsx") - before_buildcmd_file(function (target, batchcmds, sourcefile, opt) - print(sourcefile) - end) + before_buildcmd_file("build.cxxbridge") -- define rule: rust.build rule("rust.build") |
