gentoo/dev-libs/argtable3/argtable3-3.3.1.ebuild
Michael Orlitzky b2261fe3b3
dev-libs/argtable3: new package, add 3.3.1
Closes: https://bugs.gentoo.org/709630
Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
2025-08-03 11:47:21 -04:00

45 lines
959 B
Bash

# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake
DESCRIPTION="ANSI C command-line parsing library based on getopt"
HOMEPAGE="https://www.argtable.org/"
SRC_URI="https://github.com/argtable/${PN}/releases/download/v${PV}/argtable-v${PV}.tar.gz"
S="${WORKDIR}/argtable-v${PV}"
# Their LICENSE file is a concatenation; thus is our variable:
#
# * argtable3 itself: BSD
# * FreeBSD getopt: BSD-2
# * TCL/TK: tcltk
# * Hash table: BSD
# * Better string: BSD
#
LICENSE="BSD BSD-2 tcltk"
SLOT="0"
KEYWORDS="~amd64 ~riscv"
IUSE="examples test"
RESTRICT="!test? ( test )"
src_configure() {
local mycmakeargs=(
-DARGTABLE3_ENABLE_TESTS=$(usex test)
-DARGTABLE3_ENABLE_EXAMPLES=OFF # don't _build_ the examples
)
cmake_src_configure
}
src_install() {
cmake_src_install
if use examples; then
docinto examples
dodoc examples/*.c
dodoc -r examples/multicmd
fi
}