#!/bin/sh if [ $# -ne 1 ] then echo "Usage: $(basename $0) VERSION" echo echo "Download and GPG-check component tarballs for GCC VERSION." exit 1 fi version="$1" set -e out="sources.nix" declare -A options options["core"]="/* langC */ true" options["g++"]="langCC" options["fortran"]="langFortran" options["java"]="langJava" cat > "$out"<&1 | grep -E '^(hash|path) is')" path="$(echo $path_and_hash | sed -e's/^.*path is \([^ ]\+\).*$/\1/g')" hash="$(echo $path_and_hash | sed -e's/^.*hash is \([^ ]\+\).*$/\1/g')" rm -f "${url}.sig" wget "${url}.sig" gpg --verify "${file}.sig" "${path}" rm "${file}.sig" cat >> "$out" <> "$out" <