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,45 @@
{ lib, stdenv, fetchFromGitHub, unzip, cmake, alsa-lib, Carbon, CoreAudio, CoreFoundation, CoreMIDI, CoreServices }:
stdenv.mkDerivation rec {
pname = "portmidi";
version = "2.0.3";
src = fetchFromGitHub {
owner = pname;
repo = pname;
rev = "v${version}";
sha256 = "sha256-bLGqi3b9FHBA43baNDT8jkPBQSXAUDfurQSJHLcy3AE=";
};
cmakeFlags = [
"-DCMAKE_ARCHIVE_OUTPUT_DIRECTORY=Release"
"-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=Release"
"-DCMAKE_RUNTIME_OUTPUT_DIRECTORY=Release"
];
patches = [
# Add missing header include
./missing-header.diff
];
postInstall = let ext = stdenv.hostPlatform.extensions.sharedLibrary; in ''
ln -s libportmidi${ext} "$out/lib/libporttime${ext}"
'';
nativeBuildInputs = [ unzip cmake ];
buildInputs = lib.optionals stdenv.isLinux [
alsa-lib
] ++ lib.optionals stdenv.isDarwin [
Carbon CoreAudio CoreFoundation CoreMIDI CoreServices
];
hardeningDisable = [ "format" ];
meta = with lib; {
homepage = "https://github.com/PortMidi/portmidi";
description = "Platform independent library for MIDI I/O";
license = licenses.mit;
maintainers = with maintainers; [ emilytrau ];
platforms = platforms.unix;
};
}

View file

@ -0,0 +1,12 @@
diff --git a/porttime/ptmacosx_mach.c b/porttime/ptmacosx_mach.c
index 10c3554..712a974 100755
--- a/porttime/ptmacosx_mach.c
+++ b/porttime/ptmacosx_mach.c
@@ -12,6 +12,7 @@
#include "porttime.h"
#include "sys/time.h"
+#include "sys/qos.h"
#include "pthread.h"
#ifndef NSEC_PER_MSEC