mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-08 06:32:59 -04:00
app-admin/doas-sudo-shim: add doc USE flag for man pages
- Add IUSE="doc" to control optional man page generation - Add BDEPEND on dev-ruby/asciidoctor when USE=doc - Use conditional emake targets (install-exec, install-man) in src_install - Remove redundant S assignment (default value) Signed-off-by: Theron York <theron.york@cloudnuke.org>
This commit is contained in:
@@ -7,15 +7,24 @@ DESCRIPTION="sudo shim that utilizes doas"
|
||||
HOMEPAGE="https://github.com/jirutka/doas-sudo-shim"
|
||||
SRC_URI="https://github.com/jirutka/doas-sudo-shim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
S="${WORKDIR}/${P}"
|
||||
LICENSE="ISC"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64"
|
||||
IUSE="doc"
|
||||
|
||||
BDEPEND="doc? ( dev-ruby/asciidoctor )"
|
||||
RDEPEND="app-admin/doas"
|
||||
|
||||
src_compile() {
|
||||
if use doc; then
|
||||
emake man
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin sudo
|
||||
local targets="install-exec"
|
||||
use doc && targets+=" install-man"
|
||||
emake DESTDIR="${ED}" PREFIX=/usr ${targets}
|
||||
dodoc README.adoc LICENSE
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user