mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
* Fedora 11 uses SHA-256 hashes instead of SHA-1 in primary.xml.
svn path=/nixpkgs/trunk/; revision=15908
This commit is contained in:
parent
d8cc981d90
commit
813909d153
@ -103,10 +103,15 @@ print "[\n\n";
|
||||
|
||||
foreach my $pkgName (@needed) {
|
||||
my $pkg = $pkgs{$pkgName};
|
||||
die if $pkg->{checksum}->{type} ne "sha";
|
||||
print " (fetchurl {\n";
|
||||
print " url = $urlPrefix/$pkg->{location}->{href};\n";
|
||||
print " sha1 = \"$pkg->{checksum}->{content}\";\n";
|
||||
if ($pkg->{checksum}->{type} eq "sha") {
|
||||
print " sha1 = \"$pkg->{checksum}->{content}\";\n";
|
||||
} elsif ($pkg->{checksum}->{type} eq "sha256") {
|
||||
print " sha256 = \"$pkg->{checksum}->{content}\";\n";
|
||||
} else {
|
||||
die "unsupported hash type";
|
||||
}
|
||||
print " })\n";
|
||||
print "\n";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user