Bladeren bron

jsoncpp: fix ninja build

star9029 8 maanden geleden
bovenliggende
commit
87daad242c
1 gewijzigde bestanden met toevoegingen van 8 en 0 verwijderingen
  1. 8 0
      packages/j/jsoncpp/xmake.lua

+ 8 - 0
packages/j/jsoncpp/xmake.lua

@@ -23,7 +23,15 @@ package("jsoncpp")
         table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:is_debug() and "Debug" or "Release"))
         table.insert(configs, "-DBUILD_SHARED_LIBS=" .. (package:config("shared") and "ON" or "OFF"))
         table.insert(configs, "-DBUILD_STATIC_LIBS=" .. (package:config("shared") and "OFF" or "ON"))
+        if package:is_plat("windows") then
+            table.insert(configs, "-DCMAKE_COMPILE_PDB_OUTPUT_DIRECTORY=''")
+        end
         import("package.tools.cmake").install(package, configs)
+
+        if package:is_plat("windows") and package:is_debug() then
+            local dir = package:installdir(package:config("shared") and "bin" or "lib")
+            os.vcp(path.join(package:buildir(), "**.pdb"), dir)
+        end
     end)
 
     on_test(function(package)