summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/gawk/package.py
diff options
context:
space:
mode:
authorMassimiliano Culpo <massimiliano.culpo@gmail.com>2019-12-20 23:32:18 +0100
committerTodd Gamblin <tgamblin@llnl.gov>2019-12-20 14:32:18 -0800
commit497fddfcb9fdcebac47b56c6d856110b9150b5ea (patch)
treeb04db6fc53ec437c5751f3b364b962293701e5ac /var/spack/repos/builtin/packages/gawk/package.py
parent1b93320848b41057f8892c2a59287d904d28ce6e (diff)
downloadspack-497fddfcb9fdcebac47b56c6d856110b9150b5ea.tar.gz
spack-497fddfcb9fdcebac47b56c6d856110b9150b5ea.tar.bz2
spack-497fddfcb9fdcebac47b56c6d856110b9150b5ea.tar.xz
spack-497fddfcb9fdcebac47b56c6d856110b9150b5ea.zip
Fetching from URLs falls back to mirrors if they exist (#13881)
Users can now list mirrors of the main url in packages. - [x] Instead of just a single `url` attribute, users can provide a list (`urls`) in the package, and these will be tried by in order by the fetch strategy. - [x] To handle one of the most common mirror cases, define a `GNUMirrorPackage` mixin to handle all the standard GNU mirrors. GNU packages can set `gnu_mirror_path` to define the path within a mirror, and the mixin handles setting up all the requisite GNU mirror URLs. - [x] update all GNU packages in `builtin` to use the `GNUMirrorPackage` mixin.
Diffstat (limited to 'var/spack/repos/builtin/packages/gawk/package.py')
-rw-r--r--var/spack/repos/builtin/packages/gawk/package.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/gawk/package.py b/var/spack/repos/builtin/packages/gawk/package.py
index 0775f05fd1..8c6d97f21f 100644
--- a/var/spack/repos/builtin/packages/gawk/package.py
+++ b/var/spack/repos/builtin/packages/gawk/package.py
@@ -6,7 +6,7 @@
from spack import *
-class Gawk(AutotoolsPackage):
+class Gawk(AutotoolsPackage, GNUMirrorPackage):
"""If you are like many computer users, you would frequently like to make
changes in various text files wherever certain patterns appear, or
extract data from parts of certain lines while discarding the
@@ -21,7 +21,7 @@ class Gawk(AutotoolsPackage):
"""
homepage = "https://www.gnu.org/software/gawk/"
- url = "https://ftpmirror.gnu.org/gawk/gawk-4.1.4.tar.xz"
+ gnu_mirror_path = "gawk/gawk-4.1.4.tar.xz"
version('5.0.1', sha256='8e4e86f04ed789648b66f757329743a0d6dfb5294c3b91b756a474f1ce05a794')
version('4.1.4', sha256='53e184e2d0f90def9207860531802456322be091c7b48f23fdc79cda65adc266')