From db70871b2044b9bfde346d6f4027dafb0a013c4c Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Thu, 15 Jun 2023 13:38:09 +0100 Subject: gentoo auto-resync : 15:06:2023 - 13:38:09 --- dev-cpp/jwt-cpp/Manifest | 4 ++ dev-cpp/jwt-cpp/files/jwt-cpp-0.6.0-gcc13.patch | 14 +++++ dev-cpp/jwt-cpp/jwt-cpp-0.6.0.ebuild | 82 +++++++++++++++++++++++++ dev-cpp/jwt-cpp/metadata.xml | 23 +++++++ 4 files changed, 123 insertions(+) create mode 100644 dev-cpp/jwt-cpp/Manifest create mode 100644 dev-cpp/jwt-cpp/files/jwt-cpp-0.6.0-gcc13.patch create mode 100644 dev-cpp/jwt-cpp/jwt-cpp-0.6.0.ebuild create mode 100644 dev-cpp/jwt-cpp/metadata.xml (limited to 'dev-cpp/jwt-cpp') diff --git a/dev-cpp/jwt-cpp/Manifest b/dev-cpp/jwt-cpp/Manifest new file mode 100644 index 000000000000..0ea92cc67532 --- /dev/null +++ b/dev-cpp/jwt-cpp/Manifest @@ -0,0 +1,4 @@ +AUX jwt-cpp-0.6.0-gcc13.patch 284 BLAKE2B e7ed4329fe924206433c0e6e44136f8e06ded871f7e6fe85c3506901a58b316e9f79690776840ec826ff0f211b5ff72b9c2e68b946e34512afb8deefc99b331c SHA512 8311df0a0c46f5b422acdbb789600c0c1e26a2f87ffe80eb6b968da6a1b62cebe427b8c09ffb5586d48bb26afb1308af6c9524d6d2eb36dafc6849372cab3979 +DIST jwt-cpp-0.6.0.tar.gz 275126 BLAKE2B 4bf9bed9b2aa9584b497b2ab4d1d2582d9b5e4ded402200ea3f70b0e6752338fd4e2ef9c5836c728a6907a0190209c7baeaecd26032ce64dc6bf12a23594f27b SHA512 b6d5ebb3a7eeb6fef9a1d41c707251d1ab05bf47920c280d5203f1b9ee5bf6f8e914cd2ffaed66550cfa6d78c34465d4cf86517a759d5f8739b429faf1c2c0ef +EBUILD jwt-cpp-0.6.0.ebuild 1988 BLAKE2B 7972ddf9ab53b277b7de34d9d36e739f7898bf4d55d02afefe661d48705ece07b2e82d54cd1e8d4dae0f339e4d8b763e83a3861dd956479be8cbfcf9b99809b6 SHA512 5c8406f025e08b017b1b88f3cb920f81a9c3dcc4dfb6b724d32102540ce749fe7f59bfa04b10ce52e38a4864891dd6c93228e4cbeeb33d815a9e8eb0d81afa80 +MISC metadata.xml 783 BLAKE2B 6c1156aa5c7466acf0dc97db88e228d0dd1a15e9938df61c9ca4d1b4d80fa38aacbc2e3034c91deb4a4b7a4076c61511a34f8f72d4d077987577666c393a7fcc SHA512 3ca38fd435697019e10b292019355786d92e258ba8deb37f035a2d767c0bab9450560a03619b660f383cce794c24bc7bbd6ac23a0a902ca7654afccc432b8121 diff --git a/dev-cpp/jwt-cpp/files/jwt-cpp-0.6.0-gcc13.patch b/dev-cpp/jwt-cpp/files/jwt-cpp-0.6.0-gcc13.patch new file mode 100644 index 000000000000..3fef24536a86 --- /dev/null +++ b/dev-cpp/jwt-cpp/files/jwt-cpp-0.6.0-gcc13.patch @@ -0,0 +1,14 @@ +From: Hannu Lounento +Bug: https://github.com/Thalhammer/jwt-cpp/pull/287 + +Fix build with GCC 13. + +--- a/include/jwt-cpp/base.h ++++ b/include/jwt-cpp/base.h +@@ -3,6 +3,7 @@ + + #include ++#include + #include + #include + diff --git a/dev-cpp/jwt-cpp/jwt-cpp-0.6.0.ebuild b/dev-cpp/jwt-cpp/jwt-cpp-0.6.0.ebuild new file mode 100644 index 000000000000..8d2bc1f2fe86 --- /dev/null +++ b/dev-cpp/jwt-cpp/jwt-cpp-0.6.0.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +if [[ ${PV} == *9999* ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/Thalhammer/jwt-cpp.git" +else + SRC_URI="https://github.com/Thalhammer/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" +fi + +DESCRIPTION="header only library for creating and validating JSON Web Tokens in C++11" +HOMEPAGE="https://thalhammer.github.io/jwt-cpp/" + +LICENSE="MIT" +SLOT="0" +IUSE="doc +picojson test" + +DEPEND=" + dev-cpp/nlohmann_json + dev-libs/openssl + picojson? ( dev-cpp/picojson ) +" +RDEPEND="${DEPEND}" +BDEPEND=" + doc? ( app-doc/doxygen[dot] ) + test? ( dev-cpp/gtest ) +" +RESTRICT=" + !picojson? ( test ) + !test? ( test ) +" +PATCHES=( + "${FILESDIR}"/"${PN}"-0.6.0-gcc13.patch +) +DOCS=( README.md docs/{faqs,ssl,traits}.md ) + +src_prepare() { + # Unbundle dev-cpp/nlohmann_json. + rm -vrf include/nhlomann || die + # Unbundle dev-cpp/picojson and fix include paths. + # See also: https://github.com/Thalhammer/jwt-cpp/issues/213 + rm -vrf include/picojson || die + find -name '*.h' -type f -print0 | xargs -0 sed -r -e "s:picojson/picojson\.h:picojson.h:g" -i || die + # Prevent installation of bundled dev-cpp/picojson. + sed -i -e 's:^\s*install.*picojson/picojson\.h.*$::' CMakeLists.txt || die + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DJWT_DISABLE_PICOJSON="$(usex !picojson)" + # Not useful for now, asks for non-existent CMake module. + #-DJWT_EXTERNAL_PICOJSON="$(usex picojson)" + # Examples are not installed and for development only. + -DJWT_BUILD_EXAMPLES=NO + -DJWT_BUILD_TESTS="$(usex test)" + -DJWT_CMAKE_FILES_INSTALL_DIR="${EPREFIX}"/usr/share/cmake + ) + cmake_src_configure +} + +src_compile() { + cmake_src_compile + if use doc; then + doxygen || die + fi +} + +src_test() { + "${BUILD_DIR}"/tests/jwt-cpp-test || die +} + +src_install() { + cmake_src_install + use doc && local HTML_DOCS=(doxy/html/.) + einstalldocs +} diff --git a/dev-cpp/jwt-cpp/metadata.xml b/dev-cpp/jwt-cpp/metadata.xml new file mode 100644 index 000000000000..1d76ea260c5a --- /dev/null +++ b/dev-cpp/jwt-cpp/metadata.xml @@ -0,0 +1,23 @@ + + + + + o.freyermuth@googlemail.com + Oliver Freyermuth + + + amadio@gentoo.org + Guilherme Amadio + + + proxy-maint@gentoo.org + Proxy Maintainers + + + https://github.com/Thalhammer/jwt-cpp/issues + Thalhammer/jwt-cpp + + + Enable use of dev-cpp/picojson + + -- cgit v1.2.3