forked from spack/spack
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c1b6bd5
commit b52cbeb
Showing
1 changed file
with
31 additions
and
14 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 |
---|---|---|
|
@@ -6,26 +6,43 @@ | |
from spack.package import * | ||
|
||
|
||
class AwscliV2(PythonPackage): | ||
class AwscliV2(Package, PythonPackage): | ||
"""This package provides a unified command line interface to Amazon Web Services.""" | ||
|
||
homepage = "https://docs.aws.amazon.com/cli" | ||
url = "https://github.com/aws/aws-cli/archive/refs/tags/2.13.22.tar.gz" | ||
|
||
maintainers("climbfuji") | ||
|
||
version("latest", sha256="d045a8baafbe45ab87821b1a1019ba64683dbb2659e1b5ab985f869a52c1bef5") | ||
version("2.13.22", sha256="dd731a2ba5973f3219f24c8b332a223a29d959493c8a8e93746d65877d02afc1") | ||
|
||
depends_on("[email protected]:", type=("build", "run")) | ||
depends_on("[email protected]:3.8.0", type=("build")) | ||
depends_on("[email protected]:0.4.6", type=("build", "run")) | ||
depends_on("[email protected]:0.19", type=("build", "run")) | ||
depends_on("[email protected]:40.0.1", type=("build", "run")) | ||
depends_on("[email protected]:0.17.21", type=("build", "run")) | ||
depends_on("[email protected]:0.2.7", type=("build", "run")) | ||
depends_on("[email protected]:3.0.38", type=("build", "run")) | ||
depends_on("[email protected]:1.8", type=("build", "run")) | ||
depends_on("[email protected]:0.16.16", type=("build", "run")) | ||
depends_on("[email protected]:2", type=("build", "run")) | ||
depends_on("[email protected]:1.0", type=("build", "run")) | ||
depends_on("[email protected]:1.26", type=("build", "run")) | ||
def url_for_version(self, version): | ||
if version == Version("latest"): | ||
return "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" | ||
else: | ||
return f"https://github.com/aws/aws-cli/archive/refs/tags/{version}.tar.gz" | ||
|
||
build_system(conditional("generic", when="@latest"), "python_pip", default="python_pip") | ||
requires("build_system=generic", when="@latest") | ||
|
||
with when("build_system=python_pip"): | ||
depends_on("[email protected]:", type=("build", "run")) | ||
depends_on("[email protected]:3.8.0", type=("build")) | ||
depends_on("[email protected]:0.4.6", type=("build", "run")) | ||
depends_on("[email protected]:0.19", type=("build", "run")) | ||
depends_on("[email protected]:40.0.1", type=("build", "run")) | ||
depends_on("[email protected]:0.17.21", type=("build", "run")) | ||
depends_on("[email protected]:0.2.7", type=("build", "run")) | ||
depends_on("[email protected]:3.0.38", type=("build", "run")) | ||
depends_on("[email protected]:1.8", type=("build", "run")) | ||
depends_on("[email protected]:0.16.16", type=("build", "run")) | ||
depends_on("[email protected]:2", type=("build", "run")) | ||
depends_on("[email protected]:1.0", type=("build", "run")) | ||
depends_on("[email protected]:1.26", type=("build", "run")) | ||
|
||
@when("@latest") | ||
def install(self, spec, prefix): | ||
with working_dir(self.stage.source_path): | ||
installer = which("./install") | ||
installer("--install-dir", prefix, "--bin-dir", prefix.bin) |