forked from semios/ports
59 lines
1.4 KiB
Python
59 lines
1.4 KiB
Python
import glob
|
|
|
|
from lib import cpp
|
|
from lib.make import *
|
|
|
|
version("1.30.4")
|
|
description("Input device management and event handling library")
|
|
maintainer("sisungo <[email protected]>")
|
|
source_url("https://gitlab.freedesktop.org/libinput/libinput/-/archive/1.30.4/libinput-1.30.4.tar.gz")
|
|
|
|
builddep("shortcut/c")
|
|
builddep("shortcut/meson")
|
|
builddep("lxdeviced-libudev-dev @target")
|
|
builddep("libevdev-dev @target")
|
|
builddep("libmtdev-dev @target")
|
|
builddep("libwacom-dev @target")
|
|
builddep("linux-dev @target")
|
|
|
|
|
|
def build():
|
|
cpp.meson_setup([
|
|
"--prefix=/",
|
|
f"--libdir={get_prefix('libinput')}/lib",
|
|
f"--libexecdir={get_prefix('libinput-tools')}/libexec",
|
|
f"--includedir={get_prefix('libinput-dev')}/include",
|
|
"--sysconfdir=/var/config",
|
|
f"--datadir={get_prefix('libinput')}/share",
|
|
"-Ddebug-gui=false",
|
|
"-Dtests=false",
|
|
])
|
|
cpp.meson_compile()
|
|
cpp.meson_install()
|
|
|
|
on_build(build)
|
|
|
|
|
|
def pack(composer):
|
|
composer.makedir("lib")
|
|
for i in glob.glob("lib/*so*"):
|
|
composer.add(i)
|
|
composer.makedir("share")
|
|
composer.add("share/libinput")
|
|
|
|
def pack_tools(composer):
|
|
composer.add("bin")
|
|
composer.add("libexec")
|
|
|
|
package("libinput")
|
|
dep("semi-libc @same-arch")
|
|
on_pack(pack)
|
|
|
|
package("libinput-tools")
|
|
dep("libinput (same)")
|
|
on_pack(pack_tools)
|
|
|
|
package("libinput-dev")
|
|
dep("libinput (same)")
|
|
cpp.use_auto_pack(["dev"])
|