Apocrypha

pupgrade-0.5.1_betamasterwolf

# Copyright 1999-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

inherit git-r3 autotools

DESCRIPTION="TUI and CLI wrappers for Gentoo system upgrades, written in B and C"
HOMEPAGE="https://gitlab.com/masterwolf/pupgrade"
EGIT_REPO_URI="https://gitlab.com/masterwolf/pupgrade.git"
EGIT_BRANCH="testing"
EGIT_COMMIT="b3ce84c711e9b30ed2a90e22fc4f0da4d4b82652"

S="${WORKDIR}/${P}/source"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS=""

IUSE="chrooter tui"

RDEPEND="
dev-util/dialog
app-shells/bash
chrooter? ( app-admin/chrooter )
app-portage/eix
"

DEPEND="${RDEPEND}"

BDEPEND="
tui? ( sys-devel/b )"

src_prepare() {
eautoreconf
default
}

src_compile() {

emake
}

src_install() {
dobin pupgrade

if use tui; then
	dobin tuipupgrade
fi
}

# B actually uses CFLAGS, but somehow portage does not notice that...
QA_FLAGS_IGNORED="/usr/bin/tuipupgrade"