|
|
|
@ -34,18 +34,14 @@ package("libffi") |
|
|
|
|
end) |
|
|
|
|
|
|
|
|
|
on_install("macosx", "linux", "bsd", "mingw", function (package) |
|
|
|
|
local configs = {"--disable-silent-rules", "--disable-dependency-tracking"} |
|
|
|
|
table.insert(configs, "--libdir=" .. package:installdir("lib"):gsub("\\", "/")) |
|
|
|
|
-- https://github.com/libffi/libffi/issues/127 |
|
|
|
|
local configs = {"--disable-silent-rules", "--disable-dependency-tracking", "--disable-multi-os-directory"} |
|
|
|
|
table.insert(configs, "--enable-shared=" .. (package:config("shared") and "yes" or "no")) |
|
|
|
|
table.insert(configs, "--enable-static=" .. (package:config("shared") and "no" or "yes")) |
|
|
|
|
if package:debug() then |
|
|
|
|
table.insert(configs, "--enable-debug") |
|
|
|
|
end |
|
|
|
|
import("package.tools.autoconf").install(package, configs) |
|
|
|
|
-- @see https://github.com/xmake-io/xmake-repo/pull/2085#issuecomment-1567654930 |
|
|
|
|
if os.isdir(path.join(package:installdir(), "lib64")) then |
|
|
|
|
package:add("linkdirs", "lib", "lib64") |
|
|
|
|
end |
|
|
|
|
end) |
|
|
|
|
|
|
|
|
|
on_test(function (package) |
|
|
|
|