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,53 @@
{ lib
, stdenv
, fetchurl
, autoreconfHook
, enableMail ? false
, mailutils
, inetutils
, IOKit
, ApplicationServices
}:
let
dbrev = "5171";
drivedbBranch = "RELEASE_7_2_DRIVEDB";
driverdb = fetchurl {
url = "https://sourceforge.net/p/smartmontools/code/${dbrev}/tree/branches/${drivedbBranch}/smartmontools/drivedb.h?format=raw";
sha256 = "0vncr98xagbcfsxgfgxsip2qrl9q3y8va19qhv6yknlwbdfap4mn";
name = "smartmontools-drivedb.h";
};
in
stdenv.mkDerivation rec {
pname = "smartmontools";
version = "7.2";
src = fetchurl {
url = "mirror://sourceforge/smartmontools/${pname}-${version}.tar.gz";
sha256 = "1mlc25sd5rgj5xmzcllci47inmfdw7cp185fday6hc9rwqkqmnaw";
};
patches = [
# fixes darwin build
./smartmontools.patch
];
postPatch = ''
cp -v ${driverdb} drivedb.h
'';
configureFlags = lib.optional enableMail "--with-scriptpath=${lib.makeBinPath [ inetutils mailutils ]}";
nativeBuildInputs = [ autoreconfHook ];
buildInputs = lib.optionals stdenv.isDarwin [ IOKit ApplicationServices ];
enableParallelBuilding = true;
meta = with lib; {
description = "Tools for monitoring the health of hard drives";
homepage = "https://www.smartmontools.org/";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ Frostman ];
platforms = with platforms; linux ++ darwin;
mainProgram = "smartctl";
};
}

View file

@ -0,0 +1,26 @@
diff --git a/../smartmontools-6.5/configure b/./configure
index acb028a..5e2c7a1 100755
--- a/../smartmontools-6.5/configure
+++ b/./configure
@@ -6703,7 +6703,7 @@ fi
;;
*-*-darwin*)
os_deps='os_darwin.o'
- os_libs='-framework CoreFoundation -framework IOKit'
+ os_libs='-framework ApplicationServices -framework IOKit'
os_darwin=yes
os_man_filter=Darwin
;;
diff --git a/../smartmontools-6.5/configure.ac b/./configure.ac
index 6bd61d7..32ff50c 100644
--- a/../smartmontools-6.5/configure.ac
+++ b/./configure.ac
@@ -508,7 +508,7 @@ case "${host}" in
;;
*-*-darwin*)
os_deps='os_darwin.o'
- os_libs='-framework CoreFoundation -framework IOKit'
+ os_libs='-framework ApplicationServices -framework IOKit'
os_darwin=yes
os_man_filter=Darwin
;;