diff options
Diffstat (limited to 'dev-libs/libjwt/libjwt-1.15.3.ebuild')
-rw-r--r-- | dev-libs/libjwt/libjwt-1.15.3.ebuild | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/dev-libs/libjwt/libjwt-1.15.3.ebuild b/dev-libs/libjwt/libjwt-1.15.3.ebuild new file mode 100644 index 000000000000..35757c174d8b --- /dev/null +++ b/dev-libs/libjwt/libjwt-1.15.3.ebuild @@ -0,0 +1,68 @@ +# Copyright 2022-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools + +DESCRIPTION="JWT C Library" +HOMEPAGE="https://github.com/benmcollins/libjwt" +if [[ ${PV} == 9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/benmcollins/libjwt" +else + SRC_URI="https://github.com/benmcollins/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +LICENSE="MPL-2.0" +SLOT="0" +# openssl / gnutls set which ssl implementations to use (build libjwt-ossl.so / libjwt-gnutls.so) +# IF openssl is enabled it will be the implementation used for libjwt.so +# gnutls will only be used for libjwt.so if openssl is disabled +IUSE="gnutls +openssl test" + +REQUIRED_USE=" + || ( gnutls openssl ) +" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-libs/jansson + gnutls? ( + net-libs/gnutls:= + ) + openssl? ( + dev-libs/openssl:= + ) +" + +DEPEND=" + ${RDEPEND} + test? ( dev-libs/check ) +" + +PATCHES=( + "${FILESDIR}/libjwt-1.15.3_multi_ssl_atools.patch" +) + +src_prepare() { + default + eautoreconf +} + +src_configure() { + local myeconfargs=( + --enable-multi-ssl + $(use_with gnutls) + $(use_with openssl) + --with-default-ssl=$(usex openssl openssl gnutls) + ) + + econf "${myeconfargs[@]}" +} + +src_install() { + default + find "${ED}" -name '*.la' -delete || die +} |