mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 12:29:02 +02:00
* fetchurl: accept an optional name. Useful for file names that contain
unacceptable characters (such as ? on Windows). svn path=/nixpkgs/trunk/; revision=8149
This commit is contained in:
parent
2e2daff8ab
commit
2d33b25877
|
@ -3,13 +3,13 @@
|
||||||
|
|
||||||
{stdenv, curl}: # Note that `curl' may be `null', in case of the native stdenv.
|
{stdenv, curl}: # Note that `curl' may be `null', in case of the native stdenv.
|
||||||
|
|
||||||
{url, outputHash ? "", outputHashAlgo ? "", md5 ? "", sha1 ? "", sha256 ? ""}:
|
{name ? "", url, outputHash ? "", outputHashAlgo ? "", md5 ? "", sha1 ? "", sha256 ? ""}:
|
||||||
|
|
||||||
assert (outputHash != "" && outputHashAlgo != "")
|
assert (outputHash != "" && outputHashAlgo != "")
|
||||||
|| md5 != "" || sha1 != "" || sha256 != "";
|
|| md5 != "" || sha1 != "" || sha256 != "";
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = baseNameOf (toString url);
|
name = if name != "" then name else baseNameOf (toString url);
|
||||||
builder = ./builder.sh;
|
builder = ./builder.sh;
|
||||||
buildInputs = [curl];
|
buildInputs = [curl];
|
||||||
|
|
||||||
|
|
|
@ -13,8 +13,8 @@ stdenv.mkDerivation {
|
||||||
# Process Requires.private properly, see
|
# Process Requires.private properly, see
|
||||||
# http://bugs.freedesktop.org/show_bug.cgi?id=4738.
|
# http://bugs.freedesktop.org/show_bug.cgi?id=4738.
|
||||||
(fetchurl {
|
(fetchurl {
|
||||||
# http://bugs.freedesktop.org/attachment.cgi?id=8494
|
name = "pkgconfig-8494.patch";
|
||||||
url = http://losser.st-lab.cs.uu.nl/~mbravenb/mirror/pkg-config.patch;
|
url = http://bugs.freedesktop.org/attachment.cgi?id=8494;
|
||||||
sha256 = "1pcrdbb7dypg2biy0yqc7bdxak5zii8agqljdvk7j4wbyghpqzws";
|
sha256 = "1pcrdbb7dypg2biy0yqc7bdxak5zii8agqljdvk7j4wbyghpqzws";
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
Loading…
Reference in a new issue