gentoo/sys-block/mmc-utils/mmc-utils-1.0.ebuild
Sam James e07d9ef6b0
sys-block/mmc-utils: Stabilize 1.0 amd64, #962516
Signed-off-by: Sam James <sam@gentoo.org>
2025-09-24 02:14:38 +01:00

51 lines
909 B
Bash

# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit toolchain-funcs
DESCRIPTION="Userspace tools for MMC/SD devices"
HOMEPAGE="https://git.kernel.org/pub/scm/utils/mmc/mmc-utils.git/"
SRC_URI="https://git.kernel.org/pub/scm/utils/mmc/mmc-utils.git/snapshot/mmc-utils-${PV}.tar.gz"
LICENSE="GPL-2 BSD"
SLOT="0"
KEYWORDS="amd64 ~arm64"
IUSE="doc"
RDEPEND="!dev-lang/mercury"
BDEPEND="doc? ( dev-python/sphinx )"
src_prepare() {
default
sed -i \
-e '/^GIT_VERSION /d' \
-e 's/-Werror //' \
-e 's/-D_FORTIFY_SOURCE=2 //' \
-e "s/-DVERSION=.*/-DVERSION=\\\\\"gentoo-${PVR}\\\\\"/" \
Makefile || die
}
src_configure() {
tc-export CC
}
src_compile() {
emake C=0
use doc && emake -C docs html
}
src_install() {
dosbin mmc
dodoc README
doman man/mmc.1
if use doc; then
docinto html
dodoc -r docs/_build/html/.
fi
}