diff options
| author | ruki <[email protected]> | 2021-06-04 23:31:30 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2021-06-04 23:31:30 +0800 |
| commit | 625261e7ae7159259ac5cb9f4ae304b3ccbf9486 (patch) | |
| tree | 98e4d320a4e9db98ddf12e15dbca251c1c6ae1bc /xmake/actions/package/local/main.lua | |
| parent | e2140bb9755361127959d480bd60f2bcb0469cb1 (diff) | |
improve package
Diffstat (limited to 'xmake/actions/package/local/main.lua')
| -rw-r--r-- | xmake/actions/package/local/main.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/xmake/actions/package/local/main.lua b/xmake/actions/package/local/main.lua index 75c6b4d72..beaaa8862 100644 --- a/xmake/actions/package/local/main.lua +++ b/xmake/actions/package/local/main.lua @@ -32,7 +32,7 @@ function _package_binary(target) -- get the output directory local outputdir = option.get("outputdir") or config.buildir() local packagename = target:name():lower() - if bit.band(packagename:byte(2), 0xc0) == 0x80 then + if #packagename > 1 and bit.band(packagename:byte(2), 0xc0) == 0x80 then wprint("package(%s): cannot generate package, becauese it contains unicode characters!", packagename) return end @@ -88,7 +88,7 @@ function _package_library(target) -- get the output directory local outputdir = option.get("outputdir") or config.buildir() local packagename = target:name():lower() - if bit.band(packagename:byte(2), 0xc0) == 0x80 then + if #packagename > 1 and bit.band(packagename:byte(2), 0xc0) == 0x80 then wprint("package(%s): cannot generate package, becauese it contains unicode characters!", packagename) return end |
