Browse Source

improve libusb

ruki 2 years ago
parent
commit
aeb2768c5b
1 changed files with 3 additions and 0 deletions
  1. 3 0
      packages/l/libusb/xmake.lua

+ 3 - 0
packages/l/libusb/xmake.lua

@@ -88,6 +88,9 @@ package("libusb")
         local configs = {}
         local configs = {}
         table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no"))
         table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no"))
         table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes"))
         table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes"))
+        if package:config("pic") ~= false then
+            table.insert(configs, "--with-pic")
+        end
         local cflags, ldflags
         local cflags, ldflags
         if package:is_plat("linux") then
         if package:is_plat("linux") then
             cflags = "-I" .. package:dep("eudev"):installdir("include")
             cflags = "-I" .. package:dep("eudev"):installdir("include")