forked from spack/spack
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request spack#102 from greenc-FNAL/feature/xrootd
Improvements to xrootd and dependencies
- Loading branch information
Showing
5 changed files
with
219 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other | ||
# Spack Project Developers. See the top-level COPYRIGHT file for details. | ||
# | ||
# SPDX-License-Identifier: (Apache-2.0 OR MIT) | ||
|
||
# ---------------------------------------------------------------------------- | ||
# If you submit this package back to Spack as a pull request, | ||
# please first remove this boilerplate and all FIXME comments. | ||
# | ||
# This is a template package file for Spack. We've put "FIXME" | ||
# next to all the things you'll want to change. Once you've handled | ||
# them, you can save this file and test your package like this: | ||
# | ||
# spack install jwt-cpp | ||
# | ||
# You can edit this file again by typing: | ||
# | ||
# spack edit jwt-cpp | ||
# | ||
# See the Spack documentation for more information on packaging. | ||
# ---------------------------------------------------------------------------- | ||
|
||
from spack.package import * | ||
|
||
|
||
class JwtCpp(CMakePackage): | ||
"""A header only library for creating and validating JSON Web Tokens in C++11.""" | ||
|
||
homepage = "https://github.com/Thalhammer/jwt-cpp" | ||
url = "https://github.com/Thalhammer/jwt-cpp/archive/refs/tags/v0.4.0.tar.gz" | ||
|
||
maintainers("greenc-FNAL", "gartung", "marcmengel", "vitodb") | ||
|
||
version("0.6.0", sha256="0227bd6e0356b211341075c7997c837f0b388c01379bd256aa525566a5553f03") | ||
version("0.5.2", sha256="d3188f9611597eb1bb285169879e1d87202bf10a08e4e7734c9f2097bfd4a850") | ||
version("0.5.1", sha256="d8f5ffb361824630b3b6f4aad26c730c915081071040c232ac57947d6177ef4f") | ||
version("0.5.0", sha256="079a273f070dd11213e301712319a65881e51ab81535cc436d5313191df852a2") | ||
version("0.4.0", sha256="f0dcc7b0e8bef8f9c3f434e7121f9941145042c9fe3055a5bdd709085a4f2be4") | ||
|
||
# TODO: jwt-cpp>=0.6.0 supports wolfSSL for which there is currently | ||
# no Spack recipe. | ||
variant( | ||
"ssl", | ||
default="openssl", | ||
values=("openssl", "libressl"), | ||
multi=False, | ||
when="@0.5.0:", | ||
description="SSL library to use", | ||
) | ||
|
||
depends_on("openssl@1.0.2:", when="@0.4.0:0.4.99") | ||
depends_on("openssl@1.0.2:", when="@0.5.0:0.5.99 ssl=openssl") | ||
depends_on("openssl@1.0.1:", when="@0.6.0: ssl=openssl") | ||
depends_on("libressl@3:", when="@0.5.0: ssl=libressl") | ||
|
||
|
||
def cmake_args(self): | ||
spec = self.spec | ||
define = self.define | ||
args = [] | ||
if spec.satisfies("@0.5.0:"): | ||
ssl_library_dict = { "openssl": "OpenSSL", "libressl": "LibreSSL" } | ||
args.append(define("JWT_SSL_LIBRARY", | ||
ssl_library_dict[spec.variants["ssl"].value])) | ||
args+=[define("JWT_BUILD_TESTS", False), | ||
define("JWT_BUILD_EXAMPLES", False)] | ||
else: | ||
args.append(define("BUILD_TESTS", False)) | ||
return args |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
var/spack/repos/builtin/packages/xrootd/no-systemd-5.5.2.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- a/cmake/XRootDFindLibs.cmake 2021-07-29 12:22:48.000000000 +0000 | ||
+++ b/cmake/XRootDFindLibs.cmake 2021-10-25 18:26:07.308918231 +0000 | ||
@@ -30,10 +30,10 @@ | ||
add_definitions( -DHAVE_XML2 ) | ||
endif() | ||
|
||
-find_package( systemd ) | ||
-if( SYSTEMD_FOUND ) | ||
- add_definitions( -DHAVE_SYSTEMD ) | ||
-endif() | ||
+#find_package( systemd ) | ||
+#if( SYSTEMD_FOUND ) | ||
+# add_definitions( -DHAVE_SYSTEMD ) | ||
+#endif() | ||
|
||
find_package( CURL ) | ||
|
17 changes: 17 additions & 0 deletions
17
var/spack/repos/builtin/packages/xrootd/no-systemd-pre-5.5.2.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- a/cmake/XRootDFindLibs.cmake 2021-07-29 12:22:48.000000000 +0000 | ||
+++ b/cmake/XRootDFindLibs.cmake 2021-10-25 18:26:07.308918231 +0000 | ||
@@ -26,10 +26,10 @@ | ||
add_definitions( -DHAVE_XML2 ) | ||
endif() | ||
|
||
-find_package( Systemd ) | ||
-if( SYSTEMD_FOUND ) | ||
- add_definitions( -DHAVE_SYSTEMD ) | ||
-endif() | ||
+#find_package( Systemd ) | ||
+#if( SYSTEMD_FOUND ) | ||
+# add_definitions( -DHAVE_SYSTEMD ) | ||
+#endif() | ||
|
||
find_package( CURL ) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters