gentoo/dev-libs/yaz/yaz-5.35.1.ebuild
Nicolas PARLANT 5db7e8012e
dev-libs/yaz: add 5.35.1
rm features :
ziffy, separate package since 3.0.20, remove its license GPL-2
openssl, removed since 5.0.13

add features :
memcached with dev-libs/libmemcached, since 5.0.13
redis with dev-libs/hiredis, since 5.2.0

set PACKAGE_SUFFIX to install doc cleaner

it compiles fine with libxml2:2/16

one patch to fix musl building

Bugs :
close the old bug for tcpd (#730016)
compilation is fixed with c23 (#945028 #945062)

Bug: https://bugs.gentoo.org/945028
Bug: https://bugs.gentoo.org/945062
Closes: https://bugs.gentoo.org/730016
Signed-off-by: Nicolas PARLANT <nicolas.parlant@parhuet.fr>
Part-of: https://github.com/gentoo/gentoo/pull/42864
Closes: https://github.com/gentoo/gentoo/pull/42864
Signed-off-by: Sam James <sam@gentoo.org>
2025-07-04 21:00:25 +01:00

79 lines
1.5 KiB
Bash

# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools
DESCRIPTION="C/C++ toolkit for Z39.50v3 clients and servers"
HOMEPAGE="https://www.indexdata.com/resources/software/yaz/"
if [[ ${PV} == *9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/indexdata/yaz.git"
else
SRC_URI="https://ftp.indexdata.com/pub/${PN}/${P}.tar.gz"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~s390 ~sparc ~x86"
fi
LICENSE="BSD"
SLOT="0/5"
IUSE="memcached redis tcpd"
RDEPEND="
dev-libs/icu:=
dev-libs/libxml2:=
dev-libs/libxslt
net-libs/gnutls:=
sys-libs/readline:=
virtual/libintl
memcached? ( dev-libs/libmemcached )
redis? ( dev-libs/hiredis:= )
tcpd? ( sys-apps/tcp-wrappers )
"
DEPEND="${RDEPEND}"
BDEPEND="
app-alternatives/yacc
dev-build/libtool:2
dev-lang/tcl:0
virtual/pkgconfig
"
PATCHES=(
"${FILESDIR}"/${P}-fix_musl.patch
)
DOCS=( NEWS README.md )
src_prepare() {
default
# Hardcoded assumption of libraries residing in lib/, bug #730016
sed -i -e "s|/lib\"|/$(get_libdir)\"|" configure.ac || die
eautoreconf
}
src_configure() {
local myeconfargs=(
$(use_with memcached)
$(use_with redis)
$(use_enable tcpd tcpd /usr)
)
econf "${myeconfargs[@]}"
}
src_install() {
local myemakeargs=(
DESTDIR="${D}"
docdir="${EPREFIX}/usr/share/doc/${PF}/html"
# move common dir in html
PACKAGE_SUFFIX="-${PV}/html"
)
emake "${myemakeargs[@]}" install
find "${D}" -name '*.la' -delete || die
einstalldocs
}