diff options
| author | James Le Cuirot <chewi@gentoo.org> | 2025-07-01 22:04:14 +0100 |
|---|---|---|
| committer | James Le Cuirot <chewi@gentoo.org> | 2025-07-01 22:26:18 +0100 |
| commit | c3278243d7c3d66bc0ebb249cf7ff66e4f17041f (patch) | |
| tree | 26fa401f6028ca56fb092817093be2b156228498 /dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild | |
| parent | 21afe87705e59ede961d03d7a99fbdd2cf0b42ca (diff) | |
| download | gentoo-c3278243d7c3d66bc0ebb249cf7ff66e4f17041f.tar.gz gentoo-c3278243d7c3d66bc0ebb249cf7ff66e4f17041f.tar.bz2 gentoo-c3278243d7c3d66bc0ebb249cf7ff66e4f17041f.zip | |
dev-cpp/sdbus-c++: Version bump to 2.1.0
Signed-off-by: James Le Cuirot <chewi@gentoo.org>
Diffstat (limited to 'dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild')
| -rw-r--r-- | dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild b/dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild new file mode 100644 index 000000000000..bcf6e7103708 --- /dev/null +++ b/dev-cpp/sdbus-c++/sdbus-c++-2.1.0.ebuild @@ -0,0 +1,76 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit meson cmake + +DESCRIPTION="High-level C++ D-Bus library" +HOMEPAGE="https://github.com/Kistler-Group/sdbus-cpp" +SRC_URI="https://github.com/Kistler-Group/sdbus-cpp/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/sdbus-cpp-${PV}" + +LICENSE="LGPL-2.1+ Nokia-Qt-LGPL-Exception-1.1" # Nothing to do with Qt but exception text is exactly the same. +SLOT="0/2" +KEYWORDS="~amd64" +IUSE="doc +elogind systemd test tools" +REQUIRED_USE="?? ( elogind systemd )" +RESTRICT="!test? ( test )" + +RDEPEND=" + elogind? ( >=sys-auth/elogind-252 ) + systemd? ( >=sys-apps/systemd-252:= ) + !elogind? ( !systemd? ( >=sys-libs/basu-0.2.1 ) ) + tools? ( dev-libs/expat ) +" + +DEPEND=" + ${RDEPEND} + test? ( >=dev-cpp/gtest-1.14.0 ) +" + +BDEPEND=" + virtual/pkgconfig + doc? ( app-text/doxygen[dot] ) +" + +src_configure() { + local mycmakeargs=( + -DSDBUSCPP_BUILD_CODEGEN=$(usex tools) + -DSDBUSCPP_BUILD_DOCS=yes + -DSDBUSCPP_BUILD_DOXYGEN_DOCS=$(usex doc) + -DSDBUSCPP_BUILD_LIBSYSTEMD=no + -DSDBUSCPP_BUILD_TESTS=$(usex test) + ) + cmake_src_configure +} + +src_compile() { + cmake_src_compile all $(usev doc) +} + +src_test() { + if ! cmp -s {"${S}"/tests/integrationtests/files,/etc/dbus-1/system.d}/org.sdbuscpp.integrationtests.conf; then + ewarn "Not running the tests as a D-Bus configuration file has not been" + ewarn "installed yet or has changed since. The tests can be run after" + ewarn "the package has been merged." + return + elif [[ ! -S /run/dbus/system_bus_socket ]]; then + ewarn "Not running the tests as the system-wide D-Bus daemon is unavailable." + return + fi + + # Can't use cmake_src_test with dbus-run-session. Don't bother with all the + # extra arguments because there's only two tests. + dbus-run-session ctest --test-dir "${BUILD_DIR}" || die +} + +src_install() { + cmake_src_install + rm -v "${ED}"/usr/share/doc/${PF}/COPYING || die + + if use test; then + # Delete installed test binaries. + rm -rv "${ED}"/usr/tests || die + fi +} |
