uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
69
pkgs/development/interpreters/tcl/mk-tcl-derivation.nix
Normal file
69
pkgs/development/interpreters/tcl/mk-tcl-derivation.nix
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
# Generic builder for tcl packages/applications, generally based on mk-python-derivation.nix
|
||||
{ tcl
|
||||
, lib
|
||||
, makeWrapper
|
||||
, runCommand
|
||||
, writeScript
|
||||
}:
|
||||
|
||||
{ buildInputs ? []
|
||||
, nativeBuildInputs ? []
|
||||
, propagatedBuildInputs ? []
|
||||
, checkInputs ? []
|
||||
|
||||
# true if we should skip the configuration phase altogether
|
||||
, dontConfigure ? false
|
||||
|
||||
# Extra flags passed to configure step
|
||||
, configureFlags ? []
|
||||
|
||||
# Whether or not we should add common Tcl-related configure flags
|
||||
, addTclConfigureFlags ? true
|
||||
|
||||
, meta ? {}
|
||||
, passthru ? {}
|
||||
, doCheck ? true
|
||||
, ... } @ attrs:
|
||||
|
||||
let
|
||||
inherit (tcl) stdenv;
|
||||
inherit (lib) getBin optionalAttrs optionals;
|
||||
|
||||
defaultTclPkgConfigureFlags = [
|
||||
"--with-tcl=${tcl}/lib"
|
||||
"--with-tclinclude=${tcl}/include"
|
||||
"--exec-prefix=${placeholder "out"}"
|
||||
];
|
||||
|
||||
self = (stdenv.mkDerivation ((builtins.removeAttrs attrs [
|
||||
"addTclConfigureFlags" "checkPhase" "checkInputs" "doCheck"
|
||||
]) // {
|
||||
|
||||
buildInputs = buildInputs ++ [ tcl.tclPackageHook ];
|
||||
nativeBuildInputs = nativeBuildInputs ++ [ makeWrapper tcl ];
|
||||
propagatedBuildInputs = propagatedBuildInputs ++ [ tcl ];
|
||||
|
||||
TCLSH = "${getBin tcl}/bin/tclsh";
|
||||
|
||||
# Run tests after install, at which point we've done all TCLLIBPATH setup
|
||||
doCheck = false;
|
||||
doInstallCheck = attrs.doCheck or ((attrs ? doInstallCheck) && attrs.doInstallCheck);
|
||||
installCheckInputs = checkInputs ++ (optionals (attrs ? installCheckInputs) attrs.installCheckInputs);
|
||||
|
||||
# Add typical values expected by TEA for configureFlags
|
||||
configureFlags =
|
||||
if (!dontConfigure && addTclConfigureFlags)
|
||||
then (configureFlags ++ defaultTclPkgConfigureFlags)
|
||||
else configureFlags;
|
||||
|
||||
meta = {
|
||||
platforms = tcl.meta.platforms;
|
||||
} // meta;
|
||||
|
||||
|
||||
} // optionalAttrs (attrs?checkPhase) {
|
||||
installCheckPhase = attrs.checkPhase;
|
||||
}
|
||||
));
|
||||
|
||||
in lib.extendDerivation true passthru self
|
||||
Loading…
Add table
Add a link
Reference in a new issue