@@ -73,6 +73,9 @@ in
73 # is communicated to postFetch via $downloadedFile.
73 # is communicated to postFetch via $downloadedFile.
74 downloadToTemp ? false
74 downloadToTemp ? false
76+, # If true, set executable bit on downloaded file
76, # If set, don't download the file, but write a list of all possible
79, # If set, don't download the file, but write a list of all possible
77 # URLs (resulting from resolving mirror:// URLs) to $out.
80 # URLs (resulting from resolving mirror:// URLs) to $out.
78 showURLs ? false
81 showURLs ? false
@@ -116,9 +119,9 @@ if (!hasHash) then throw "Specify hash for fetchurl fixed-output derivation: ${s
116 outputHash = if outputHash != "" then outputHash else
119 outputHash = if outputHash != "" then outputHash else
117 if sha256 != "" then sha256 else if sha1 != "" then sha1 else md5;
120 if sha256 != "" then sha256 else if sha1 != "" then sha1 else md5;
119− outputHashMode = if recursiveHash then "recursive" else "flat";
122+ outputHashMode = if (recursiveHash || executable) then "recursive" else "flat";
121− inherit curlOpts showURLs mirrorsFile impureEnvVars postFetch downloadToTemp;
124+ inherit curlOpts showURLs mirrorsFile impureEnvVars postFetch downloadToTemp executable;
123 # Doing the download on a remote machine just duplicates network
126 # Doing the download on a remote machine just duplicates network
124 # traffic, so don't do that.
127 # traffic, so don't do that.