diff options
| author | ruki <[email protected]> | 2022-08-05 00:45:59 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2022-08-05 00:45:59 +0800 |
| commit | 88c91ec3ff285ba148a04a01e8e32bdf2b186dc5 (patch) | |
| tree | d0faca1f84258772053d25b85f8fe228228bdb0a /xmake/rules/c++/modules/modules_support/clang.lua | |
| parent | fc011e7ae96d00c209550022ce44f66ec002a474 (diff) | |
use projectdir var
Diffstat (limited to 'xmake/rules/c++/modules/modules_support/clang.lua')
| -rw-r--r-- | xmake/rules/c++/modules/modules_support/clang.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/xmake/rules/c++/modules/modules_support/clang.lua b/xmake/rules/c++/modules/modules_support/clang.lua index c53716d51..00434ef81 100644 --- a/xmake/rules/c++/modules/modules_support/clang.lua +++ b/xmake/rules/c++/modules/modules_support/clang.lua @@ -143,6 +143,7 @@ function generate_headerunits(target, batchcmds, headerunits, opt) local objectfiles = {} local public_flags = {} local private_flags = {} + local projectdir = os.projectdir() for _, headerunit in ipairs(headerunits) do if not headerunit.stl then local file = path.relative(headerunit.path, target:scriptdir()) @@ -150,7 +151,7 @@ function generate_headerunits(target, batchcmds, headerunits, opt) local outdir if headerunit.type == ":quote" then - outdir = path.join(cachedir, path.directory(path.relative(headerunit.path, project.directory()))) + outdir = path.join(cachedir, path.directory(path.relative(headerunit.path, projectdir))) else outdir = path.join(cachedir, path.directory(headerunit.path)) end |
