diff options
| author | ruki <[email protected]> | 2024-07-27 00:35:55 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2024-07-27 00:35:55 +0800 |
| commit | d860777fa4df424482cb63723d71ae894002584c (patch) | |
| tree | 8cabfa984c284fd5c2146501e101d23c839bf50f /xmake/modules/core/tools/gcc.lua | |
| parent | db6f72c1020047cf58d76223302c7c4c6810d14b (diff) | |
improve rpath
Diffstat (limited to 'xmake/modules/core/tools/gcc.lua')
| -rw-r--r-- | xmake/modules/core/tools/gcc.lua | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/xmake/modules/core/tools/gcc.lua b/xmake/modules/core/tools/gcc.lua index e33c40c41..9500cbd38 100644 --- a/xmake/modules/core/tools/gcc.lua +++ b/xmake/modules/core/tools/gcc.lua @@ -387,6 +387,10 @@ end -- make the rpathdir flag function nf_rpathdir(self, dir, opt) opt = opt or {} + local extra = opt.extra + if extra and extra.installonly then + return + end dir = path.translate(dir) if self:has_flags("-Wl,-rpath=" .. dir, "ldflags") then local flags = {"-Wl,-rpath=" .. (dir:gsub("@[%w_]+", function (name) @@ -395,7 +399,6 @@ function nf_rpathdir(self, dir, opt) end))} -- add_rpathdirs("...", {runpath = false}) -- https://github.com/xmake-io/xmake/issues/5109 - local extra = opt.extra if extra then if extra.runpath == false and self:has_flags("-Wl,-rpath=" .. dir .. ",--disable-new-dtags", "ldflags") then flags[1] = flags[1] .. ",--disable-new-dtags" |
