sys-apps/azure-vm-utils: Sync with Gentoo

It's from Gentoo commit d75640ff844729b646ebe88a4915a06b4b6b7aba.
This commit is contained in:
Flatcar Buildbot 2025-04-28 07:18:10 +00:00
parent d1ad5e5855
commit aeb9630104
5 changed files with 73 additions and 29 deletions

View File

@ -1,2 +1,2 @@
DIST azure-vm-utils-0.4.0.tar.gz 15688 BLAKE2B 4a8f5b28a01b3670d81cbc9ae43c24b6177d90ddc3bf6e78a3ccc7406361474d2aa7dce934709fdb73cc0930616475e79ef8484e05bf34354668909e5d8a1c96 SHA512 e97f6de49f0ee9281d17c2be0f4c0e0d86385d113fd514e28fc14f635669a1abdddd83961193941b6969b2b0d41a357e4211357f8c226d84f698166c2eb21b8e
DIST azure-vm-utils-0.5.2.tar.gz 42079 BLAKE2B e5380af38f072b15adb5b25b3df77fea699e88cddc1dd2779a263d63ee795cf79f3df8127265aebbdb031f96dbcfa10e36be71ebca35998f9d7e860b74b753e0 SHA512 2df38df001ee08da68543a8597c485b8f2b4e50fcdbe93defb443a1905fbc87ed5c2ef7903b79d795733b78e37fa8584a4ce33082b7a4490a1c7c4a8e5d8fcac
DIST azure-vm-utils-0.6.0.tar.gz 48676 BLAKE2B c58a68ffcfa25fdab554c501de30e859f38b949ad7da215b9cf59b5884688a52b7279af2aec0c4dfe80d5240e8baa7460bb8c3e0800235ba7e676a78ac2e90b0 SHA512 f54dc3c6ca45b50a063a9c774f94cec3dd01e910088dbcbbf1ce279dc0c4874aa0fe2b27c9596248c137f787e9be51190cacb0d5ab8ab0cdd4ba994f60b64ddc

View File

@ -1,28 +0,0 @@
# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake udev
DESCRIPTION="Utilities and udev rules to support Linux on Azure"
HOMEPAGE="https://github.com/Azure/azure-vm-utils"
SRC_URI="https://github.com/Azure/${PN}/archive/refs/tags/v${PV}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm64"
src_configure() {
local mycmakeargs=(
-DUDEV_RULES_INSTALL_DIR="$(get_udevdir)/rules.d"
)
cmake_src_configure
}
pkg_postinst() {
udev_reload
}
pkg_postrm() {
udev_reload
}

View File

@ -14,9 +14,19 @@ KEYWORDS="~amd64 ~arm64"
IUSE="test"
RESTRICT="!test? ( test )"
CDEPEND="
dev-libs/json-c:=
"
DEPEND="
${CDEPEND}
test? ( dev-util/cmocka )
"
RDEPEND="
${CDEPEND}
"
BDEPEND="
virtual/pkgconfig
"
src_configure() {
local mycmakeargs=(

View File

@ -0,0 +1,59 @@
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake udev
DESCRIPTION="Utilities and udev rules to support Linux on Azure"
HOMEPAGE="https://github.com/Azure/azure-vm-utils"
SRC_URI="https://github.com/Azure/${PN}/archive/refs/tags/v${PV}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm64"
IUSE="dracut test"
RESTRICT="!test? ( test )"
CDEPEND="
dev-libs/json-c:=
"
DEPEND="
${CDEPEND}
test? ( dev-util/cmocka )
"
RDEPEND="
${CDEPEND}
dracut? ( sys-kernel/dracut )
"
BDEPEND="
virtual/pkgconfig
"
src_configure() {
local mycmakeargs=(
-DDRACUT=$(usex dracut dracut "")
-DENABLE_TESTS=$(usex test)
-DINITRAMFS_TOOLS=
-DUDEV_RULES_INSTALL_DIR="$(get_udevdir)/rules.d"
-DVERSION="v${PV}"
)
cmake_src_configure
}
src_install() {
cmake_src_install
# Remove post-install test that only works on Azure.
rm -v \
"${ED}"/usr/sbin/azure-vm-utils-selftest \
"${ED}"/usr/share/man/man*/azure-vm-utils-selftest.* \
|| die
}
pkg_postinst() {
udev_reload
}
pkg_postrm() {
udev_reload
}

View File

@ -5,6 +5,9 @@
<email>chewi@gentoo.org</email>
<name>James Le Cuirot</name>
</maintainer>
<use>
<flag name="dracut">Install dracut module</flag>
</use>
<upstream>
<remote-id type="github">Azure/azure-vm-utils</remote-id>
</upstream>