diff options
| author | ruki <[email protected]> | 2020-11-07 00:34:04 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2020-11-07 00:34:04 +0800 |
| commit | ba62268d4a1cd7db9e66f52e08a393eb6cc2df90 (patch) | |
| tree | 6f83dc48c3f5170c93b2345c44d0c183b5ef759e /xmake/modules/package/tools/cmake.lua | |
| parent | 8d83314b65dfe66b35b961e220f98a65a5705d62 (diff) | |
install bin for tools/cmake
Diffstat (limited to 'xmake/modules/package/tools/cmake.lua')
| -rw-r--r-- | xmake/modules/package/tools/cmake.lua | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/xmake/modules/package/tools/cmake.lua b/xmake/modules/package/tools/cmake.lua index c81958826..77a204e8b 100644 --- a/xmake/modules/package/tools/cmake.lua +++ b/xmake/modules/package/tools/cmake.lua @@ -323,12 +323,13 @@ function _install_for_msvc(package, configs, opt) local projfile = os.isfile("INSTALL.vcxproj") and "INSTALL.vcxproj" or "INSTALL.vcproj" if os.isfile(projfile) then os.vrunv(msbuild.program, {projfile, "/property:configuration=" .. (package:debug() and "Debug" or "Release")}, {envs = runenvs}) + os.trycp("install/bin", package:installdir()) os.trycp("install/lib", package:installdir()) -- perhaps only headers library os.trycp("install/include", package:installdir()) else - os.cp("**.lib", package:installdir("lib")) - os.cp("**.dll", package:installdir("lib")) - os.cp("**.exp", package:installdir("lib")) + os.trycp("**.dll", package:installdir("bin")) + os.trycp("**.lib", package:installdir("lib")) + os.trycp("**.exp", package:installdir("lib")) end end @@ -345,9 +346,7 @@ function _install_files_for_cmake(package, opt) local prefixdir_new = package:installdir() io.replace(cmakefile, prefixdir_old, prefixdir_new, {plain = true}) end - if (opt and opt.binary) or package:kind() == "binary" then - os.trycp("install/bin", package:installdir()) - end + os.trycp("install/bin", package:installdir()) os.trycp("install/lib", package:installdir()) os.trycp("install/include", package:installdir()) end |
