add krb5 and gobject-introspection (#683)

* add krb5

* add gobject-introspection

* update harfbuzz
pull/684/head
Hoildkv 3 years ago committed by GitHub
parent eb4711f89f
commit ce1446e7a1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 28
      packages/g/gobject-introspection/xmake.lua
  2. 1
      packages/h/harfbuzz/xmake.lua
  3. 44
      packages/k/krb5/xmake.lua

@ -0,0 +1,28 @@
package("gobject-introspection")
set_homepage("https://gi.readthedocs.io/en/latest/")
set_description("GObject introspection is a middleware layer between C libraries (using GObject) and language bindings.")
set_license("LGPL-2.0")
add_urls("https://download.gnome.org/sources/gobject-introspection/$(version).tar.xz", {version = function (version)
return format("%d.%d/gobject-introspection-%s", version:major(), version:minor(), version)
end})
add_versions("1.70.0", "902b4906e3102d17aa2fcb6dad1c19971c70f2a82a159ddc4a94df73a3cafc4a")
add_configs("shared", {description = "Build shared library.", default = true, type = "boolean", readonly = true})
if is_plat("linux") then
add_extsources("apt::libgirepository1.0-dev")
end
add_deps("meson", "ninja", "pkg-config", "python 3.x", "flex", "bison")
add_deps("glib", {configs = {shared = true}})
add_includedirs("include/gobject-introspection-1.0")
on_install("macosx", "linux", function (package)
import("package.tools.meson").install(package)
package:addenv("PATH", "bin")
end)
on_test(function (package)
assert(package:has_cfuncs("g_irepository_get_default", {includes = "girepository.h"}))
end)

@ -9,6 +9,7 @@ package("harfbuzz")
add_versions("2.8.1", "b3f17394c5bccee456172b2b30ddec0bb87e9c5df38b4559a973d14ccd04509d")
add_versions("2.9.0", "bf5d5bad69ee44ff1dd08800c58cb433e9b3bf4dad5d7c6f1dec5d1cf0249d04")
add_versions("3.0.0", "55f7e36671b8c5569b6438f80efed2fd663298f785ad2819e115b35b5587ef69")
add_versions("3.1.1", "5283c7f5f1f06ddb5e2e88319f6946ea37d2eb3a574e0f73f6000de8f9aa34e6")
add_configs("icu", {description = "Enable ICU library unicode functions.", default = false, type = "boolean"})
add_configs("freetype", {description = "Enable freetype interop helpers.", default = true, type = "boolean"})

@ -0,0 +1,44 @@
package("krb5")
set_homepage("http://web.mit.edu/kerberos/")
set_description("Kerberos: The Network Authentication Protocol")
add_urls("https://kerberos.org/dist/krb5/$(version).tar.gz", {version = function (version)
return format("%d.%d/krb5-%s", version:major(), version:minor(), version)
end})
add_versions("1.19.2", "10453fee4e3a8f8ce6129059e5c050b8a65dab1c257df68b99b3112eaa0cdf6a")
add_configs("tls", {description = "Enable TLS/OpenSSL support.", default = false, type = "boolean"})
add_configs("shared", {description = "Build shared library.", default = true, type = "boolean", readonly = true})
add_deps("bison", "libverto")
add_links("k5crypto", "kdb5", "krad", "gssapi_krb5", "krb5support", "krb5", "gssrpc", "verto", "com_err")
on_load("macosx", "linux", function (package)
if package:config("tls") then
package:add("deps", "openssl")
end
end)
on_install("macosx", "linux", function (package)
os.cd("src")
local configs = {"--disable-dependency-tracking", "--with-system-verto"}
table.insert(configs, "--with-tls-impl=" .. (package:config("tls") and "openssl" or "no"))
local cppflags = {}
local ldflags = {}
for _, dep in ipairs(package:orderdeps()) do
local fetchinfo = dep:fetch()
if fetchinfo then
for _, includedir in ipairs(fetchinfo.includedirs or fetchinfo.sysincludedirs) do
table.insert(cppflags, "-I" .. includedir)
end
for _, linkdir in ipairs(fetchinfo.linkdirs) do
table.insert(ldflags, "-L" .. linkdir)
end
end
end
import("package.tools.autoconf").install(package, configs, {cppflags = cppflags, ldflags = ldflags})
end)
on_test(function (package)
assert(package:has_cfuncs("krb5_c_encrypt", {includes = "krb5.h"}))
end)
Loading…
Cancel
Save