Skip to content

Commit

Permalink
libdrm: add 2.4.123 version
Browse files Browse the repository at this point in the history
  • Loading branch information
star-hengxing committed Nov 5, 2024
1 parent 14f527a commit 4a0faa1
Showing 1 changed file with 23 additions and 6 deletions.
29 changes: 23 additions & 6 deletions packages/l/libdrm/xmake.lua
Original file line number Diff line number Diff line change
@@ -1,16 +1,33 @@
package("libdrm")

set_homepage("https://gitlab.freedesktop.org/mesa/drm")
set_description("libdrm - userspace library for drm (direct rendering manager)")
set_license("MIT")

add_urls("https://dri.freedesktop.org/libdrm/libdrm-$(version).tar.xz",
"https://gitlab.freedesktop.org/mesa/drm.git")

add_urls("https://dri.freedesktop.org/libdrm/libdrm-$(version).tar.xz")
add_versions("2.4.123", "a2b98567a149a74b0f50e91e825f9c0315d86e7be9b74394dae8b298caadb79e")
add_versions("2.4.118", "a777bd85f2b5fc9c57f886c82058300578317cafdbc77d0a769d7e9a9567ab88")

add_deps("meson", "ninja")
if is_plat("linux") then
add_extsources("pkgconfig::libdrm", "pacman::libdrm", "apt::libdrm-dev")
elseif is_plat("macosx") then
add_extsources("brew::libdrm")
end

add_includedirs("include", "include/libdrm")
add_extsources("pkgconfig::libdrm", "pacman::libdrm", "apt::libdrm-dev")
on_install("linux", function (package)
local configs = {"-Dudev=true", "-Dvalgrind=disabled", "-Dman-pages=disabled", "-Dtests=false", "-Dcairo-tests=disabled", "-Dinstall-test-programs=false"}

add_deps("meson", "ninja")

on_install("linux", "macosx", "bsd", function (package)
local configs = {
"-Dudev=true",
"-Dvalgrind=disabled",
"-Dman-pages=disabled",
"-Dtests=false",
"-Dcairo-tests=disabled",
"-Dinstall-test-programs=false",
}
table.insert(configs, "-Ddefault_library=" .. (package:config("shared") and "shared" or "static"))
import("package.tools.meson").install(package, configs)
end)
Expand Down

0 comments on commit 4a0faa1

Please sign in to comment.