diff options
author | Guillermo Joandet <gjoandet@gmail.com> | 2023-08-08 22:10:55 -0300 |
---|---|---|
committer | Matt Turner <mattst88@gentoo.org> | 2023-08-22 10:03:48 -0400 |
commit | 421f692d3376e61913fb7e487dd204e9f6a2a64d (patch) | |
tree | 2c0df3f3d2ea1d42b5d2d40e9da6fff1409febbd /dev-libs | |
parent | app-editors/ghex: Version bump to 45_beta (diff) | |
download | gentoo-421f692d3376e61913fb7e487dd204e9f6a2a64d.tar.gz gentoo-421f692d3376e61913fb7e487dd204e9f6a2a64d.tar.bz2 gentoo-421f692d3376e61913fb7e487dd204e9f6a2a64d.zip |
dev-libs/libei: New package 1.0.0
Signed-off-by: Guillermo Joandet <gjoandet@gmail.com>
Signed-off-by: Matt Turner <mattst88@gentoo.org>
Diffstat (limited to 'dev-libs')
-rw-r--r-- | dev-libs/libei/Manifest | 2 | ||||
-rw-r--r-- | dev-libs/libei/libei-1.0.0.ebuild | 98 | ||||
-rw-r--r-- | dev-libs/libei/metadata.xml | 11 |
3 files changed, 111 insertions, 0 deletions
diff --git a/dev-libs/libei/Manifest b/dev-libs/libei/Manifest new file mode 100644 index 000000000000..06150d34228d --- /dev/null +++ b/dev-libs/libei/Manifest @@ -0,0 +1,2 @@ +DIST libei-1.0.0.tar.bz2 166254 BLAKE2B 72f9e0426b87e81061e8b01356cfc67897f46219be74c6b7309d2f7b26ea4f6b716ab33a2f9ec16daa0bc555359535b589219eddceced9fa636a2964d32c3d7d SHA512 145b514782fb500bed09437200d0fb989aa0a2cd81d1752938f9b4819ae8130510b2a4a65231bacb8565fcddaa1ffd1925c84cd3a5d34eaa4918ec05105465f6 +DIST munit-fbbdf1467eb0d04a6ee465def2e529e4c87f2118.tar.gz 27724 BLAKE2B 9670c9b7a0b5d9ee6ec8df2dea9e241b043964ecf1fa3f6060ad1d16c40ab6afe47f53c6d4a791003e101a0b363263b858e6e4e445f868292753dd1ee7f7e3ce SHA512 26b5599fd12be627a692823ebf496fa446be7ed04a1233fb42e0667c05109b0f804f76646e289ac660fc815baf45f77ec8caf0ff2ea7fb0b4f87f0038a2b971c diff --git a/dev-libs/libei/libei-1.0.0.ebuild b/dev-libs/libei/libei-1.0.0.ebuild new file mode 100644 index 000000000000..1debac5de82d --- /dev/null +++ b/dev-libs/libei/libei-1.0.0.ebuild @@ -0,0 +1,98 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit meson python-any-r1 + +DESCRIPTION="Library for Emulated Input, primarily aimed at the Wayland stack" +HOMEPAGE="https://gitlab.freedesktop.org/libinput/libei" +SRC_URI="https://gitlab.freedesktop.org/libinput/${PN}/-/archive/${PV}/${P}.tar.bz2" +MUNIT_COMMIT="fbbdf1467eb0d04a6ee465def2e529e4c87f2118" +SRC_URI+=" https://github.com/nemequ/munit/archive/${MUNIT_COMMIT}.tar.gz -> munit-${MUNIT_COMMIT}.tar.gz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64" +IUSE="elogind systemd test" +RESTRICT="!test? ( test )" + +RDEPEND=" + >=dev-libs/libevdev-1.9.902 + || ( + systemd? ( >=sys-apps/systemd-237 ) + elogind? ( >=sys-auth/elogind-237 ) + sys-libs/basu + ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + virtual/pkgconfig + $(python_gen_any_dep ' + dev-python/attrs[${PYTHON_USEDEP}] + dev-python/jinja[${PYTHON_USEDEP}] + ') + test? ( + $(python_gen_any_dep ' + dev-python/pytest[${PYTHON_USEDEP}] + dev-python/python-dbusmock[${PYTHON_USEDEP}] + dev-python/pyyaml[${PYTHON_USEDEP}] + dev-python/structlog[${PYTHON_USEDEP}] + ') + ) +" + +python_check_deps() { + if use test; then + python_has_version \ + "dev-python/pytest[${PYTHON_USEDEP}]" \ + "dev-python/python-dbusmock[${PYTHON_USEDEP}]" \ + "dev-python/pyyaml[${PYTHON_USEDEP}]" \ + "dev-python/structlog[${PYTHON_USEDEP}]" \ + || return 1 + fi + python_has_version \ + "dev-python/attrs[${PYTHON_USEDEP}]" \ + "dev-python/jinja[${PYTHON_USEDEP}]" \ + || return 1 +} + +src_unpack() { + if [[ -n ${A} ]]; then + unpack ${A} + mv "${WORKDIR}"/munit-${MUNIT_COMMIT} "${WORKDIR}"/${P}/subprojects/munit || die + rm "${WORKDIR}"/${P}/subprojects/munit.wrap || die + fi +} + +src_prepare() { + default + + sed -i -e 's:^valgrind = .*:valgrind = disabler():g' test/meson.build || die +} + +src_configure() { + local emesonargs=( + -Ddocumentation="" + -Dliboeffis=enabled + $(meson_feature test tests) + ) + if use systemd; then + emesonargs+=(-Dsd-bus-provider=libsystemd) + elif use elogind; then + emesonargs+=(-Dsd-bus-provider=libelogind) + else + emesonargs+=(-Dsd-bus-provider=basu) + fi + meson_src_configure +} + +src_install() { + meson_src_install + + # munit subproject is installed but not wanted + if use test; then + rm "${ED}"/usr/lib*/libmunit.so || die + fi +} diff --git a/dev-libs/libei/metadata.xml b/dev-libs/libei/metadata.xml new file mode 100644 index 000000000000..4e1ad47f523f --- /dev/null +++ b/dev-libs/libei/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>x11@gentoo.org</email> + <name>X11</name> + </maintainer> + <upstream> + <remote-id type="freedesktop-gitlab">libinput/libei</remote-id> + </upstream> +</pkgmetadata> |