summaryrefslogtreecommitdiff
path: root/dev-cpp/jwt-cpp
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2024-01-30 11:49:23 +0000
committerV3n3RiX <venerix@koprulu.sector>2024-01-30 11:49:23 +0000
commit840a65e2af3f2cc7527e723a28f6e627a9592fb7 (patch)
tree66e124d9e55317fe43e1af9984e75c156df5cb29 /dev-cpp/jwt-cpp
parent73e3b099187df1c4f2df056e45f345a56d2535aa (diff)
gentoo auto-resync : 30:01:2024 - 11:49:23
Diffstat (limited to 'dev-cpp/jwt-cpp')
-rw-r--r--dev-cpp/jwt-cpp/Manifest2
-rw-r--r--dev-cpp/jwt-cpp/jwt-cpp-0.7.0.ebuild80
2 files changed, 82 insertions, 0 deletions
diff --git a/dev-cpp/jwt-cpp/Manifest b/dev-cpp/jwt-cpp/Manifest
index 97f4918cf7ba..b94981dd9481 100644
--- a/dev-cpp/jwt-cpp/Manifest
+++ b/dev-cpp/jwt-cpp/Manifest
@@ -1,4 +1,6 @@
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
+DIST jwt-cpp-0.7.0.tar.gz 133925 BLAKE2B 7f6ff1d23f60c555382e4ae4e9633954db638a93bb4f183efe057da8cc751be6f5a545e94cd8976e8b0260a6775a1ed82c7b2445401ba01fb46869489f289f38 SHA512 b6fdb93e3f2f065a2eb45fe16cb076a932b8d4bfad2251bd66d2be40d8afaf5c27a9cf17aaea61d8bfa3f5ff9ed3b45f90962dc14d72704ac5b9d717c12cc79f
EBUILD jwt-cpp-0.6.0.ebuild 1987 BLAKE2B 043be060736d6d5c8a179b7896e509c34aeaea804d4593dd6b01dab969060079f9ac6541db30326c90aceb9a74dc9b83eaf49391afd70c2f8613a621d16617aa SHA512 a315e18832845730f68cd12be9132169ec50615e3be75237adeccd4de830887bc20a641000b020e3d144c93f19f19c65d304458a51353880234d2b5822698af5
+EBUILD jwt-cpp-0.7.0.ebuild 1937 BLAKE2B 736c7bedd07ad17f37e0c392ac23dc188bbd3229e3a4dea4a9390c2a2350aba528998da28dd4310c49956ef210c30566ee70251a0c7d49602fb4c33628eb7372 SHA512 eebabc7e1982ecc47893a6ef6837609d665e3813ba128411cf28adbda3439534259fe2031fe8fcbbe2c800ec249adb2c6df9dd2290ac914cbbd3940aecf1f043
MISC metadata.xml 783 BLAKE2B 6c1156aa5c7466acf0dc97db88e228d0dd1a15e9938df61c9ca4d1b4d80fa38aacbc2e3034c91deb4a4b7a4076c61511a34f8f72d4d077987577666c393a7fcc SHA512 3ca38fd435697019e10b292019355786d92e258ba8deb37f035a2d767c0bab9450560a03619b660f383cce794c24bc7bbd6ac23a0a902ca7654afccc432b8121
diff --git a/dev-cpp/jwt-cpp/jwt-cpp-0.7.0.ebuild b/dev-cpp/jwt-cpp/jwt-cpp-0.7.0.ebuild
new file mode 100644
index 000000000000..64f36db0f7dd
--- /dev/null
+++ b/dev-cpp/jwt-cpp/jwt-cpp-0.7.0.ebuild
@@ -0,0 +1,80 @@
+# Copyright 1999-2024 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-text/doxygen[dot] )
+ test? ( dev-cpp/gtest )
+"
+RESTRICT="
+ !picojson? ( test )
+ !test? ( test )
+"
+
+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
+}