* add kahip

* use cpp test
pull/2459/head
Hoildkv 1 year ago committed by GitHub
parent ad26a87b7c
commit 210015ca0c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 22
      packages/k/kahip/xmake.lua

@ -0,0 +1,22 @@
package("kahip")
set_homepage("https://kahip.github.io/")
set_description("KaHIP - Karlsruhe High Quality Partitioning")
set_license("MIT")
add_urls("https://github.com/KaHIP/KaHIP/archive/refs/tags/$(version).tar.gz",
"https://github.com/KaHIP/KaHIP.git")
add_versions("v3.15", "20760099370ddf7ecb2f92bfdb727def48f6428001165be6ce504264b9a99a0b")
add_deps("cmake", "openmp")
on_install("macosx", "linux", function (package)
local configs = {"-DNOMPI=ON", "-DPARHIP=OFF"}
table.insert(configs, "-DCMAKE_BUILD_TYPE=" .. (package:debug() and "Debug" or "Release"))
import("package.tools.cmake").install(package, configs)
local excess = package:config("shared") and "kahip_static" or "kahip"
os.rm(path.join(package:installdir("lib"), excess .. ".*"))
end)
on_test(function (package)
assert(package:has_cxxfuncs("kaffpa", {includes = "kaHIP_interface.h"}))
end)
Loading…
Cancel
Save