ruki vor 6 Jahren
Ursprung
Commit
aed4c6ec5c
2 geänderte Dateien mit 8 neuen und 3 gelöschten Zeilen
  1. 7 1
      packages/p/python2/xmake.lua
  2. 1 2
      packages/s/skia/xmake.lua

+ 7 - 1
packages/p/python2/xmake.lua

@@ -45,9 +45,15 @@ package("python2")
         -- add openssl libs path for detecting
         io.gsub("setup.py", "/usr/local/ssl", package:dep("openssl"):installdir())
 
+        -- allow python modules to use ctypes.find_library to find xmake's stuff
+        if is_host("macosx") then
+            io.gsub("Lib/ctypes/macholib/dyld.py", "DEFAULT_LIBRARY_FALLBACK = [", format("DEFAULT_LIBRARY_FALLBACK = [ '%s/lib',", package:installdir()))
+        end
+
         -- unset these so that installing pip and setuptools puts them where we want
         -- and not into some other Python the user has installed.
-        import("package.tools.autoconf").install(package, configs, {envs = {PYTHONHOME = "", PYTHONPATH = ""}})
+        import("package.tools.autoconf").configure(package, configs, {envs = {PYTHONHOME = "", PYTHONPATH = ""}})
+        os.vrunv("make", {"install", "-j4", "PYTHONAPPSDIR=" .. package:installdir()})
     end)
 
     on_test(function (package)

+ 1 - 2
packages/s/skia/xmake.lua

@@ -11,7 +11,6 @@ package("skia")
     add_deps("python2", "ninja")
 
     on_install("macosx", "linux", "windows", function (package)
-        --os.vrun("git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git --depth 1")
         local pathes = os.getenv("PATH") or ""
         pathes = pathes .. path.envsep() .. path.join(os.curdir(), "depot_tools")
         pathes = pathes .. path.envsep() .. path.join(os.curdir(), "bin")
@@ -41,7 +40,7 @@ package("skia")
         for k, v in pairs(args) do
             argstr = argstr .. ' ' .. k .. '=' .. tostring(v)
         end
-        os.vrunv("python2", {"tools/git-sync-deps"})--, {envs = {PATH = pathes}})
+        os.vrun("python2 tools/git-sync-deps")
         os.vrun("bin/gn gen build --args='%s'", argstr)
         os.vrun("ninja -C build")
     end)