summaryrefslogtreecommitdiff
path: root/tests/projects
diff options
context:
space:
mode:
Diffstat (limited to 'tests/projects')
-rw-r--r--tests/projects/c++/shared_library_export_all/xmake.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/projects/c++/shared_library_export_all/xmake.lua b/tests/projects/c++/shared_library_export_all/xmake.lua
index 33d2c7d0c..bc7b0dd68 100644
--- a/tests/projects/c++/shared_library_export_all/xmake.lua
+++ b/tests/projects/c++/shared_library_export_all/xmake.lua
@@ -9,8 +9,9 @@ target("bar")
set_kind("shared")
add_files("src/bar.cpp")
add_rules("utils.symbols.export_all", {export_filter = function (symbol, opt)
- local objectfile = opt.objectfile
- if objectfile:find("bar.cpp", 1, true) and symbol:find("add", 1, true) then
+ local filepath = opt.sourcefile or opt.objectfile
+ if filepath and filepath:find("bar.cpp", 1, true) and symbol:find("add", 1, true) then
+ print("export: %s at %s", symbol, filepath)
return true
end
end})