diff options
| author | ruki <[email protected]> | 2024-06-13 22:42:41 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2024-06-13 22:42:41 +0800 |
| commit | 598d43eaadf88c5813454e3e79c8e1d56117360a (patch) | |
| tree | 6160fae83419e45758823d19c48f12e4db4a0053 /xmake/plugins | |
| parent | 2a1d36cd43e3719b34843316e4afd823eb9761d5 (diff) | |
add debian template
Diffstat (limited to 'xmake/plugins')
| -rw-r--r-- | xmake/plugins/pack/xpack.lua | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/xmake/plugins/pack/xpack.lua b/xmake/plugins/pack/xpack.lua index 8af36cdd9..ccf76ebf5 100644 --- a/xmake/plugins/pack/xpack.lua +++ b/xmake/plugins/pack/xpack.lua @@ -321,15 +321,19 @@ end -- get the specfile path function xpack:specfile() - local extensions = { - wix = ".wxs", - nsis = ".nsi", - srpm = ".spec", - rpm = ".spec", - runself = ".lsm" - } - local extension = extensions[self:format()] or ".spec" - return self:get("specfile") or path.join(self:buildir(), self:basename() .. extension) + local specfile = self:get("specfile") + if not specfile then + local extensions = { + wix = ".wxs", + nsis = ".nsi", + srpm = ".spec", + rpm = ".spec", + runself = ".lsm" + } + local extension = extensions[self:format()] or ".spec" + specfile = path.join(self:buildir(), self:basename() .. extension) + end + return specfile end -- get the extension |
