games-roguelike/cataclysm-dda: Add doc USE flag and install man pages

Signed-off-by: strategictraveler <strategictraveler@proton.me>
This commit is contained in:
strategictraveler
2025-01-14 11:54:00 +00:00
parent 5c98216724
commit d6e86fdd73
2 changed files with 20 additions and 4 deletions

View File

@@ -1,4 +1,4 @@
# Copyright 2024 Gentoo Authors
# Copyright 2024-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -31,7 +31,7 @@ fi
# CC-BY-SA-4.0 for soundpack
LICENSE="Apache-2.0 CC-BY-SA-3.0 CC-BY-SA-4.0 MIT OFL-1.1 Unicode-3.0"
IUSE="debug ncurses nls +sound +soundpack test +tiles"
IUSE="debug doc ncurses nls +sound +soundpack test +tiles"
REQUIRED_USE="soundpack? ( sound ) sound? ( tiles ) \
|| ( tiles ncurses )"
RESTRICT="!test? ( test )"
@@ -50,6 +50,7 @@ RDEPEND="
)"
DEPEND="${RDEPEND}"
BDEPEND="
doc? ( app-text/doxygen[dot] )
soundpack? ( app-arch/unzip )
nls? ( sys-devel/gettext )
"
@@ -121,6 +122,8 @@ src_compile() {
use nls && export LANGUAGES="all"
use doc && doxygen doxygen_doc/doxygen_conf.txt || die "Failed to generate docs"
if use ncurses; then
# don't build tests twice
if ! use tiles; then
@@ -151,6 +154,11 @@ src_install() {
[[ -e "${WORKDIR}/cataclysm-${SLOT}" ]] && dobin "${WORKDIR}/cataclysm-${SLOT}"
use doc && dodoc -r doxygen_doc/html
use tiles && newman "doc/cataclysm-tiles.6" "cataclysm-tiles-${SLOT}.6"
use ncurses && newman "doc/cataclysm.6" "cataclysm-${SLOT}.6"
if use soundpack; then
insinto "/usr/share/${PN}-${SLOT}/sound"
doins -r "${WORKDIR}/CC-Sounds"

View File

@@ -1,4 +1,4 @@
# Copyright 2024 Gentoo Authors
# Copyright 2024-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -31,7 +31,7 @@ fi
# CC-BY-SA-4.0 for soundpack
LICENSE="Apache-2.0 CC-BY-SA-3.0 CC-BY-SA-4.0 MIT OFL-1.1 Unicode-3.0"
IUSE="debug ncurses nls +sound +soundpack test +tiles"
IUSE="debug doc ncurses nls +sound +soundpack test +tiles"
REQUIRED_USE="soundpack? ( sound ) sound? ( tiles ) \
|| ( tiles ncurses )"
RESTRICT="!test? ( test )"
@@ -50,6 +50,7 @@ RDEPEND="
)"
DEPEND="${RDEPEND}"
BDEPEND="
doc? ( app-text/doxygen[dot] )
nls? ( sys-devel/gettext )
"
@@ -115,6 +116,8 @@ src_compile() {
use nls && export LANGUAGES="all"
use doc && doxygen doxygen_doc/doxygen_conf.txt || die "Failed to generate docs"
if use ncurses; then
# don't build tests twice
if ! use tiles; then
@@ -145,6 +148,11 @@ src_install() {
[[ -e "${WORKDIR}/cataclysm-${SLOT}" ]] && dobin "${WORKDIR}/cataclysm-${SLOT}"
use doc && dodoc -r doxygen_doc/html
use tiles && newman "doc/cataclysm-tiles.6" "cataclysm-tiles-${SLOT}.6"
use ncurses && newman "doc/cataclysm.6" "cataclysm-${SLOT}.6"
if use soundpack; then
insinto "/usr/share/${PN}-${SLOT}/sound"
doins -r "${WORKDIR}/CC-Sounds"