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:
Anton Arapov 2021-04-03 12:58:10 +02:00 committed by Alan Daniels
commit 56de2bcd43
30691 changed files with 3076956 additions and 0 deletions

View file

@ -0,0 +1,40 @@
{ stdenv, lib, fetchurl, substituteAll, PodParser }:
stdenv.mkDerivation {
pname = "multiline";
version = "0.6.3";
src = fetchurl {
url = "https://raw.githubusercontent.com/weechat/scripts/945315bed4bc2beaf1e47f9b946ffe8f638f77fe/perl/multiline.pl";
sha256 = "1smialb21ny7brhij4sbw46xvsmrdv6ig2da0ip63ga2afngwsy4";
};
dontUnpack = true;
prePatch = ''
cp $src multiline.pl
'';
patches = [
# The script requires a special Perl environment.
(substituteAll {
src = ./libpath.patch;
env = PodParser;
})
];
passthru.scripts = [ "multiline.pl" ];
installPhase = ''
runHook preInstall
install -D multiline.pl $out/share/multiline.pl
runHook postInstall
'';
meta = with lib; {
description = "Multi-line edit box";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ oxzi ];
};
}

View file

@ -0,0 +1,9 @@
diff --git a/multiline.pl b/multiline.pl
index 54474d4..42fbef8 100644
--- a/multiline.pl
+++ b/multiline.pl
@@ -1,3 +1,4 @@
+use lib '@env@/lib/perl5/site_perl';
use strict; use warnings;
$INC{'Encode/ConfigLocal.pm'}=1;
require Encode;