package An official xmake package repository https://xrepo.xmake.io/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
1.3 KiB

4 years ago
package("xorgproto")
set_kind("library", {headeronly = true})
4 years ago
set_homepage("https://www.x.org/")
set_description("X.Org: Protocol Headers")
set_urls("https://xorg.freedesktop.org/archive/individual/proto/xorgproto-$(version).tar.gz")
add_versions("2021.5", "be6ddd6590881452fdfa170c1c9ff87209a98d36155332cbf2ccbc431add86ff")
add_versions("2022.2", "da351a403d07a7006d7bdc8dcfc14ddc1b588b38fb81adab9989a8eef605757b")
add_versions("2023.2", "c791aad9b5847781175388ebe2de85cb5f024f8dabf526d5d699c4f942660cc3")
4 years ago
if is_plat("linux") then
add_extsources("apt::x11proto-dev", "pkgconfig::xproto")
end
if is_plat("macosx", "linux") then
add_deps("pkg-config", "util-macros")
end
4 years ago
on_install("macosx", "linux", function (package)
local configs = {"--sysconfdir=" .. package:installdir("etc"),
"--localstatedir=" .. package:installdir("var"),
"--disable-dependency-tracking",
"--disable-silent-rules"}
import("package.tools.autoconf").install(package, configs)
end)
on_test(function (package)
local envs = {PKG_CONFIG_PATH = path.join(package:installdir(), "share", "pkgconfig")}
os.vrunv("pkg-config", {"--exists", "xproto"}, {envs = envs})
assert(package:has_cincludes("X11/Xproto.h"))
end)